Package org.apache.sshd.common.kex
Enum KexProposalOption
- java.lang.Object
-
- java.lang.Enum<KexProposalOption>
-
- org.apache.sshd.common.kex.KexProposalOption
-
- All Implemented Interfaces:
Serializable,Comparable<KexProposalOption>
public enum KexProposalOption extends Enum<KexProposalOption>
- Author:
- Apache MINA SSHD Project
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classKexProposalOption.Constants
-
Enum Constant Summary
Enum Constants Enum Constant Description ALGORITHMSC2SCOMPC2SENCC2SLANGC2SMACS2CCOMPS2CENCS2CLANGS2CMACSERVERKEYS
-
Field Summary
Fields Modifier and Type Field Description static Comparator<KexProposalOption>BY_PROPOSAL_INDEXCompares values according togetProposalIndex()static Set<KexProposalOption>CIPHER_PROPOSALSstatic Set<KexProposalOption>COMPRESSION_PROPOSALSstatic Set<KexProposalOption>FIRST_KEX_PACKET_GUESS_MATCHESstatic Set<KexProposalOption>LANGUAGE_PROPOSALSstatic Set<KexProposalOption>MAC_PROPOSALSstatic intPROPOSAL_MAXstatic List<KexProposalOption>VALUESAListof all the options sorted according togetProposalIndex()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static KexProposalOptionfromName(String n)static KexProposalOptionfromProposalIndex(int index)StringgetDescription()intgetProposalIndex()static KexProposalOptionvalueOf(String name)Returns the enum constant of this type with the specified name.static KexProposalOption[]values()Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Enum Constant Detail
-
ALGORITHMS
public static final KexProposalOption ALGORITHMS
-
SERVERKEYS
public static final KexProposalOption SERVERKEYS
-
C2SENC
public static final KexProposalOption C2SENC
-
S2CENC
public static final KexProposalOption S2CENC
-
C2SMAC
public static final KexProposalOption C2SMAC
-
S2CMAC
public static final KexProposalOption S2CMAC
-
C2SCOMP
public static final KexProposalOption C2SCOMP
-
S2CCOMP
public static final KexProposalOption S2CCOMP
-
C2SLANG
public static final KexProposalOption C2SLANG
-
S2CLANG
public static final KexProposalOption S2CLANG
-
-
Field Detail
-
CIPHER_PROPOSALS
public static final Set<KexProposalOption> CIPHER_PROPOSALS
-
MAC_PROPOSALS
public static final Set<KexProposalOption> MAC_PROPOSALS
-
COMPRESSION_PROPOSALS
public static final Set<KexProposalOption> COMPRESSION_PROPOSALS
-
LANGUAGE_PROPOSALS
public static final Set<KexProposalOption> LANGUAGE_PROPOSALS
-
FIRST_KEX_PACKET_GUESS_MATCHES
public static final Set<KexProposalOption> FIRST_KEX_PACKET_GUESS_MATCHES
-
BY_PROPOSAL_INDEX
public static final Comparator<KexProposalOption> BY_PROPOSAL_INDEX
Compares values according togetProposalIndex()
-
VALUES
public static final List<KexProposalOption> VALUES
AListof all the options sorted according togetProposalIndex()- See Also:
BY_PROPOSAL_INDEX
-
PROPOSAL_MAX
public static final int PROPOSAL_MAX
-
-
Method Detail
-
values
public static KexProposalOption[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:for (KexProposalOption c : KexProposalOption.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static KexProposalOption valueOf(String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (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 type has no constant with the specified nameNullPointerException- if the argument is null
-
getProposalIndex
public final int getProposalIndex()
- Returns:
- The proposal option location in the KEX array
-
getDescription
public final String getDescription()
- Returns:
- User-friendly name for the KEX negotiation item
- See Also:
- RFC-4253 - section 7.1
-
fromName
public static KexProposalOption fromName(String n)
- Parameters:
n- The option name - ignored ifnull/empty- Returns:
- The matching
Enum.name()- case insensitive ornullif no match found
-
fromProposalIndex
public static KexProposalOption fromProposalIndex(int index)
-
-