org.springframework.jmx.support
Class MBeanServerConnectionFactoryBean.MBeanServerConnectionLazyInitTargetSource

java.lang.Object
  extended by org.springframework.aop.target.AbstractLazyCreationTargetSource
      extended by org.springframework.jmx.support.MBeanServerConnectionFactoryBean.MBeanServerConnectionLazyInitTargetSource
All Implemented Interfaces:
TargetClassAware, TargetSource
Enclosing class:
MBeanServerConnectionFactoryBean

private class MBeanServerConnectionFactoryBean.MBeanServerConnectionLazyInitTargetSource
extends AbstractLazyCreationTargetSource

Lazily creates an MBeanServerConnection.


Field Summary
 
Fields inherited from class org.springframework.aop.target.AbstractLazyCreationTargetSource
logger
 
Constructor Summary
private MBeanServerConnectionFactoryBean.MBeanServerConnectionLazyInitTargetSource()
           
 
Method Summary
protected  java.lang.Object createObject()
          Subclasses should implement this method to return the lazy initialized object.
 java.lang.Class<?> getTargetClass()
          This default implementation returns null if the target is null (it is hasn't yet been initialized), or the target class if the target has already been initialized.
 
Methods inherited from class org.springframework.aop.target.AbstractLazyCreationTargetSource
getTarget, isInitialized, isStatic, releaseTarget
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

MBeanServerConnectionFactoryBean.MBeanServerConnectionLazyInitTargetSource

private MBeanServerConnectionFactoryBean.MBeanServerConnectionLazyInitTargetSource()
Method Detail

createObject

protected java.lang.Object createObject()
                                 throws java.lang.Exception
Description copied from class: AbstractLazyCreationTargetSource
Subclasses should implement this method to return the lazy initialized object. Called the first time the proxy is invoked.

Specified by:
createObject in class AbstractLazyCreationTargetSource
Returns:
the created object
Throws:
java.lang.Exception - if creation failed

getTargetClass

public java.lang.Class<?> getTargetClass()
Description copied from class: AbstractLazyCreationTargetSource
This default implementation returns null if the target is null (it is hasn't yet been initialized), or the target class if the target has already been initialized.

Subclasses may wish to override this method in order to provide a meaningful value when the target is still null.

Specified by:
getTargetClass in interface TargetClassAware
Specified by:
getTargetClass in interface TargetSource
Overrides:
getTargetClass in class AbstractLazyCreationTargetSource
Returns:
the type of targets returned by this TargetSource
See Also:
AbstractLazyCreationTargetSource.isInitialized()