Class ChainedComponent

  • All Implemented Interfaces:
    com.yahoo.component.Component, java.lang.Comparable<com.yahoo.component.Component>

    public abstract class ChainedComponent
    extends com.yahoo.component.AbstractComponent
    Component with dependencies.
    Author:
    Tony Vaagenes
    • Field Summary

      • Fields inherited from class com.yahoo.component.AbstractComponent

        isDeconstructable
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      protected Dependencies getAnnotatedDependencies​(java.lang.Class<? extends java.lang.annotation.Annotation> providesClass, java.lang.Class<? extends java.lang.annotation.Annotation> beforeClass, java.lang.Class<? extends java.lang.annotation.Annotation> afterClass)  
      protected Dependencies getDefaultAnnotatedDependencies()
      This method is here only for legacy reasons, do not override.
      Dependencies getDependencies()
      Returns the configured and declared dependencies of this chainedcomponent
      void initDependencies​(Dependencies dependencies)
      Called by the container to assign the full set of dependencies to this class (configured and declared).
      • Methods inherited from class com.yahoo.component.AbstractComponent

        clone, compareTo, deconstruct, getClassName, getId, getIdString, hasInitializedId, initId, isDeconstructable, setIsDeconstructable, toString
      • Methods inherited from class java.lang.Object

        equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
    • Constructor Detail

      • ChainedComponent

        public ChainedComponent​(com.yahoo.component.ComponentId id)
      • ChainedComponent

        protected ChainedComponent()
    • Method Detail

      • initDependencies

        public void initDependencies​(Dependencies dependencies)
        Called by the container to assign the full set of dependencies to this class (configured and declared). This is called once before this is started.
        Parameters:
        dependencies - The configured dependencies, that this method will merge with annotated dependencies.
      • getDependencies

        public Dependencies getDependencies()
        Returns the configured and declared dependencies of this chainedcomponent
      • getDefaultAnnotatedDependencies

        protected Dependencies getDefaultAnnotatedDependencies()
        This method is here only for legacy reasons, do not override.
      • getAnnotatedDependencies

        protected Dependencies getAnnotatedDependencies​(java.lang.Class<? extends java.lang.annotation.Annotation> providesClass,
                                                        java.lang.Class<? extends java.lang.annotation.Annotation> beforeClass,
                                                        java.lang.Class<? extends java.lang.annotation.Annotation> afterClass)
        Parameters:
        providesClass - The annotation class representing 'provides'.
        beforeClass - The annotation class representing 'before'.
        afterClass - The annotation class representing 'after'.
        Returns:
        a new Dependencies created from the annotations given in this component's class.