Savarese.Org HomeORO HomeSavarese.Org/ORO Logo

com.oroinc.net
Interface DatagramSocketFactory

All Known Implementing Classes:
DefaultDatagramSocketFactory

public interface DatagramSocketFactory

The DatagramSocketFactory interface provides a means for the programmer to control the creation of datagram sockets and provide his own DatagramSocket implementations for use by all classes derived from DatagramSocketClient . This allows you to provide your own DatagramSocket implementations and to perform security checks or browser capability requests before creating a DatagramSocket.

Author:
Daniel F. Savarese

Method Summary
 java.net.DatagramSocket createDatagramSocket()
          Creates a DatagramSocket on the local host at the first available port.
 java.net.DatagramSocket createDatagramSocket(int port)
          Creates a DatagramSocket on the local host at a specified port.
 java.net.DatagramSocket createDatagramSocket(int port, java.net.InetAddress laddr)
          Creates a DatagramSocket at the specified address on the local host at a specified port.
 

Method Detail

createDatagramSocket

public java.net.DatagramSocket createDatagramSocket()
                                             throws java.net.SocketException
Creates a DatagramSocket on the local host at the first available port.

Throws:
java.net.SocketException - If the socket could not be created.

createDatagramSocket

public java.net.DatagramSocket createDatagramSocket(int port)
                                             throws java.net.SocketException
Creates a DatagramSocket on the local host at a specified port.

Parameters:
port - The port to use for the socket.
Throws:
java.net.SocketException - If the socket could not be created.

createDatagramSocket

public java.net.DatagramSocket createDatagramSocket(int port,
                                                    java.net.InetAddress laddr)
                                             throws java.net.SocketException
Creates a DatagramSocket at the specified address on the local host at a specified port.

Parameters:
port - The port to use for the socket.
laddr - The local address to use.
Throws:
java.net.SocketException - If the socket could not be created.

Savarese.Org HomeORO HomeSavarese.Org/ORO Logo

Copyright © 1997-2002 Daniel F. Savarese. All Rights Reserved.