Overview | Package | Class | Use | Tree | Deprecated | Index | Help
| Project Rio
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.jini.rio.core
Class ServiceBeanInstance

    java.lang.Object
      org.jini.rio.core.ServiceBeanInstance

All Implemented Interfaces:
  Serializable

    public class ServiceBeanInstance

extends Object
implements Serializable

This class indicates an instance of an instantiated ServiceBean

See Also:
  Serialized Form

Constructor Summary
`ServiceBeanInstance(Uuid identifier, MarshalledInstance mi, ServiceBeanConfig sbConfig)` Create a ServiceBeanInstance
`ServiceBeanInstance(Uuid identifier, MarshalledInstance mi, ServiceBeanConfig sbConfig, String hostAddress, Uuid instantiatorID)` Create a ServiceBeanInstance

Method Summary
`boolean` | `equals(Object obj)` A ServiceBeanInstance is equal to another ServiceBeanInstance if the service identifier properties are equal
`String` | `getHostAddress()` Get the IP address of the compute resource the service is executing on
`MarshalledInstance` | `getMarshalledInstance()` Get the MarshalledInstance
`Object` | `getService()` Get the object used to communicate to the ServiceBean
`ServiceBeanConfig` | `getServiceBeanConfig()` Get the ServiceBeanConfig for the ServiceBean
`Uuid` | `getServiceBeanID()` Get the unique identifier for the ServiceBean
`Uuid` | `getServiceBeanInstantiatorID()` Get the unique identifier for the ServiceBeanInstantiator
`int` | `hashCode()` Override hashCode to be the hash of the service identifier
`void` | `setServiceBeanConfig(ServiceBeanConfig sbConfig)` Set the ServiceBeanConfig for the ServiceBean
`String` | `toString()`

Methods inherited from class java.lang.Object
`clone, finalize, getClass, notify, notifyAll, wait, wait, wait`

Constructor Detail

### ServiceBeanInstance

    public ServiceBeanInstance(Uuid identifier,
                               MarshalledInstance mi,
                               ServiceBeanConfig sbConfig)

  Create a ServiceBeanInstance

  Parameters:
    `identifier` - Unique identifier for the ServiceBean
    `mi` - Object used to communicate to the ServiceBean
    `sbConfig` - ServiceBeanConfig object for the ServiceBean

### ServiceBeanInstance

    public ServiceBeanInstance(Uuid identifier,
                               MarshalledInstance mi,
                               ServiceBeanConfig sbConfig,
                               String hostAddress,
                               Uuid instantiatorID)

  Create a ServiceBeanInstance

  Parameters:
    `identifier` - Unique identifier for the ServiceBean
    `mi` - Object used to communicate to the ServiceBean
    `sbConfig` - ServiceBeanConfig object for the ServiceBean
    `hostAddress` - The hostAddress the service is executing on
    `instantiatorID` - The Unique identifier of the ServiceBeanInstantiator

Method Detail

### getServiceBeanID

    public Uuid getServiceBeanID()

  Get the unique identifier for the ServiceBean

  Returns:
    Unique identifier for the ServiceBean

### getServiceBeanInstantiatorID

    public Uuid getServiceBeanInstantiatorID()

  Get the unique identifier for the ServiceBeanInstantiator

  Returns:
    Unique identifier for the ServiceBeanInstantiator

### getMarshalledInstance

    public MarshalledInstance getMarshalledInstance()

  Get the MarshalledInstance

  Returns:
    The MarshalledInstance for the service proxy

### getService

    public Object getService()
                      throws IOException,
                             ClassNotFoundException

  Get the object used to communicate to the ServiceBean

  Returns:
    Object used to communicate to the ServiceBean
  Throws:
    `ClassNotFoundException` - If the class cannot be found when loading the service proxy
    `IOException` - As a result of de-marshalling the service proxy

### setServiceBeanConfig

    public void setServiceBeanConfig(ServiceBeanConfig sbConfig)

  Set the ServiceBeanConfig for the ServiceBean

  Parameters:
    `sbConfig` - The ServiceBeanConfig for the ServiceBean

### getServiceBeanConfig

    public ServiceBeanConfig getServiceBeanConfig()

  Get the ServiceBeanConfig for the ServiceBean

  Returns:
    The ServiceBeanConfig for the ServiceBean

### getHostAddress

    public String getHostAddress()

  Get the IP address of the compute resource the service is executing on

  Returns:
    The IP address of of the compute resource the service is executing on. This value may be null

### hashCode

    public int hashCode()

  Override hashCode to be the hash of the service identifier

  Overrides:
    `hashCode` in class `Object`

### equals

    public boolean equals(Object obj)

  A ServiceBeanInstance is equal to another ServiceBeanInstance if the service identifier properties are equal

  Overrides:
    `equals` in class `Object`

### toString

    public String toString()

  Overrides:
    `toString` in class `Object`

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
| Project Rio
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © Project Rio.