private void callDefaultRemoveMethod(Object instance) { if ( hasDefaultRemoveMethod() ) { callComponentMethod( instance, getDefaultRemoveMethod() ); } }
public void callDestroyMethod(Object instance) { if ( hasDestroyMethod() ) { callComponentMethod( instance, getDestroyMethod() ); } }
public void callPreDestroyMethod(Object instance) { if ( hasPreDestroyMethod() ) { callComponentMethod( instance, getPreDestroyMethod() ); } }
public void callPostActivateMethod(Object instance) { if ( hasPostActivateMethod() ) { callComponentMethod( instance, getPostActivateMethod() ); } }
private Object unwrap(Object instance) { if ( hasUnwrapMethod() ) { return callComponentMethod( instance, getUnwrapMethod() ); } else { return instance; } }
public void callCreateMethod(Object instance) { if ( hasCreateMethod() ) { callComponentMethod( instance, getCreateMethod() ); } }
public void callPostConstructMethod(Object instance) { if ( hasPostConstructMethod() ) { callComponentMethod( instance, getPostConstructMethod() ); } }
public void callPrePassivateMethod(Object instance) { if ( hasPrePassivateMethod() ) { callComponentMethod( instance, getPrePassivateMethod() ); } }
private static Object createInstanceFromFactory(String name, ScopeType scope, Init.FactoryMethod factoryMethod, Object factory) { // check whether there has been created an instance by another thread // while waiting for this function's lock if (scope != STATELESS) { Object value = (scope == null) ? Contexts.lookupInStatefulContexts(name) : scope.getContext().get(name); if (value != null) { return value; } } if (factory == null) { return null; } else { Object result = factoryMethod.getComponent().callComponentMethod(factory, factoryMethod.getMethod()); return handleFactoryMethodResult(name, factoryMethod.getComponent(), result, factoryMethod.getScope()); } }
component.callComponentMethod(bean, component.getDestroyMethod());
observer.getComponent().callComponentMethod(listener, observer.getMethod(), parameters);