public enum Transport extends Enum<Transport>
Enum Constant and Description |
---|
DTLS
Represents a datagram TLS (DTLS) transport.
|
SCTP
Represents an SCTP transport.
|
SSLTCP
Represents an Google's SSL TCP transport.
|
TCP
Represents a TCP transport.
|
TLS
Represents a TLS transport.
|
UDP
Represents a UDP transport.
|
Modifier and Type | Field and Description |
---|---|
private String |
transportName
The name of this Transport.
|
Modifier and Type | Method and Description |
---|---|
static Transport |
parse(String transportName)
Returns a Transport instance corresponding to the specified
transportName.
|
String |
toString()
Returns the name of this Transport (e.g.
|
static Transport |
valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static Transport[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final Transport TCP
public static final Transport UDP
public static final Transport TLS
public static final Transport DTLS
public static final Transport SCTP
public static final Transport SSLTCP
private final String transportName
public static Transport[] values()
for (Transport c : Transport.values()) System.out.println(c);
public static Transport valueOf(String name)
name
- the name of the enum constant to be returned.IllegalArgumentException
- if this enum type has no constant with the specified nameNullPointerException
- if the argument is nullpublic String toString()
public static Transport parse(String transportName) throws IllegalArgumentException
UDP
.transportName
- the name that we'd like to parse.IllegalArgumentException
- in case transportName is
not a valid or currently supported transport.Copyright © 2018. All rights reserved.