org.apache.geronimo.connector
Class AdminObjectWrapper

java.lang.Object
  extended by org.apache.geronimo.connector.AdminObjectWrapper

public class AdminObjectWrapper
extends java.lang.Object

Wrapper around AdminObject that manages the AdminObject lifecycle.

Version:
$Rev: 1005848 $ $Date: 2010-10-08 22:44:55 +0800 (Fri, 08 Oct 2010) $

Field Summary
protected  java.lang.Object adminObject
           
protected  ResourceAdapterWrapper resourceAdapterWrapper
           
 
Constructor Summary
AdminObjectWrapper(java.lang.String adminObjectInterface, java.lang.String adminObjectClass, ResourceAdapterWrapper resourceAdapterWrapper, java.lang.ClassLoader cl, javax.validation.ValidatorFactory validatorFactory)
          Normal managed constructor.
 
Method Summary
 void doFail()
          Fails the target.
 void doStart()
          Starts the AdminObject.
 void doStop()
          Stops the target.
 java.lang.String getAdminObjectClass()
          Returns class of wrapped AdminObject.
 java.lang.String getAdminObjectInterface()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

resourceAdapterWrapper

protected ResourceAdapterWrapper resourceAdapterWrapper

adminObject

protected java.lang.Object adminObject
Constructor Detail

AdminObjectWrapper

public AdminObjectWrapper(java.lang.String adminObjectInterface,
                          java.lang.String adminObjectClass,
                          ResourceAdapterWrapper resourceAdapterWrapper,
                          java.lang.ClassLoader cl,
                          javax.validation.ValidatorFactory validatorFactory)
                   throws java.lang.IllegalAccessException,
                          java.lang.InstantiationException,
                          java.lang.ClassNotFoundException
Normal managed constructor.

Parameters:
adminObjectInterface - Interface the proxy will implement.
adminObjectClass - Class of admin object to be wrapped.
Throws:
java.lang.IllegalAccessException
java.lang.InstantiationException
java.lang.ClassNotFoundException
Method Detail

getAdminObjectInterface

public java.lang.String getAdminObjectInterface()

getAdminObjectClass

public java.lang.String getAdminObjectClass()
Returns class of wrapped AdminObject.

Returns:
class of wrapped AdminObject

doStart

public void doStart()
             throws java.lang.Exception
Starts the AdminObject. This will validate the instance and register the object instance with its ResourceAdapter

Throws:
java.lang.Exception - if the target failed to start; this will cause a transition to the failed state

doStop

public void doStop()
            throws java.lang.Exception
Stops the target. This is a NOP for AdminObjects

Throws:
java.lang.Exception - if the target failed to stop; this will cause a transition to the failed state

doFail

public void doFail()
Fails the target. This is a nop for an AdminObject.



Copyright © 2003-2011 The Apache Software Foundation. All Rights Reserved.