Class UdpMessenger

java.lang.Object
java.lang.Thread
org.metricshub.ipmi.core.transport.UdpMessenger
All Implemented Interfaces:
Runnable, Messenger

public class UdpMessenger extends Thread implements Messenger
Handles the UDP connection.
  • Constructor Details

    • UdpMessenger

      public UdpMessenger(int port) throws SocketException, UnknownHostException
      Initiates UdpMessenger, binds it to the specified port and starts listening. Wildcard IP address will be used.
      Parameters:
      port - - port to bind socket to.
      Throws:
      SocketException - if the socket could not be opened, or the socket could not bind to the specified local port.
      UnknownHostException
    • UdpMessenger

      public UdpMessenger(int port, InetAddress address) throws SocketException
      Initiates UdpMessenger, binds it to the specified port and IP address and starts listening.
      Parameters:
      port - - port to bind socket to.
      address - - IP address to bind socket to.
      Throws:
      SocketException - if the socket could not be opened, or the socket could not bind to the specified local port.
  • Method Details