i want to set a class back to its original structure after calling a receive function. code below to explain
Code:
class Node { public: Node(){} ~Node(){} }; class lol : public Node { public: string strName; }; class face { public: void vSetLOL( CONST Node &C_lol ) { this->C_lol = C_lol; } const Node getLoL( void ) const { return C_lol; } priavte: Node C_lol ; } main { lol C_lol; face C_face; C_lol.strname = "gums"; C_face.vSetLOL( C_lol ); C_lol.strname = " monkey"; ////// how do you change the node C_lol back to lol C_lol ///// C_lol = C_face.getLOL(); /// this is the main problem }
Comment