Class LegacyTransactionWrapper
- java.lang.Object
-
- com.klaytn.caver.transaction.type.wrapper.LegacyTransactionWrapper
-
public class LegacyTransactionWrapper extends java.lang.Object
Represents a LegacyTransactionWrapper 1. This class wraps all of static methods of LegacyTransaction 2. This class should be accessed via `caver.transaction.legacyTransaction`
-
-
Constructor Summary
Constructors Constructor Description LegacyTransactionWrapper(Klay klaytnCall)
Creates a LegacyTransactionWrapper instance.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description LegacyTransaction
create(byte[] rlpEncoded)
Creates a LegacyTransaction instance derived from a RLP-encoded LegacyTransaction byte array.LegacyTransaction
create(LegacyTransaction.Builder builder)
Creates a LegacyTransaction instance using LegacyTransaction.BuilderLegacyTransaction
create(java.lang.String rlpEncoded)
Creates a LegacyTransaction instance derived from a RLP-encoded LegacyTransaction string.LegacyTransaction
create(java.lang.String from, java.lang.String nonce, java.lang.String gas, java.lang.String gasPrice, java.lang.String chainId, java.util.List<SignatureData> signatures, java.lang.String to, java.lang.String input, java.lang.String value)
Create a LegacyTransaction instance.LegacyTransaction
decode(byte[] rlpEncoded)
Decodes a RLP-encoded LegacyTransaction byte array.LegacyTransaction
decode(java.lang.String rlpEncoded)
Decodes a RLP-encoded LegacyTransaction string.
-
-
-
Constructor Detail
-
LegacyTransactionWrapper
public LegacyTransactionWrapper(Klay klaytnCall)
Creates a LegacyTransactionWrapper instance.- Parameters:
klaytnCall
- Klay RPC instance
-
-
Method Detail
-
create
public LegacyTransaction create(java.lang.String rlpEncoded)
Creates a LegacyTransaction instance derived from a RLP-encoded LegacyTransaction string.- Parameters:
rlpEncoded
- RLP-encoded LegacyTransaction string- Returns:
- LegacyTransaction
-
create
public LegacyTransaction create(byte[] rlpEncoded)
Creates a LegacyTransaction instance derived from a RLP-encoded LegacyTransaction byte array.- Parameters:
rlpEncoded
- RLP-encoded LegacyTransaction byte array.- Returns:
- LegacyTransaction
-
create
public LegacyTransaction create(LegacyTransaction.Builder builder)
Creates a LegacyTransaction instance using LegacyTransaction.Builder- Parameters:
builder
- LegacyTransaction.Builder- Returns:
- LegacyTransaction
-
create
public LegacyTransaction create(java.lang.String from, java.lang.String nonce, java.lang.String gas, java.lang.String gasPrice, java.lang.String chainId, java.util.List<SignatureData> signatures, java.lang.String to, java.lang.String input, java.lang.String value)
Create a LegacyTransaction instance.- Parameters:
from
- The address of the sender.nonce
- A value used to uniquely identify a sender’s transaction.gas
- The maximum amount of gas the transaction is allowed to use.gasPrice
- A unit price of gas in peb the sender will pay for a transaction fee.chainId
- Network IDsignatures
- A Signature listto
- The account address that will receive the transferred value.input
- Data attached to the transaction, used for transaction execution.value
- The amount of KLAY in peb to be transferred.- Returns:
- LegacyTransaction
-
decode
public LegacyTransaction decode(java.lang.String rlpEncoded)
Decodes a RLP-encoded LegacyTransaction string.- Parameters:
rlpEncoded
- RLP-encoded LegacyTransaction string- Returns:
- LegacyTransaction
-
decode
public LegacyTransaction decode(byte[] rlpEncoded)
Decodes a RLP-encoded LegacyTransaction byte array.- Parameters:
rlpEncoded
- RLP-encoded LegacyTransaction byte array.- Returns:
- LegacyTransaction
-
-