Class AbstractPojoPhase

java.lang.Object
org.jboss.as.pojo.service.AbstractPojoPhase
All Implemented Interfaces:
org.jboss.msc.Service, org.jboss.msc.service.Service<Object>, org.jboss.msc.value.Value<Object>
Direct Known Subclasses:
ConfiguredPojoPhase, DescribedPojoPhase, InstalledPojoPhase, InstantiatedPojoPhase, LifecyclePojoPhase

public abstract class AbstractPojoPhase extends Object implements org.jboss.msc.service.Service<Object>
Abstract pojo phase; it handles install/uninstall
Author:
Ales Justin
  • Constructor Details

    • AbstractPojoPhase

      public AbstractPojoPhase()
  • Method Details

    • getLifecycleState

      protected abstract BeanState getLifecycleState()
    • createNextPhase

      protected abstract AbstractPojoPhase createNextPhase()
    • start

      public void start(org.jboss.msc.service.StartContext context) throws org.jboss.msc.service.StartException
      Specified by:
      start in interface org.jboss.msc.Service
      Throws:
      org.jboss.msc.service.StartException
    • startInternal

      protected void startInternal(org.jboss.msc.service.StartContext context) throws org.jboss.msc.service.StartException
      Throws:
      org.jboss.msc.service.StartException
    • registerAliases

      protected void registerAliases(org.jboss.msc.service.ServiceBuilder serviceBuilder, BeanState next)
    • getValue

      Specified by:
      getValue in interface org.jboss.msc.value.Value<Object>
      Throws:
      IllegalStateException
      IllegalArgumentException
    • stop

      public void stop(org.jboss.msc.service.StopContext context)
      Specified by:
      stop in interface org.jboss.msc.Service
    • stopInternal

      protected void stopInternal(org.jboss.msc.service.StopContext context)
    • createJoinpoint

      protected org.jboss.as.pojo.service.Joinpoint createJoinpoint(InstallConfig config)
    • executeInstalls

      protected void executeInstalls() throws org.jboss.msc.service.StartException
      Throws:
      org.jboss.msc.service.StartException
    • considerUninstalls

      protected void considerUninstalls(List<org.jboss.as.pojo.service.Joinpoint> uninstalls, int index)
      Consider the uninstalls.

      This method is here to be able to override the behavior after installs failed. e.g. perhaps only running uninstalls from the index.

      By default we run all uninstalls in the case at least one install failed.

      Parameters:
      uninstalls - the uninstalls
      index - current installs index
    • executeUninstalls

      protected void executeUninstalls()
    • addCallbacks

      protected void addCallbacks(boolean install)
    • removeCallbacks

      protected void removeCallbacks(boolean install)
    • getModule

      protected org.jboss.modules.Module getModule()
    • setModule

      protected void setModule(org.jboss.modules.Module module)
    • getBeanConfig

      protected BeanMetaDataConfig getBeanConfig()
    • getIndex

      protected org.jboss.as.server.deployment.reflect.DeploymentReflectionIndex getIndex()
    • setBeanConfig

      protected void setBeanConfig(BeanMetaDataConfig beanConfig)
    • setIndex

      protected void setIndex(org.jboss.as.server.deployment.reflect.DeploymentReflectionIndex index)
    • getBeanInfo

      protected BeanInfo getBeanInfo()
    • setBeanInfo

      protected void setBeanInfo(BeanInfo beanInfo)
    • getBean

      protected Object getBean()
    • setBean

      protected void setBean(Object bean)