Code example for DatagramSocket

Methods: getLocalAddress

0
	 * @return Address 
	 * @throws IOException 
	 */ 
	public String getLocalAddress() throws IOException {
		if (connection != null) {
			return connection.getLocalAddress().getHostAddress();
		} else { 
			throw new IOException("Connection not openned");
		} 
	} 
 
	/** 
	 * Returns the local port 
	 *  
	 * @return Port 
	 * @throws IOException 
	 */ 
	public int getLocalPort() throws IOException { 
		if (connection != null) {
			return connection.getLocalPort();
		} else {