Class Stage

java.lang.Object
com.genologics.ri.stage.Stage
All Implemented Interfaces:
Linkable<Stage>, Locatable, Serializable

public class Stage extends Object implements Linkable<Stage>, Serializable
The detailed representation of a workflow stage.

A stage represents a step within a workflow in the Clarity LIMS system. Each stage is associated with a specific workflow, protocol, and protocol step. Stages define the sequence of operations that samples or artifacts undergo during laboratory processing.

This class provides access to the stage's name, index within its workflow, and links to the associated workflow, protocol, and protocol step entities.

See Also:
  • Field Details

    • ID_EXTRACTOR_PATTERN

      public static final Pattern ID_EXTRACTOR_PATTERN
      Regular expression pattern to extract workflow id and workflow stage id from a workflow stage URI. This pattern is constructed from the URI sections defined in the ClarityEntity annotations.
      Since:
      2.22
    • workflow

      protected WorkflowLink workflow
      Link to the workflow this stage belongs to.
    • protocol

      protected ProtocolLink protocol
      Link to the protocol for this stage.
    • step

      protected ProtocolStepLink step
      Link to the protocol step for this stage.
    • uri

      protected URI uri
      The URI of the stage.
    • name

      protected String name
      The name of the stage.
    • index

      protected Integer index
      The index of the stage in the workflow.
  • Constructor Details

    • Stage

      public Stage()
      Default constructor.
    • Stage

      public Stage(URI uri)
      Constructor with URI.
      Parameters:
      uri - The URI of the stage.
    • Stage

      public Stage(URI uri, String name)
      Constructor with URI and name.
      Parameters:
      uri - The URI of the stage.
      name - The name of the stage.
  • Method Details

    • getId

      public Integer getId()
      Gets the numeric identifier for this workflow stage from its URI.
      Returns:
      The workflow stage id, or null if either the URI is not set or it doesn't match the form expected for a workflow stage URI.
      Since:
      2.22
    • getWorkflowId

      public Integer getWorkflowId()
      Gets the numeric identifier for this stage's workflow from its URI.
      Returns:
      The workflow id, or null if either the URI is not set or it doesn't match the form expected for a workflow stage URI.
      Since:
      2.22
    • getWorkflow

      public WorkflowLink getWorkflow()
      Gets the workflow link for this stage.
      Returns:
      The workflow link.
    • setWorkflow

      public void setWorkflow(Linkable<Workflow> workflow)
      Sets the workflow for this stage.
      Parameters:
      workflow - The linkable workflow object to set.
    • getProtocol

      public ProtocolLink getProtocol()
      Gets the protocol link for this stage.
      Returns:
      The protocol link.
    • setProtocol

      public void setProtocol(Linkable<Protocol> protocol)
      Sets the protocol for this stage.
      Parameters:
      protocol - The linkable protocol object to set.
    • getStep

      public ProtocolStepLink getStep()
      Gets the protocol step link for this stage.
      Returns:
      The protocol step link.
    • setStep

      public void setStep(Linkable<ProtocolStep> step)
      Sets the protocol step for this stage.
      Parameters:
      step - The linkable protocol step object to set.
    • getUri

      public URI getUri()
      Gets the URI of the stage.
      Specified by:
      getUri in interface Locatable
      Returns:
      The URI of the stage.
    • setUri

      public void setUri(URI uri)
      Sets the URI of the stage.
      Specified by:
      setUri in interface Locatable
      Parameters:
      uri - The URI of the stage.
    • getName

      public String getName()
      Gets the name of the stage.
      Returns:
      The name of the stage.
    • setName

      public void setName(String name)
      Sets the name of the stage.
      Parameters:
      name - The name of the stage.
    • getIndex

      public Integer getIndex()
      Gets the index of the stage in the workflow.
      Returns:
      The index of the stage.
    • setIndex

      public void setIndex(Integer index)
      Sets the index of the stage in the workflow.
      Parameters:
      index - The index of the stage.
    • getLink

      public LimsLink<Stage> getLink()
      Gets a link to this stage entity.
      Specified by:
      getLink in interface Linkable<Stage>
      Returns:
      A new StageLink referencing this stage.