// Path: src/nb/barmie/exceptions/BaRMIeInvalidPortException.java
// public class BaRMIeInvalidPortException extends BaRMIeException {
// 	public BaRMIeInvalidPortException(int portNumber) {
// 		super("The given port number (" + portNumber + ") is not a valid TCP port number.");
// 	}
// }


import nb.barmie.exceptions.BaRMIeInvalidPortException;
package nb.barmie.net;


/***********************************************************
 * Holder for host and port properties of a TCP endpoint.
 * 
 * Written by Nicky Bloor (@NickstaDB).
 **********************************************************/
public class TCPEndpoint {
	/*******************
	 * Properties
	 ******************/
	private final String _host;
	private final int _port;
	
	/*******************
	 * Construct the TCP endpoint object with a given host and port.
	 * 
	 * @param host The host/IP to use.
	 * @param port The port to use.
	 * @throws nb.barmie.exceptions.BaRMIeInvalidPortException If the given port number is not a valid TCP port number.
	 ******************/
// Path: src/nb/barmie/exceptions/BaRMIeInvalidPortException.java
// public class BaRMIeInvalidPortException extends BaRMIeException {
// 	public BaRMIeInvalidPortException(int portNumber) {
// 		super("The given port number (" + portNumber + ") is not a valid TCP port number.");
// 	}
// }


// Path: src/nb/barmie/net/TCPEndpoint.java
import nb.barmie.exceptions.BaRMIeInvalidPortException;

package nb.barmie.net;


/***********************************************************
 * Holder for host and port properties of a TCP endpoint.
 * 
 * Written by Nicky Bloor (@NickstaDB).
 **********************************************************/
public class TCPEndpoint {
	/*******************
	 * Properties
	 ******************/
	private final String _host;
	private final int _port;
	
	/*******************
	 * Construct the TCP endpoint object with a given host and port.
	 * 
	 * @param host The host/IP to use.
	 * @param port The port to use.
	 * @throws nb.barmie.exceptions.BaRMIeInvalidPortException If the given port number is not a valid TCP port number.
	 ******************/
	public TCPEndpoint(String host, int port) throws BaRMIeInvalidPortException {