Java Platform 1.2

Uses of Class
java.net.InetAddress

Packages that use InetAddress
java.lang Provides classes that are fundamental to the design of the Java programming language. 
java.net Provides the classes for implementing networking applications. 
 

Uses of InetAddress in java.lang
 

Methods in java.lang with parameters of type InetAddress
 void SecurityManager.checkMulticast(InetAddress maddr)
          Throws a SecurityException if the calling thread is not allowed to use (join/leave/send/receive) IP multicast.
 void SecurityManager.checkMulticast(InetAddress maddr, byte ttl)
          Throws a SecurityException if the calling thread is not allowed to use (join/leave/send/receive) IP multicast.
 

Uses of InetAddress in java.net
 

Fields in java.net declared as InetAddress
protected  InetAddress SocketImpl.address
          The IP address of the remote end of this socket.
 

Methods in java.net that return InetAddress
protected  InetAddress Authenticator.getRequestingSite()
           
 InetAddress DatagramSocket.getInetAddress()
          Returns the address to which this socket is connected.
 InetAddress DatagramSocket.getLocalAddress()
          Gets the local address to which the socket is bound.
 InetAddress MulticastSocket.getInterface()
          Retrieve the address of the network interface used for multicast packets.
 InetAddress DatagramPacket.getAddress()
          Returns the IP address of the machine to which this datagram is being sent or from which the datagram was received.
 InetAddress Socket.getInetAddress()
          Returns the address to which the socket is connected.
 InetAddress Socket.getLocalAddress()
          Gets the local address to which the socket is bound.
static InetAddress InetAddress.getByName(String host)
          Determines the IP address of a host, given the host's name.
static InetAddress[] InetAddress.getAllByName(String host)
          Determines all the IP addresses of a host, given the host's name.
static InetAddress InetAddress.getLocalHost()
          Returns the local host.
 InetAddress ServerSocket.getInetAddress()
          Returns the local address of this server socket.
protected  InetAddress SocketImpl.getInetAddress()
          Returns the value of this socket's address field.
 

Methods in java.net with parameters of type InetAddress
static PasswordAuthentication Authenticator.requestPasswordAuthentication(InetAddress addr, int port, String protocol, String prompt, String scheme)
          Ask the authenticator that has been registered with the system for a password.
 void DatagramSocket.connect(InetAddress address, int port)
          Connects the socket to a remote address for this socket.
 void MulticastSocket.joinGroup(InetAddress mcastaddr)
          Joins a multicast group.
 void MulticastSocket.leaveGroup(InetAddress mcastaddr)
          Leave a multicast group.
 void MulticastSocket.setInterface(InetAddress inf)
          Set the outgoing network interface for multicast packets on this socket, to other than the system default.
 void DatagramPacket.setAddress(InetAddress iaddr)
           
protected abstract  void DatagramSocketImpl.bind(int lport, InetAddress laddr)
          Binds a datagram socket to a local port and address.
protected abstract  int DatagramSocketImpl.peek(InetAddress i)
          Peek at the packet to see who it is from.
protected abstract  void DatagramSocketImpl.join(InetAddress inetaddr)
          Join the multicast group.
protected abstract  void DatagramSocketImpl.leave(InetAddress inetaddr)
          Leave the multicast group.
protected abstract  void SocketImpl.connect(InetAddress address, int port)
          Connects this socket to the specified port number on the specified host.
protected abstract  void SocketImpl.bind(InetAddress host, int port)
          Binds this socket to the specified port number on the specified host.
 

Constructors in java.net with parameters of type InetAddress
DatagramSocket.DatagramSocket(int port, InetAddress laddr)
          Creates a datagram socket, bound to the specified local address.
DatagramPacket.DatagramPacket(byte[] buf, int offset, int length, InetAddress address, int port)
          Constructs a datagram packet for sending packets of length length with offset ioffsetto the specified port number on the specified host.
DatagramPacket.DatagramPacket(byte[] buf, int length, InetAddress address, int port)
          Constructs a datagram packet for sending packets of length length to the specified port number on the specified host.
Socket.Socket(InetAddress address, int port)
          Creates a stream socket and connects it to the specified port number at the specified IP address.
Socket.Socket(String host, int port, InetAddress localAddr, int localPort)
          Creates a socket and connects it to the specified remote host on the specified remote port.
Socket.Socket(InetAddress address, int port, InetAddress localAddr, int localPort)
          Creates a socket and connects it to the specified remote address on the specified remote port.
Socket.Socket(InetAddress host, int port, boolean stream)
          Deprecated. Use DatagramSocket instead for UDP transport.
ServerSocket.ServerSocket(int port, int backlog, InetAddress bindAddr)
          Create a server with the specified port, listen backlog, and local IP address to bind to.
 


Java Platform 1.2

Submit a bug or feature Version 1.2 of Java Platform API Specification
Java is a trademark or registered trademark of Sun Microsystems, Inc. in the US and other countries.
Copyright 1993-1998 Sun Microsystems, Inc. 901 San Antonio Road,
Palo Alto, California, 94303, U.S.A. All Rights Reserved.