@Retention(RUNTIME) @Target(FIELD) public @interface Port
Annotation that indicates that an option/argument denotes a port number and its value should be restricted as such to a specific set of port classes as defined by PortType. If you want to restrict to more specific ranges use the PortRange or PortRanges annotations instead.
  • Optional Element Summary

    Optional Elements
    Modifier and Type
    Optional Element
    Description
    The acceptable port types, defaults to PortType#OS_ALLOCATED, PortType#USER and PortType#DYNAMIC
  • Element Details

    • acceptablePorts

      PortType[] acceptablePorts
      The acceptable port types, defaults to PortType#OS_ALLOCATED, PortType#USER and PortType#DYNAMIC
      Returns:
      Acceptable port types
      Default:
      {OS_ALLOCATED, USER, DYNAMIC}