Package 

Class NetAccessManager

  • All Implemented Interfaces:
    org.ice4j.stack.ErrorHandler

    
    public class NetAccessManager
     implements ErrorHandler
                        

    Manages Connectors and MessageProcessingTask execution and pooling. This class serves as a layer that masks network primitives and provides equivalent STUN abstractions. Instances that operate with the NetAccessManager are only supposed to understand STUN talk and shouldn't be aware of datagrams sockets, and etc.

    • Field Summary

      Fields 
      Modifier and Type Field Description
    • Constructor Summary

      Constructors 
      Constructor Description
    • Enum Constant Summary

      Enum Constants 
      Enum Constant Description
    • Method Summary

      Modifier and Type Method Description
      PeerUdpMessageEventHandler getUdpMessageEventHandler() Gets the PeerUdpMessageEventHandler of this NetAccessManager which is to be notified when incoming UDP messages have been processed and are ready for delivery.
      ChannelDataEventHandler getChannelDataMessageEventHandler() Gets the ChannelDataEventHandler of this NetAccessManager which is to be notified when incoming ChannelData messages have been processed and are ready for delivery.
      void handleError(String message, Throwable error) A civilized way of not caring!
      void handleFatalError(Runnable callingThread, String message, Throwable error) Clears the faulty thread and reports the problem.
      void stop() Stops NetAccessManager and all of its active MessageProcessingTask.
      • Methods inherited from class java.lang.Object

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

    • Method Detail

      • handleError

         void handleError(String message, Throwable error)

        A civilized way of not caring!

        Parameters:
        message - a description of the error
        error - the error that has occurred
      • handleFatalError

         void handleFatalError(Runnable callingThread, String message, Throwable error)

        Clears the faulty thread and reports the problem.

        Parameters:
        callingThread - the thread where the error occurred.
        message - A description of the error
        error - The error itself
      • stop

         void stop()

        Stops NetAccessManager and all of its active MessageProcessingTask.