public static enum Port.Protocol extends java.lang.Enum<Port.Protocol>
| Modifier and Type | Method and Description |
|---|---|
static Port.Protocol |
getFromString(java.lang.String protocolString)
Returns the
Port.Protocol given its string representation. |
java.lang.String |
toString() |
static Port.Protocol |
valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name.
|
static Port.Protocol[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final Port.Protocol TCP
public static final Port.Protocol UDP
public static Port.Protocol[] values()
for (Port.Protocol c : Port.Protocol.values()) System.out.println(c);
public static Port.Protocol valueOf(java.lang.String name)
name - the name of the enum constant to be returned.java.lang.IllegalArgumentException - if this enum type has no constant with the specified namejava.lang.NullPointerException - if the argument is nullpublic java.lang.String toString()
toString in class java.lang.Enum<Port.Protocol>public static Port.Protocol getFromString(@Nullable java.lang.String protocolString)
Port.Protocol given its string representation.protocolString - the case insensitive string (e.g. "tcp", "udp")Port.Protocol with the corresponding name, or Protocol#TCP by default
if invalid