Package org.xrpl.xrpl4j.crypto
Class PrivateKey.DefaultPrivateKey
java.lang.Object
org.xrpl.xrpl4j.crypto.PrivateKey.DefaultPrivateKey
- All Implemented Interfaces:
PrivateKey
- Direct Known Subclasses:
ImmutableDefaultPrivateKey
- Enclosing interface:
- PrivateKey
@Immutable
public abstract static class PrivateKey.DefaultPrivateKey
extends Object
implements PrivateKey
Abstract implementation for immutables.
-
Nested Class Summary
Nested classes/interfaces inherited from interface org.xrpl.xrpl4j.crypto.PrivateKey
PrivateKey.DefaultPrivateKey
-
Field Summary
Fields inherited from interface org.xrpl.xrpl4j.crypto.PrivateKey
PREFIX
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionThe key, as a Base16-encoded (i.e., HEX) string.The key, as a Base58-encoded string.toString()
The type of this key (eitherVersionType.ED25519
orVersionType.SECP256K1
).Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Methods inherited from interface org.xrpl.xrpl4j.crypto.PrivateKey
value
-
Constructor Details
-
DefaultPrivateKey
public DefaultPrivateKey()
-
-
Method Details
-
base58Encoded
Description copied from interface:PrivateKey
The key, as a Base58-encoded string.- Specified by:
base58Encoded
in interfacePrivateKey
- Returns:
- A
String
.
-
base16Encoded
Description copied from interface:PrivateKey
The key, as a Base16-encoded (i.e., HEX) string. Note that if this is an Ed25519 private-key, then this value contains a leading prefix of `ED`, in hex.- Specified by:
base16Encoded
in interfacePrivateKey
- Returns:
- A
String
.
-
versionType
Description copied from interface:PrivateKey
The type of this key (eitherVersionType.ED25519
orVersionType.SECP256K1
).- Specified by:
versionType
in interfacePrivateKey
- Returns:
- A
VersionType
.
-
toString
-