Class PlanImpl

    • Nested Class Summary

      Nested Classes 
      Modifier and Type Class Description
      static class  PlanImpl.Builder  
    • Constructor Summary

      Constructors 
      Modifier Constructor Description
      protected PlanImpl()  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void activate()
      Begin processing.
      void deactivate()
      Stop processing.
      Step findStep​(java.lang.String stepName)
      Locate the step in the plan that has the given name.
      java.lang.String getDocIdField()
      This is the field that is to be used as a docId
      Step[] getExecutableSteps()
      Get the subset of steps that will execute when the plan is activated.
      java.lang.String getName()
      A name for this object to distinguish it from other objects.
      Step[] getSteps()
      Return every Step in the plan regardless of whether it will be executing when the plan is activated
      int getVersion()
      A (usually serially incremented) version identifier for a plan.
      boolean isActive()
      Test to see if the object is active
      guru.nidi.graphviz.engine.Renderer visualize​(guru.nidi.graphviz.engine.Format format)
      Produce an image visualization of this plan
      • Methods inherited from class java.lang.Object

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

      • PlanImpl

        protected PlanImpl()
    • Method Detail

      • getSteps

        public Step[] getSteps()
        Description copied from interface: Plan
        Return every Step in the plan regardless of whether it will be executing when the plan is activated
        Specified by:
        getSteps in interface Plan
        Returns:
        All steps
      • getExecutableSteps

        public Step[] getExecutableSteps()
        Description copied from interface: Plan
        Get the subset of steps that will execute when the plan is activated. This should be a continuous set of steps that can be traversed in total via Step.getNextSteps(Document).
        Specified by:
        getExecutableSteps in interface Plan
        Returns:
        an Array of steps in the plan that will be executed
      • getDocIdField

        public java.lang.String getDocIdField()
        Description copied from interface: Plan
        This is the field that is to be used as a docId
        Specified by:
        getDocIdField in interface Plan
        Returns:
        usually "id" but some legacy indexes may need to use something else
      • findStep

        public Step findStep​(java.lang.String stepName)
        Description copied from interface: Plan
        Locate the step in the plan that has the given name. All steps in the plan must have a unique name.
        Specified by:
        findStep in interface Plan
        Parameters:
        stepName - the name of the step to find
        Returns:
        the step if found or null if the name does not match any steps.
      • visualize

        public guru.nidi.graphviz.engine.Renderer visualize​(guru.nidi.graphviz.engine.Format format)
        Description copied from interface: Plan
        Produce an image visualization of this plan
        Specified by:
        visualize in interface Plan
        Parameters:
        format - the format that should be rendered
        Returns:
        An image visualizing the plan as a directed graph.
      • getVersion

        public int getVersion()
        Description copied from interface: Plan
        A (usually serially incremented) version identifier for a plan. Changing the version of the plan indicates that the processing has changed substantially, and that prior indexing no longer is considered to have produced the desired output. The practical implication of changing the plan version is that all documents will become eligible for re-indexing.
        Specified by:
        getVersion in interface Plan
        Returns:
        a numeric identifier which changes when prior indexing is invalidated and there is a need for re-indexing. Monotonically increasing positive numbers are recommended but not absolutely required.
      • activate

        public void activate()
        Description copied from interface: Active
        Begin processing. This is the on switch.
        Specified by:
        activate in interface Active
      • deactivate

        public void deactivate()
        Description copied from interface: Active
        Stop processing. This is the stop switch.
        Specified by:
        deactivate in interface Active
      • isActive

        public boolean isActive()
        Description copied from interface: Active
        Test to see if the object is active
        Specified by:
        isActive in interface Active
        Returns:
        true if actively processing false otherwise.
      • getName

        public java.lang.String getName()
        Description copied from interface: Configurable
        A name for this object to distinguish it from other objects. This value is generally supplied by the plan author. Every object in a plan must have a unique name, begin with a letter and only contain letters, digits, underscores and periods.
        Specified by:
        getName in interface Configurable
        Returns:
        The user supplied name for this step