Class StatusDefinition


  • public class StatusDefinition
    extends java.lang.Object
    State Definition.

    Stores information about the time, it was switched on and provides an method to set this state.

    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      protected boolean isActive()
      Returns if this state is the active state.
      protected void switchOn()
      Switch on the state/it's referring relays.
      protected void updateActiveTime()
      Updates the time channel depending if the state is active or not.
      • Methods inherited from class java.lang.Object

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

      • switchOn

        protected void switchOn()
                         throws java.lang.IllegalArgumentException,
                                OpenemsError.OpenemsNamedException
        Switch on the state/it's referring relays.

        Forward its state to the parent changeState method, to set the corresponding relay outputs and the present state, if the state is not already active.

        Throws:
        OpenemsError.OpenemsNamedException - on error
        java.lang.IllegalArgumentException - on error
      • updateActiveTime

        protected void updateActiveTime()
        Updates the time channel depending if the state is active or not.
      • isActive

        protected boolean isActive()
        Returns if this state is the active state.
        Returns:
        Is this state active.