Package akka.actor

Class FSM.State<S,​D>

  • All Implemented Interfaces:
    java.io.Serializable, scala.Equals, scala.Product
    Direct Known Subclasses:
    FSM.SilentState
    Enclosing interface:
    FSM<S,​D>

    public static class FSM.State<S,​D>
    extends java.lang.Object
    implements scala.Product, java.io.Serializable
    See Also:
    Serialized Form
    • Constructor Summary

      Constructors 
      Constructor Description
      State​(S stateName, D stateData, scala.Option<scala.concurrent.duration.FiniteDuration> timeout, scala.Option<FSM.Reason> stopReason, scala.collection.immutable.List<java.lang.Object> replies)  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      boolean canEqual​(java.lang.Object that)  
      FSM.State<S,​D> copy​(S stateName, D stateData, scala.Option<scala.concurrent.duration.FiniteDuration> timeout, scala.Option<FSM.Reason> stopReason, scala.collection.immutable.List<java.lang.Object> replies)  
      S copy$default$1()  
      D copy$default$2()  
      scala.Option<scala.concurrent.duration.FiniteDuration> copy$default$3()  
      scala.Option<FSM.Reason> copy$default$4()  
      scala.collection.immutable.List<java.lang.Object> copy$default$5()  
      boolean equals​(java.lang.Object that)  
      FSM.State<S,​D> forMax​(java.time.Duration timeout)
      JAVA API: Modify state transition descriptor to include a state timeout for the next state.
      FSM.State<S,​D> forMax​(scala.concurrent.duration.Duration timeout)
      Modify state transition descriptor to include a state timeout for the next state.
      int productArity()  
      java.lang.Object productElement​(int n)  
      java.lang.String productPrefix()  
      scala.collection.immutable.List<java.lang.Object> replies()  
      FSM.State<S,​D> replying​(java.lang.Object replyValue)
      Send reply to sender of the current message, if available.
      D stateData()  
      S stateName()  
      scala.Option<FSM.Reason> stopReason()  
      scala.Option<scala.concurrent.duration.FiniteDuration> timeout()  
      FSM.State<S,​D> using​(D nextStateData)
      Modify state transition descriptor with new state data.
      • Methods inherited from class java.lang.Object

        clone, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
      • Methods inherited from interface scala.Product

        productElementName, productElementNames, productIterator
    • Constructor Detail

      • State

        public State​(S stateName,
                     D stateData,
                     scala.Option<scala.concurrent.duration.FiniteDuration> timeout,
                     scala.Option<FSM.Reason> stopReason,
                     scala.collection.immutable.List<java.lang.Object> replies)
    • Method Detail

      • stateName

        public S stateName()
      • stateData

        public D stateData()
      • timeout

        public scala.Option<scala.concurrent.duration.FiniteDuration> timeout()
      • stopReason

        public scala.Option<FSM.Reason> stopReason()
      • replies

        public scala.collection.immutable.List<java.lang.Object> replies()
      • canEqual

        public boolean canEqual​(java.lang.Object that)
        Specified by:
        canEqual in interface scala.Equals
      • equals

        public boolean equals​(java.lang.Object that)
        Specified by:
        equals in interface scala.Equals
        Overrides:
        equals in class java.lang.Object
      • productPrefix

        public java.lang.String productPrefix()
        Specified by:
        productPrefix in interface scala.Product
      • productArity

        public int productArity()
        Specified by:
        productArity in interface scala.Product
      • productElement

        public java.lang.Object productElement​(int n)
        Specified by:
        productElement in interface scala.Product
      • copy

        public FSM.State<S,​D> copy​(S stateName,
                                         D stateData,
                                         scala.Option<scala.concurrent.duration.FiniteDuration> timeout,
                                         scala.Option<FSM.Reason> stopReason,
                                         scala.collection.immutable.List<java.lang.Object> replies)
      • copy$default$1

        public S copy$default$1()
      • copy$default$2

        public D copy$default$2()
      • copy$default$3

        public scala.Option<scala.concurrent.duration.FiniteDuration> copy$default$3()
      • copy$default$4

        public scala.Option<FSM.Reason> copy$default$4()
      • copy$default$5

        public scala.collection.immutable.List<java.lang.Object> copy$default$5()
      • forMax

        public FSM.State<S,​D> forMax​(scala.concurrent.duration.Duration timeout)
        Modify state transition descriptor to include a state timeout for the next state. This timeout overrides any default timeout set for the next state.

        Use Duration.Inf to deactivate an existing timeout.

      • forMax

        public FSM.State<S,​D> forMax​(java.time.Duration timeout)
        JAVA API: Modify state transition descriptor to include a state timeout for the next state. This timeout overrides any default timeout set for the next state.

        Use Duration.Inf to deactivate an existing timeout.

      • replying

        public FSM.State<S,​D> replying​(java.lang.Object replyValue)
        Send reply to sender of the current message, if available.

        Returns:
        this state transition descriptor
      • using

        public FSM.State<S,​D> using​(D nextStateData)
        Modify state transition descriptor with new state data. The data will be set when transitioning to the new state.