Interface ComponentHealthCondition

All Known Implementing Classes:
ActiveMQServerCondition, ComponentHealthConditionBase, DAServerCondition, EnumPositionCondition, IspybServiceCondition, MalcolmProcessCondition, ProcessingServerCondition, RateLimitedServerCondition, ScannableHealthCondition, ScannableThresholdCondition, ServerCondition

public interface ComponentHealthCondition
This represents a condition on a component of the beamline which contributes to its overall health.
It could for example check whether a scannable is within an acceptable range, or whether a required service is running.
  • Method Summary

    Modifier and Type
    Method
    Description
    Return the current state of the component.
    For a scannable, this would be its position: for a service, it could indicate whether it is running, paused etc.
    Return a user-friendly description of the component e.g.
    Return a message that can be displayed to the user is the corresponding condition is not met
    Return the health state for this component, based on the condition itself and whether it is critical for the functioning of the beamline.
    boolean
    Indicate whether this is critical for the overall health of the beamline
    boolean
    Indicates whether the condition is enabled.
    void
    setCritical(boolean critical)
     
    void
    setDescription(String description)
     
    void
    setEnabled(boolean enabled)
     
    void
    setErrorMessage(String errorMessage)
     
  • Method Details

    • getCurrentState

      String getCurrentState()
      Return the current state of the component.
      For a scannable, this would be its position: for a service, it could indicate whether it is running, paused etc.
    • getHealthState

      BeamlineHealthState getHealthState()
      Return the health state for this component, based on the condition itself and whether it is critical for the functioning of the beamline.
    • getDescription

      String getDescription()
      Return a user-friendly description of the component e.g. for display in the GUI
    • setDescription

      void setDescription(String description)
    • getErrorMessage

      String getErrorMessage()
      Return a message that can be displayed to the user is the corresponding condition is not met
    • setErrorMessage

      void setErrorMessage(String errorMessage)
    • isCritical

      boolean isCritical()
      Indicate whether this is critical for the overall health of the beamline
    • setCritical

      void setCritical(boolean critical)
    • isEnabled

      boolean isEnabled()
      Indicates whether the condition is enabled.
    • setEnabled

      void setEnabled(boolean enabled)