|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--com.sun.jaw.impl.adaptor.iiop.AdaptorClient
The AdaptorClient
class provides an implementation of the
AdaptorMO
interface based on the Internet Inter ORB Protocol (IIOP) system.
In order to identify the Java Dynamic Management agent with which the adaptor needs to communicate,
the connect needs to be invoked with the
IIOP identity of the IIOP
Adaptor server
.
AdaptorMO
,
AdaptorServerImpl
, Serialized FormConstructor Summary | |
AdaptorClient()
Constructs an adaptor client. |
Method Summary | |
ObjectName |
addListener(ManagedObject mo,
java.util.EventListener listen,
java.lang.String listenerType)
Adds a managed object listener. |
void |
cb_connect(ManagedObject cbean)
Connects a C-bean to the adaptor. |
void |
cb_disconnect(ManagedObject cbean)
Disconnects a C-bean from the adaptor. |
java.lang.Object |
cb_newDBMO(java.lang.String impl,
ObjectName name,
ModificationList list)
Creates a persistent instance of a managed object on the remote object server. |
java.lang.Object |
cb_newDBMO(java.lang.String impl,
ObjectName name,
ModificationList list,
ObjectName aLoader)
Creates a persistent instance of a managed object on the remote object server. |
java.lang.Object |
cb_newMO(java.lang.String impl,
ObjectName name,
ModificationList list)
Creates an instance of a managed object on the remote object server. |
java.lang.Object |
cb_newMO(java.lang.String impl,
ObjectName name,
ModificationList list,
ObjectName aLoader)
Creates an instance of a managed object on the remote object server. |
void |
connect(java.lang.Object context,
java.lang.String host,
int port,
java.lang.String logicalName)
Initializes the communications with a remote managed object server. |
void |
deleteMO(ObjectName name)
Deletes an instance of a managed object in the remote object server. |
void |
disconnect()
Terminates the communications with the remote managed object server. |
java.lang.String |
getAdaptorVersion()
The method returns a string that represents the version of this JDMK adaptor. |
java.lang.ClassLoader |
getClassLoader()
Gets the class loader used to retrieve all MO and MOStub classes. |
static java.lang.String |
getClassVersion()
Returns the version of this class. |
java.lang.String |
getDomain()
Returns the name of the domain controlled by the managed object server. |
java.lang.Object |
getIndexedValue(ObjectName name,
java.lang.String property,
int pos)
Gets the value of a specific indexed property in a managed object. |
MapperSrvIf |
getMapperSrv()
Gets the mapper used to derive the implementation name from an object name. |
java.util.Vector |
getObject(ObjectName name,
QueryExp filter)
Gets handles on managed objects controlled by the remote managed object server. |
ManagedObject |
getObjectFromCache(ObjectName name)
Returns the local managed object associated with name . |
java.util.Vector |
getOnlyNames(ObjectName name,
QueryExp query)
Gets the names of managed objects controlled by the remote managed object server. |
java.lang.Object |
getValue(ObjectName name,
java.lang.String property)
Gets the value of a specific property in a managed object. |
PropertyList |
getValues(ObjectName name,
java.util.Vector propertyIdList)
Gets the values of several properties in a managed object. |
java.util.EventListener |
giveListener(ObjectName mo,
ObjectName listener)
Retrieves the the given listener associated to the managed object. |
java.lang.Object |
invokePerform(ObjectName objName,
java.lang.String pfName,
java.lang.Object[] params,
java.lang.String[] signature)
Invokes a specific method on a remote object. |
java.lang.Boolean |
isConnected()
Checks whether the managed object adaptor is connected to the remote managed object server. |
void |
newDBMO(java.lang.String impl,
ObjectName name,
ModificationList list)
Creates a persistent instance of a managed object on the remote object server. |
void |
newDBMO(java.lang.String impl,
ObjectName name,
ModificationList list,
ObjectName aLoader)
Creates a persistent instance of a managed object on the remote object server. |
void |
newMO(java.lang.String impl,
ObjectName name,
ModificationList list)
Creates an instance of a managed object on the remote object server. |
void |
newMO(java.lang.String impl,
ObjectName name,
ModificationList list,
ObjectName aLoader)
Creates an instance of a managed object on the remote object server. |
void |
newObj(java.lang.String className)
Instantiates a Java object of a specific class on a remote managed object server. |
void |
newObj(java.lang.String className,
ObjectName aLoader)
Instantiates a Java object of a specific class on a remote managed object server. |
void |
removeListener(ManagedObject mo,
ObjectName name)
Removes a managed object listener. |
void |
setClassLoader(java.lang.ClassLoader loader)
Specifies a class loader to retrieve MO and MOStub classes. |
java.lang.Object |
setIndexedValue(ObjectName name,
java.lang.String property,
java.lang.Object value,
java.lang.String op,
int pos)
Sets the value of a specific indexed property of a named managed object. |
void |
setMapperSrv(MapperSrvIf mapper)
Allows you to specify a mapper. |
int |
setup(java.lang.Object param)
Specifies the location of the CORBA naming service. |
java.lang.Object |
setValue(ObjectName name,
java.lang.String property,
java.lang.Object value,
java.lang.String op)
Sets a property of a named managed object to a specific value. |
PropertyList |
setValues(ObjectName name,
ModificationList modif)
Sets the value of several properties within a managed object. |
void |
transferObject(java.lang.Object object,
ObjectName logicalName)
Creates a copy of a named object and adds it to the remote repository. |
Methods inherited from class java.lang.Object |
clone,
equals,
finalize,
getClass,
hashCode,
notify,
notifyAll,
toString,
wait,
wait,
wait |
Constructor Detail |
public AdaptorClient()
Method Detail |
public int setup(java.lang.Object param)
param
- A String
object containing the
hostname on which the Corba naming service is running and port number
on which the Corba naming service listens (for instance sky:9500).public void connect(java.lang.Object context, java.lang.String host, int port, java.lang.String logicalName) throws CommunicationException, java.lang.SecurityException
context
- Not used by the IIOP adaptor.host
- The host name of the server.port
- Not used.logicalName
- The logical name of the adaptor.public void disconnect()
public java.lang.Boolean isConnected()
public java.util.Vector getOnlyNames(ObjectName name, QueryExp query) throws InstanceNotFoundException
name
- The names of the managed objects to be retrieved.query
- The query to be applied for selecting managed
objects.public java.util.Vector getObject(ObjectName name, QueryExp filter) throws LocalException, InstanceNotFoundException, java.lang.reflect.InvocationTargetException
name
- The names of the managed objects to be retrieved.filter
- The filter to be applied for selecting managed
objects.LocalException
.InvocationTargetException
.public java.lang.Object getValue(ObjectName name, java.lang.String property) throws InstanceNotFoundException, PropertyNotFoundException, java.lang.reflect.InvocationTargetException
name
- The name of the managed object from which
the property is to be retrieved.property
- The name of the property to be retrieved.InvocationTargetException
.public java.lang.Object getIndexedValue(ObjectName name, java.lang.String property, int pos) throws InstanceNotFoundException, PropertyNotFoundException, java.lang.reflect.InvocationTargetException
name
- The names of the object from which
the property is to be retrieved.property
- The name of the property to be retrieved.pos
- The position in the index of the value to
be retrieved.InvocationTargetException
.public PropertyList getValues(ObjectName name, java.util.Vector propertyIdList) throws InstanceNotFoundException
name
- The name of the object from which
the properties are to be retrieved.propertyIdList
- A list of the properties to be retrieved.public java.lang.Object setValue(ObjectName name, java.lang.String property, java.lang.Object value, java.lang.String op) throws InstanceNotFoundException, java.lang.IllegalAccessException, PropertyNotFoundException, InvalidPropertyValueException, java.lang.ClassNotFoundException, java.lang.InstantiationException, java.lang.reflect.InvocationTargetException
name
- The name of the object in which the property is to be set.property
- The property to be set.value
- The value that the property is to be set to.op
- The Java class name of the operator to be applied to the property.
The class must implement the OperatorSrvIf
interface.InvocationTargetException
.public java.lang.Object setIndexedValue(ObjectName name, java.lang.String property, java.lang.Object value, java.lang.String op, int pos) throws InstanceNotFoundException, java.lang.reflect.InvocationTargetException, java.lang.IllegalAccessException, ServiceNotFoundException, PropertyNotFoundException, InvalidPropertyValueException, java.lang.InstantiationException, java.lang.ClassNotFoundException
name
- The name of the object in which the property is to be set.property
- The property to be set.value
- The value that the property is to be set to.op
- The Java class name of the operator to be applied to the property.
The class must implement the OperatorSrvIf
interface.pos
- The position in the index of the property to be set.InvocationTargetException
.public PropertyList setValues(ObjectName name, ModificationList modif) throws InstanceNotFoundException, java.lang.IllegalAccessException, java.lang.reflect.InvocationTargetException
Serializable
interface.name
- The name of the object in which the properties are to be set.ModificationList
- A list of the properties to be set and
the values to which they are to be set.InvocationTargetException
.public ManagedObject getObjectFromCache(ObjectName name)
name
.name
- The name of the local managed object to be accessed.name
.public ObjectName addListener(ManagedObject mo, java.util.EventListener listen, java.lang.String listenerType) throws InstanceNotFoundException, java.lang.IllegalAccessException, java.lang.ClassNotFoundException, java.lang.InstantiationException
mo
- The name of the managed object to be listened to.listen
- The listener to be added.listenerType
- Class name of the remote listener to be created.removeListener(com.sun.jaw.reference.client.mo.ManagedObject, com.sun.jaw.reference.common.ObjectName)
public void removeListener(ManagedObject mo, ObjectName name)
name
- The name of the remote listener
to be removed.public java.util.EventListener giveListener(ObjectName mo, ObjectName listener)
mo
- The name of the managed object for which the listener was operating.name
- The name of the remote listener to be retrieved.public void newObj(java.lang.String className) throws java.lang.IllegalAccessException, java.lang.InstantiationException, java.lang.ClassNotFoundException, java.lang.reflect.InvocationTargetException
className
- The Java class name of the object to be
created.InvocationTargetException
.public void newMO(java.lang.String impl, ObjectName name, ModificationList list) throws java.lang.IllegalAccessException, java.lang.ClassNotFoundException, InstanceAlreadyExistException, java.lang.InstantiationException, java.lang.reflect.InvocationTargetException
impl
- The name of the Java implementation to be used on the server.name
- The name of the managed object to be created.list
- The list of initial values of the properties of
the new managed object.InvocationTargetException
.public void newDBMO(java.lang.String impl, ObjectName name, ModificationList list) throws java.lang.IllegalAccessException, java.lang.ClassNotFoundException, InstanceAlreadyExistException, java.lang.InstantiationException, java.lang.reflect.InvocationTargetException
impl
- The name of the Java implementation to be used on the server.name
- The name of the managed object to be created.list
- The list of initial values of the properties of
the new managed object.InvocationTargetException
.public java.lang.Object cb_newMO(java.lang.String impl, ObjectName name, ModificationList list) throws java.lang.IllegalAccessException, java.lang.ClassNotFoundException, InstanceAlreadyExistException, java.lang.InstantiationException, LocalException, java.lang.reflect.InvocationTargetException
impl
- The name of the Java implementation to be used on the server.name
- The name of the managed object to be created.list
- The list of initial values of the properties of
the new managed object.LocalException
.InvocationTargetException
.public java.lang.Object cb_newDBMO(java.lang.String impl, ObjectName name, ModificationList list) throws java.lang.IllegalAccessException, java.lang.ClassNotFoundException, InstanceAlreadyExistException, java.lang.InstantiationException, LocalException, java.lang.reflect.InvocationTargetException
impl
- The name of the Java implementation to be used on the server.name
- The name of the managed object to be created.list
- The list of initial values of the properties of
the new managed object.LocalException
.InvocationTargetException
.public void newObj(java.lang.String className, ObjectName aLoader) throws java.lang.IllegalAccessException, java.lang.InstantiationException, java.lang.ClassNotFoundException, java.lang.reflect.InvocationTargetException
className
- The Java class name of the object to be created.aLoader
- The name of a class loader to be used.InvocationTargetException
.public void newMO(java.lang.String impl, ObjectName name, ModificationList list, ObjectName aLoader) throws java.lang.IllegalAccessException, java.lang.ClassNotFoundException, InstanceAlreadyExistException, java.lang.InstantiationException, java.lang.reflect.InvocationTargetException
impl
- The name of the Java implementation to be used
on the server.name
- The name of the managed object to be created.list
- The list of initial values of the properties of
the new managed object.aLoader
- The name of the class loader to be used.InvocationTargetException
.public void newDBMO(java.lang.String impl, ObjectName name, ModificationList list, ObjectName aLoader) throws java.lang.IllegalAccessException, java.lang.ClassNotFoundException, InstanceAlreadyExistException, java.lang.InstantiationException, java.lang.reflect.InvocationTargetException
impl
- The name of the Java implementation to be used
on the server.name
- The name of the managed object to be created.list
- The list of initial values of the properties of
the new managed object.aLoader
- The name of the class loader to be used.InvocationTargetException
.public java.lang.Object cb_newMO(java.lang.String impl, ObjectName name, ModificationList list, ObjectName aLoader) throws java.lang.IllegalAccessException, java.lang.ClassNotFoundException, InstanceAlreadyExistException, java.lang.InstantiationException, LocalException, java.lang.reflect.InvocationTargetException
impl
- The name of the Java implementation to be used
on the server.name
- The name of the managed object to be created.list
- The list of initial values of the properties of
the new managed object.aLoader
- The name of a class loader to be used.LocalException
.InvocationTargetException
.public java.lang.Object cb_newDBMO(java.lang.String impl, ObjectName name, ModificationList list, ObjectName aLoader) throws java.lang.IllegalAccessException, java.lang.ClassNotFoundException, InstanceAlreadyExistException, java.lang.InstantiationException, LocalException, java.lang.reflect.InvocationTargetException
impl
- The name of the Java implementation to be used
on the server.name
- The name of the managed object to be created.list
- The list of initial values of the properties of
the new managed object.aLoader
- The name of a class loader to be used.LocalException
.InvocationTargetException
.public void transferObject(java.lang.Object object, ObjectName logicalName) throws InstanceAlreadyExistException
Use this method with care, because it moves an instance remotely. All methods of this instance are executed locally on the remote agent.
object
- The object to be added to the remote repository.logicalName
- The logical name of the object.public void deleteMO(ObjectName name) throws InstanceNotFoundException, java.lang.reflect.InvocationTargetException
name
- The name of the managed object to be deleted.public java.lang.Object invokePerform(ObjectName objName, java.lang.String pfName, java.lang.Object[] params, java.lang.String[] signature) throws InstanceNotFoundException, java.lang.NoSuchMethodException, java.lang.reflect.InvocationTargetException, java.lang.IllegalAccessException
objName
- The name of the remote object.pfName
- The name of the method to be invoked.params
- An array containing the parameters to be passed to the method.signature
- The signature of the method to be invoked.InvocationTargetException
.public void cb_connect(ManagedObject cbean)
cbean
- The C-bean to be connectedpublic void cb_disconnect(ManagedObject cbean)
cbean
- The C-bean to be disconnected.public static java.lang.String getClassVersion()
public java.lang.String getAdaptorVersion()
public java.lang.String getDomain() throws CommunicationException
public java.lang.ClassLoader getClassLoader()
public void setClassLoader(java.lang.ClassLoader loader)
loader
- The instance of ClassLoader.public MapperSrvIf getMapperSrv()
public void setMapperSrv(MapperSrvIf mapper)
mapper
- The instance of mapping service to be used.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |