Interface POAPolicyMediator

All Known Implementing Classes:
POAPolicyMediatorBase, POAPolicyMediatorBase_R, POAPolicyMediatorImpl_NR_UDS, POAPolicyMediatorImpl_NR_USM, POAPolicyMediatorImpl_R_AOM, POAPolicyMediatorImpl_R_UDS, POAPolicyMediatorImpl_R_USM

public interface POAPolicyMediator
POAPolicyMediator defines an interface to which the POA delegates all policy specific operations. This permits code paths for different policies to be optimized by creating the correct code at POA creation time. Also note that as much as possible, this interface does not do any concurrency control, except as noted. The POA is responsible for concurrency control.
  • Method Details

    • getPolicies

      Policies getPolicies()
      Return the policies object that was used to create this POAPolicyMediator.
    • getScid

      int getScid()
      Return the subcontract ID to use in the IIOP profile in IORs created by this POAPolicyMediator's POA. This is initialized according to the policies and the POA used to construct this POAPolicyMediator in the POAPolicyMediatorFactory.
    • getServerId

      int getServerId()
      Return the server ID to use in the IIOP profile in IORs created by this POAPolicyMediator's POA. This is initialized according to the policies and the POA used to construct this POAPolicyMediator in the POAPolicyMediatorFactory.
    • getInvocationServant

      Object getInvocationServant(byte[] id, String operation) throws ForwardRequest
      Get the servant to use for an invocation with the given id and operation.
      Parameters:
      id - the object ID for which we are requesting a servant
      operation - the name of the operation to be performed on the servant
      Returns:
      the resulting Servant.
      Throws:
      ForwardRequest
    • returnServant

      void returnServant()
      Release a servant that was obtained from getInvocationServant.
    • etherealizeAll

      void etherealizeAll()
      Etherealize all servants associated with this POAPolicyMediator. Does nothing if the retention policy is non-retain.
    • clearAOM

      void clearAOM()
      Delete everything in the active object map.
    • getServantManager

      ServantManager getServantManager() throws WrongPolicy
      Return the servant manager. Will throw WrongPolicy if the request processing policy is not USE_SERVANT_MANAGER.
      Throws:
      WrongPolicy
    • setServantManager

      void setServantManager(ServantManager servantManager) throws WrongPolicy
      Set the servant manager. Will throw WrongPolicy if the request processing policy is not USE_SERVANT_MANAGER.
      Throws:
      WrongPolicy
    • getDefaultServant

      Servant getDefaultServant() throws NoServant, WrongPolicy
      Return the default servant. Will throw WrongPolicy if the request processing policy is not USE_DEFAULT_SERVANT.
      Throws:
      NoServant
      WrongPolicy
    • setDefaultServant

      void setDefaultServant(Servant servant) throws WrongPolicy
      Set the default servant. Will throw WrongPolicy if the request processing policy is not USE_DEFAULT_SERVANT.
      Throws:
      WrongPolicy
    • activateObject

      void activateObject(byte[] id, Servant servant) throws ObjectAlreadyActive, ServantAlreadyActive, WrongPolicy
      Throws:
      ObjectAlreadyActive
      ServantAlreadyActive
      WrongPolicy
    • deactivateObject

      Servant deactivateObject(byte[] id) throws ObjectNotActive, WrongPolicy
      Deactivate the object that is associated with the given id. Returns the servant for id.
      Throws:
      ObjectNotActive
      WrongPolicy
    • newSystemId

      byte[] newSystemId() throws WrongPolicy
      Allocate a new, unique system ID. Requires the ID assignment policy to be SYSTEM.
      Throws:
      WrongPolicy
    • servantToId

      byte[] servantToId(Servant servant) throws ServantNotActive, WrongPolicy
      Throws:
      ServantNotActive
      WrongPolicy
    • idToServant

      Servant idToServant(byte[] id) throws ObjectNotActive, WrongPolicy
      Throws:
      ObjectNotActive
      WrongPolicy