public interface Grail
Four fundamental constraints are imposed:
The specific package in which this class resides, and that of its implementing class, can be framework specific.
| Modifier and Type | Method and Description |
|---|---|
void |
export(Object object)
This method makes an object's public methods, whether instance or
static, remotely invocable.
|
Object[] |
lookup(Class methodSetInterface)
This method finds all remotely invocable objects, supporting the
specified method set.
|
Object |
proxy(Object reference,
Class methodSetInterface)
This method instantiates a
Dynamic Proxy at the client, which implements the method set
specified.
|
void export(Object object) throws Exception
Note: There is no silly requirement that the object being exported implement a no-arg constructor; any syntactically valid class definition will work.
Object[] lookup(Class methodSetInterface) throws Exception
Four levels of remote object covariance must be supported here:
Notes: If the client interface has superinterfaces, their methods must also be matched similarly. Method arguments, and returns, are alowed to be primitive types as well.
methodSetInterface - The interface of methods that remote objects
are required to supportException - For any network or framework specific reasonsObject proxy(Object reference, Class methodSetInterface)
reference - A reference to a remote object returned by the
lookup method of this interfacemethodSetInterface - The set (or subset) of client methods,
static or instance, that the remote object implementsCopyright © 2016. All Rights Reserved.