public enum SocksVersion extends Enum<SocksVersion>
Enum Constant and Description |
---|
SOCKS4a
SOCKS protocol version 4a (or 4)
|
SOCKS5
SOCKS protocol version 5
|
UNKNOWN
Unknown protocol version
|
Modifier and Type | Method and Description |
---|---|
byte |
byteValue()
Returns the value of the version field, as defined in the protocol specification.
|
static SocksVersion |
valueOf(byte b)
Returns the
SocksVersion that corresponds to the specified version field value,
as defined in the protocol specification. |
static SocksVersion |
valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static SocksVersion[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final SocksVersion SOCKS4a
public static final SocksVersion SOCKS5
public static final SocksVersion UNKNOWN
public static SocksVersion[] values()
for (SocksVersion c : SocksVersion.values()) System.out.println(c);
public static SocksVersion 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 static SocksVersion valueOf(byte b)
SocksVersion
that corresponds to the specified version field value,
as defined in the protocol specification.UNKNOWN
if the specified value does not represent a known SOCKS protocol versionpublic byte byteValue()
Copyright © 2008–2017 The Netty Project. All rights reserved.