Implementing a VMC
public class myVMC implements VirtualMobileCode,
VMCManagedResources, ... , Serializable {
private MobileCodeStub stub = null; // Defined here but set by the MCM !
// Implement all methods of the (Virtual) MobileCode interface
public setStub (MobileCodeStub stub) { // Nobody but MCM should call this !
// Implement all methods of all other interfaces implemented
Notes:
1) A VMC must implement VMCMobileCode ... which is an empty subclass of
MobileCode used only for type-casting within the MobileCodeManager
2) The toolkit provides a good starting point in users : An empty
VirtualManagedComponent (returns null when any data is queried) that
can easily be extended ... and filled. However, your subclass should implement
Serializable if you want to transport the VMC.
3) Perhaps we need a SuperVMC.java !