|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | ENUM CONSTANTS | FIELD | METHOD | DETAIL: ENUM CONSTANTS | FIELD | METHOD |
java.lang.Objectjava.lang.Enum<KeyType>
org.keyczar.enums.KeyType
public enum KeyType
Encodes different types of keys each with (default size, output size). Some have multiple acceptable sizes given in a list with the first as default.
JSON Representation currently supports these strings:
Enum Constant Summary | |
---|---|
AES
|
|
DSA_PRIV
|
|
DSA_PUB
|
|
HMAC_SHA1
|
|
RSA_PRIV
|
|
RSA_PUB
|
|
TEST
|
Method Summary | |
---|---|
int |
defaultSize()
Returns the default (recommended) key size. |
java.util.List<java.lang.Integer> |
getAcceptableSizes()
|
int |
getOutputSize()
|
boolean |
isAcceptableSize(int size)
Checks whether a given key size is acceptable. |
java.lang.String |
toString()
|
static KeyType |
valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name. |
static KeyType[] |
values()
Returns an array containing the constants of this enum type, in the order they are declared. |
Methods inherited from class java.lang.Enum |
---|
compareTo, equals, getDeclaringClass, hashCode, name, ordinal, valueOf |
Methods inherited from class java.lang.Object |
---|
getClass, notify, notifyAll, wait, wait, wait |
Enum Constant Detail |
---|
public static final KeyType AES
public static final KeyType HMAC_SHA1
public static final KeyType DSA_PRIV
public static final KeyType DSA_PUB
public static final KeyType RSA_PRIV
public static final KeyType RSA_PUB
public static final KeyType TEST
Method Detail |
---|
public static KeyType[] values()
for (KeyType c : KeyType.values()) System.out.println(c);
public static KeyType 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 name
java.lang.NullPointerException
- if the argument is nullpublic int defaultSize()
public int getOutputSize()
public boolean isAcceptableSize(int size)
size
- integer key size
public java.util.List<java.lang.Integer> getAcceptableSizes()
public java.lang.String toString()
toString
in class java.lang.Enum<KeyType>
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | ENUM CONSTANTS | FIELD | METHOD | DETAIL: ENUM CONSTANTS | FIELD | METHOD |