org.jboss.mx.remoting
Class MBeanServerLocator

java.lang.Object
  extended byorg.jboss.mx.remoting.MBeanServerLocator
All Implemented Interfaces:
java.io.Serializable

public class MBeanServerLocator
extends java.lang.Object
implements java.io.Serializable

MBeanServerLocator is an object that is used to identify and locate an MBeanServer on the network via JMX Remoting.

The MBeanServerLocator can be serialized and passed across the network, as long as the target server has access back to the MBeanServer via JMX Remoting Connector and has been detected by a JMX Remoting Detector.

See Also:
Serialized Form

Field Summary
protected  MBeanServer (src) server
           
 
Constructor Summary
MBeanServerLocator(Identity (src)  identity)
           
 
Method Summary
 boolean equals(java.lang.Object obj)
           
 java.net.InetAddress getAddress()
          return the InetAddress for the MBeanServer
 Identity (src) getIdentity()
          return the identity of the server
 java.lang.String getInstanceId()
          return the MBeanServer InstanceID
 MBeanServer (src) getMBeanServer()
          return a proxy to the MBeanServer
 java.lang.String getServerId()
          return the MBeanServer ID
 int hashCode()
           
protected  MBeanServer (src) resolveServer()
          try and resolve the serverid to a MBeanServer instance or proxy to a remote server
 void setAutoLocate(boolean autoLocate)
          set true (default) to automatically locate the appropriate MBeanServer on deserialization or false to only locate on demand to the call to getMBeanServer.
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

server

protected transient MBeanServer (src)  server
Constructor Detail

MBeanServerLocator

public MBeanServerLocator(Identity (src)  identity)
Method Detail

hashCode

public int hashCode()

equals

public boolean equals(java.lang.Object obj)

toString

public java.lang.String toString()

getServerId

public java.lang.String getServerId()
return the MBeanServer ID

Returns:

getIdentity

public final Identity (src)  getIdentity()
return the identity of the server

Returns:

getInstanceId

public java.lang.String getInstanceId()
return the MBeanServer InstanceID

Returns:

getAddress

public java.net.InetAddress getAddress()
return the InetAddress for the MBeanServer

Returns:

getMBeanServer

public MBeanServer (src)  getMBeanServer()
return a proxy to the MBeanServer

Returns:

resolveServer

protected MBeanServer (src)  resolveServer()
                             throws ConnectionFailedException (src) 
try and resolve the serverid to a MBeanServer instance or proxy to a remote server

Returns:
Throws:
ConnectionFailedException (src)

setAutoLocate

public void setAutoLocate(boolean autoLocate)
set true (default) to automatically locate the appropriate MBeanServer on deserialization or false to only locate on demand to the call to getMBeanServer.

Parameters:
autoLocate -