Class Port

  • All Implemented Interfaces:
    DataType

    @Service
    public final class Port
    extends Object
    implements DataType
    Represents a network port on a machine. It's modelled as a functional class.
    Author:
    केदार ([email protected])
    • Constructor Detail

      • Port

        public Port()
    • Method Detail

      • validate

        public void validate​(String value)
                      throws ValidationException
        Checks if given string represents a port. Does not allow any value other than those between 0 and 65535 (both inclusive).
        Specified by:
        validate in interface DataType
        Parameters:
        value - represents the value of the port.
        Throws:
        ValidationException - if the value does not represent integer value.