Package 

Class StunFailureEvent

  • All Implemented Interfaces:
    java.io.Serializable

    
    public class StunFailureEvent
    extends BaseStunMessageEvent
                        

    The class is used to dispatch events that occur when a STUN transaction fails asynchronously for reasons like a port unreachable exception for example.

    • Nested Class Summary

      Nested Classes 
      Modifier and Type Class Description
    • Field Summary

      Fields 
      Modifier and Type Field Description
      private final Throwable cause
    • Enum Constant Summary

      Enum Constants 
      Enum Constant Description
    • Method Summary

      Modifier and Type Method Description
      Throwable getCause() Returns the Exception that cause this failure or null if the failure is not related to an Exception.
      TransportAddress getLocalAddress() Returns the TransportAddress that the message was supposed to leave from.
      String toString() Returns a String representation of this event, containing the corresponding message, and local address.
      • Methods inherited from class org.ice4j.BaseStunMessageEvent

        getMessage, getStunStack, getTransactionID
      • Methods inherited from class java.util.EventObject

        getSource
      • Methods inherited from class java.lang.Object

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

      • StunFailureEvent

        StunFailureEvent(StunStack stunStack, Message message, TransportAddress localAddress, Throwable cause)
        Constructs a StunFailureEvent according to the specified message.
        Parameters:
        stunStack - the StunStack to be associated with the new instance
        message - the message itself
        localAddress - the local address that the message was sent from.
        cause - the Exception that caused this failure or null if there's no Exception associated with this failure
    • Method Detail

      • getCause

         Throwable getCause()

        Returns the Exception that cause this failure or null if the failure is not related to an Exception.

      • toString

         String toString()

        Returns a String representation of this event, containing the corresponding message, and local address.