Package org.jcsp.net2.tcpip
Class TCPIPProtocolID
java.lang.Object
org.jcsp.net2.ProtocolID
org.jcsp.net2.tcpip.TCPIPProtocolID
Concrete implementation of a ProtocolID used to parse a string representation of a TCPIPNodeAddress into a
TCPIPNodeAddress object.
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic TCPIPProtocolID
Gets the singleton instance of this classprotected NodeAddress
Parses a string to recreate a TCPIPNodeAddress object
-
Field Details
-
instance
Singleton instance of this class
-
-
Constructor Details
-
TCPIPProtocolID
private TCPIPProtocolID()Default private constructor
-
-
Method Details
-
getInstance
Gets the singleton instance of this class- Returns:
- A new singleton instance of this class
-
parse
Parses a string to recreate a TCPIPNodeAddress object- Specified by:
parse
in classProtocolID
- Parameters:
addressString
- String representing the address- Returns:
- A new TCPIPNodeAddress object
- Throws:
IllegalArgumentException
- Thrown if the address is not in a correct form
-