Skip to content

Most visited

Recently visited

navigation
Added in API level 1

Key

public interface Key
implements Serializable

java.security.Key
Known Indirect Subclasses


Key is the common interface for all keys.

See also:

Summary

Constants

long serialVersionUID

The serialVersionUID to be compatible with JDK1.1.

Public methods

abstract String getAlgorithm()

Returns the name of the algorithm of this key.

abstract byte[] getEncoded()

Returns the encoded form of this key, or null if encoding is not supported by this key.

abstract String getFormat()

Returns the name of the format used to encode this key, or null if it can not be encoded.

Constants

serialVersionUID

Added in API level 1
long serialVersionUID

The serialVersionUID to be compatible with JDK1.1.

Constant Value: 6603384152749567654 (0x5ba3eee69414eea6)

Public methods

getAlgorithm

Added in API level 1
String getAlgorithm ()

Returns the name of the algorithm of this key. If the algorithm is unknown, null is returned.

Returns
String the name of the algorithm of this key or null if the algorithm is unknown.

getEncoded

Added in API level 1
byte[] getEncoded ()

Returns the encoded form of this key, or null if encoding is not supported by this key.

Returns
byte[] the encoded form of this key, or null if encoding is not supported by this key.

getFormat

Added in API level 1
String getFormat ()

Returns the name of the format used to encode this key, or null if it can not be encoded.

Returns
String the name of the format used to encode this key, or null if it can not be encoded.
This site uses cookies to store your preferences for site-specific language and display options.

Hooray!

This class requires API level or higher

This doc is hidden because your selected API level for the documentation is . You can change the documentation API level with the selector above the left navigation.

For more information about specifying the API level your app requires, read Supporting Different Platform Versions.