Class SmeHelloState


  • public class SmeHelloState
    extends State
    • Method Detail

      • init

        public void init()
        Specified by:
        init in class State
      • startWFRTimer

        public void startWFRTimer()
      • startSendProlongationReqTimer

        public void startSendProlongationReqTimer​(int timeout)
      • startProlongationReqReplyTimer

        public void startProlongationReqReplyTimer()
      • setWaitForReady

        public void setWaitForReady​(TimeoutTimer waitForReady)
      • getSendProlongationReq

        public TimeoutTimer getSendProlongationReq()
      • getProlongationReqReply

        public TimeoutTimer getProlongationReqReply()
      • deactivateTimer

        public void deactivateTimer​(TimeoutTimer timeoutTimer)
      • processMsg

        public void processMsg​(byte[] msg)
        Specified by:
        processMsg in class State
      • nextState

        protected void nextState()
        Specified by:
        nextState in class State
      • timedOut

        protected void timedOut​(TimeoutTimer timeoutTimer)
        on timeout set timeout state depending on current phase and do the timeout procedure.
        Specified by:
        timedOut in class State
        Parameters:
        timeoutTimer - the timed out timeout timer
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object
      • commonAbort

        public void commonAbort()
      • incomingProlongReq

        public void incomingProlongReq()
      • calculateWFRLeft

        protected int calculateWFRLeft​(long waitForReadyElapsed)
        helper method, calculates how much time is left until the waitForReady-timer times out, for "hello"-messages
        Parameters:
        waitForReadyElapsed - the elapsed time of the waitForReady-timer in millis
        Returns:
        T_hello_inc-value in millis minus waitForReadyElapsed
      • switchToReady

        public void switchToReady()
        switch from basic state PENDING to READY. Should only be used right after authentication of communication partner.
      • getLastReceivedMsg

        public HelloMsg getLastReceivedMsg()
      • setLastReceivedMsg

        public void setLastReceivedMsg​(HelloMsg lastReceivedMsg)
      • getAcceptedProlongationRequests

        public int getAcceptedProlongationRequests()
      • getT_hello_init

        public int getT_hello_init()
      • getT_hello_inc

        public int getT_hello_inc()
      • getT_hello_prolong_thr_inc

        public int getT_hello_prolong_thr_inc()
      • getT_hello_prolong_waiting_gap

        public int getT_hello_prolong_waiting_gap()
      • getT_hello_prolong_min

        public int getT_hello_prolong_min()