Package com.klaytn.caver.account
Class AccountKeyLegacy
- java.lang.Object
-
- com.klaytn.caver.account.AccountKeyLegacy
-
- All Implemented Interfaces:
IAccountKey
public class AccountKeyLegacy extends java.lang.Object implements IAccountKey
AccountKeyLegacy represents a key of legacy account types. If an account has AccountKeyLegacy, the tx validation process is done like below (as Ethereum did): Get the public key from ecrecover(txhash, txsig) Get the address of the public key The address is the sender
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
AccountKeyLegacy.AccountKeyLegacySerializer
Serialize class to AccountKeyLegacy object into JSON.
-
Constructor Summary
Constructors Constructor Description AccountKeyLegacy()
Creates an AccountKeyLegacy instance
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static AccountKeyLegacy
decode(byte[] rlpEncodedKey)
Decodes a RLP-encoded AccountKeyLegacy byte arraystatic AccountKeyLegacy
decode(java.lang.String rlpEncodedKey)
Decodes a RLP-encoded AccountKeyLegacy stringjava.lang.String
getRLPEncoding()
Encodes a AccountKeyLegacy Object by RLP-encoding method.static java.lang.String
getType()
Returns an AccountKeyLegacy's type attribute
-
-
-
Method Detail
-
decode
public static AccountKeyLegacy decode(java.lang.String rlpEncodedKey)
Decodes a RLP-encoded AccountKeyLegacy string- Parameters:
rlpEncodedKey
- A RLP-encoded AccountKeyLegacy string- Returns:
- AccountKeyLegacy
-
decode
public static AccountKeyLegacy decode(byte[] rlpEncodedKey)
Decodes a RLP-encoded AccountKeyLegacy byte array- Parameters:
rlpEncodedKey
- RLP-encoded AccountKeyLegacy byte array- Returns:
- AccountKeyLegacy
-
getRLPEncoding
public java.lang.String getRLPEncoding()
Encodes a AccountKeyLegacy Object by RLP-encoding method.- Specified by:
getRLPEncoding
in interfaceIAccountKey
- Returns:
- RLP-encoded AccountKeyLegacy string
-
getType
public static java.lang.String getType()
Returns an AccountKeyLegacy's type attribute- Returns:
- AccountKeyLegacy's type attribute
-
-