Hi,<br><br>I have a complex case I'm trying to work with. I may be doing this completely wrong so if there is a better design for this I'm always open for that. However for now I'm going to assume my particular problem can be solved.<br> <br>There exists two classes: A and B. Class A is defined as such:<br><br><span style="font-family: courier new,monospace; color: rgb(153, 0, 0);">class A</span><br style="font-family: courier new,monospace; color: rgb(153, 0, 0);"> <span style="font-family: courier new,monospace; color: rgb(153, 0, 0);">{</span><br style="font-family: courier new,monospace; color: rgb(153, 0, 0);"><span style="font-family: courier new,monospace; color: rgb(153, 0, 0);">public:</span><br style="font-family: courier new,monospace; color: rgb(153, 0, 0);"> <span style="font-family: courier new,monospace; color: rgb(153, 0, 0);"> template< typename Archive ></span><br style="font-family: courier new,monospace; color: rgb(153, 0, 0);"><span style="font-family: courier new,monospace; color: rgb(153, 0, 0);"> void load( Archive& archive, unsigned int )</span><br style="font-family: courier new,monospace; color: rgb(153, 0, 0);"> <span style="font-family: courier new,monospace; color: rgb(153, 0, 0);"> {</span><br style="font-family: courier new,monospace; color: rgb(153, 0, 0);"><span style="font-family: courier new,monospace; color: rgb(153, 0, 0);"> archive & m_listOfB;</span><br style="font-family: courier new,monospace; color: rgb(153, 0, 0);"> <span style="font-family: courier new,monospace; color: rgb(153, 0, 0);"> }</span><br style="font-family: courier new,monospace; color: rgb(153, 0, 0);"><br style="font-family: courier new,monospace; color: rgb(153, 0, 0);"> <span style="font-family: courier new,monospace; color: rgb(153, 0, 0);">private:</span><br style="font-family: courier new,monospace; color: rgb(153, 0, 0);"><span style="font-family: courier new,monospace; color: rgb(153, 0, 0);"> std::vector<int> m_listOfInt;</span><br style="font-family: courier new,monospace; color: rgb(153, 0, 0);"> <span style="font-family: courier new,monospace; color: rgb(153, 0, 0);"> boost::ptr_vector<B> m_listOfB;</span><br style="font-family: courier new,monospace; color: rgb(153, 0, 0);"><span style="font-family: courier new,monospace; color: rgb(153, 0, 0);">};</span><br> <br>And class B is defined roughly as:<br><br><span style="font-family: courier new,monospace; color: rgb(153, 0, 0);">class B</span><br style="font-family: courier new,monospace; color: rgb(153, 0, 0);"><span style="font-family: courier new,monospace; color: rgb(153, 0, 0);">{</span><br style="font-family: courier new,monospace; color: rgb(153, 0, 0);"> <span style="font-family: courier new,monospace; color: rgb(153, 0, 0);">public:</span><br style="font-family: courier new,monospace; color: rgb(153, 0, 0);"><span style="font-family: courier new,monospace; color: rgb(153, 0, 0);"> template< typename Archive ></span><br style="font-family: courier new,monospace; color: rgb(153, 0, 0);"> <span style="font-family: courier new,monospace; color: rgb(153, 0, 0);"> void load( Archive& archive, unsigned int )</span><br style="font-family: courier new,monospace; color: rgb(153, 0, 0);"><span style="font-family: courier new,monospace; color: rgb(153, 0, 0);"> {</span><br style="font-family: courier new,monospace; color: rgb(153, 0, 0);"> <span style="font-family: courier new,monospace; color: rgb(153, 0, 0);"> // Code isn't important here</span><br style="font-family: courier new,monospace; color: rgb(153, 0, 0);"><span style="font-family: courier new,monospace; color: rgb(153, 0, 0);"> }</span><br style="font-family: courier new,monospace; color: rgb(153, 0, 0);"> <span style="font-family: courier new,monospace; color: rgb(153, 0, 0);">};</span><br><br>Here's the problem:<br><br>For each B that is deserialized by A::load(), I need to pass in a reference to m_listOfInt. So, essentially the load() function in B would look something like this:<br> <br style="font-family: courier new,monospace;"><span style="font-family: courier new,monospace; color: rgb(153, 0, 0);">void load( Archive& archive, unsigned int, std::vector<int>& listOfInt )</span><br style="font-family: courier new,monospace; color: rgb(153, 0, 0);"> <span style="font-family: courier new,monospace; color: rgb(153, 0, 0);">{</span><br style="font-family: courier new,monospace; color: rgb(153, 0, 0);"><span style="font-family: courier new,monospace; color: rgb(153, 0, 0);">}</span><br> <br>I was hoping boost.bind could be used somewhere, but I just don't see how. One way to solve the problem is to call B::load() explicitly with the extra parameter, but I don't think that's an appropriate solution. Any ideas on how to solve this? Or perhaps I'm trying to solve the wrong problem.<br>