Here have a class, in this class, one containing the boost: : the function parameters of member functions, to realize the interface in v8 now, but the problem is how to set the v8: : the parameters of the Argument into class need to boost: : the function, the code is as follows:
The class Node { Typedef boost: : functionPublic: Bool enumerateChildren (EnumCallBack callback) const { If (true==children_. Empty ()) { return false; } For (Nodes: : const_iterator iter=children_. The begin (); Iter!=children_. End (); Iter++) { The callback (* iter); } return true; };
Private: Vector }; Handle NodeEnumerateChildren (const Arguments& The args) { Local