Enum Class Schema
- All Implemented Interfaces:
Serializable,Comparable<Schema>,Constable
Lists common relevant protocol schemas.
- Author:
- Holger Eichelberger, SSE
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>> -
Enum Constant Summary
Enum Constants -
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleanReturns whether this schema is supposed to be encrypted.toUri()Returns the URI schema prefix.static SchemaReturns the enum constant of this class with the specified name.static Schema[]values()Returns an array containing the constants of this enum class, in the order they are declared.
-
Enum Constant Details
-
HTTP
HTTP unencrypted. -
HTTPS
HTTP encrypted. -
TCP
TCP unencrypted. -
SSL
TCP TLS-encrypted. -
WS
Not-encrypted websockets. -
SSH
SSH. -
IGNORE
Use whatever you like.
-
-
Field Details
-
uriSchema
-
isEncrypted
private boolean isEncrypted
-
-
Constructor Details
-
Schema
Creates a constant.- Parameters:
uriSchema- the URL schema prefix, may be empty for noneisEncryted-truefor encrypted,falsefor plaintext
-
-
Method Details
-
values
Returns an array containing the constants of this enum class, in the order they are declared.- Returns:
- an array containing the constants of this enum class, in the order they are declared
-
valueOf
Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)- Parameters:
name- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException- if this enum class has no constant with the specified nameNullPointerException- if the argument is null
-
isEncrypted
public boolean isEncrypted()Returns whether this schema is supposed to be encrypted.- Returns:
truefor encrypted,falsefor plaintext
-
toUri
Returns the URI schema prefix.- Returns:
- the URI schema prefix, may be empty for none
-