Hi guys,
I have list of class contain list of another class.
I need advice which one is the right way to set myMessages class??Code:MyMessages class { ID list <myPackets> Packets; } myPackets class { Seq Text }
ORCode:void set_myMessages(const int &ID, list <myPackets> Packets)
and also I need advice how to make a list of class.Code:void set_myMessages(const string &ID, string Seq, string Text)
atm I use,
It does work but, I couldn't print the listPackets using iterator?Code:list <myPackets> listPackets; myPackets Packets; Packets.set(seq,text); listPackets.push_back(Packets); Packets.set(seq,text); listPackets.push_back(Packets);
so How do I print my list??? Also I need to sort list of my Packets, but
my list of packet contain 2 element seq and text, so I couldn't use sort() funtion, so any Idea how I sorting the data??
Thank You So Much



LinkBack URL
About LinkBacks


