Hi everybody,<br><br>Thanks for all the great replies. You have really shed some light on this. <br><br>What I'll end up doing is probably writing a wrapper class for the remote object: <br><br>(pseudo code)<br><br>class RemoteObjectWrapper {<br>
private RemoteObject remoteObject;<br> public int doStuff( BigComplexNestedDataStructure arg ) {<br> remoteObject.doStuff( convert( arg ) );<br> }<br> private SpeciallyAdaptedArgType convert( BigComplexNestedDataStructure arg ) {<br>
...<br> }<br>}<br><br>class RemoteObject {<br> private ActualRemoteObject actualObject;<br> public int doStuff( SpeciallyAdaptedArgType arg ) {<br> actualObject.doStuff( convert( arg ) );<br> }<br> private BigComplexNestedDataStructure convert( SpeciallyAdaptedArgType arg ) {<br>
...<br> }<br>}<br><br>class ActualRemoteObject {<br> public int doStuff( BigComplexNestedDataStructure arg ) {<br> ... actual code ...<br> }<br>}<br><br>This way I'll end up having to change the existing codebase as little as possible, thus minimizing the risk of breaking something, as it's a fairly big system I'm changing. <br>
<br>Thanks again for all the advice.<br><br>/David<br><br>