Package org.xrpl.xrpl4j.crypto.signing
Class ImmutableSingleSignedTransaction.Builder<T extends Transaction>
java.lang.Object
org.xrpl.xrpl4j.crypto.signing.ImmutableSingleSignedTransaction.Builder<T>
- Enclosing class:
ImmutableSingleSignedTransaction<T extends Transaction>
@NotThreadSafe
public static final class ImmutableSingleSignedTransaction.Builder<T extends Transaction>
extends Object
Builds instances of type
ImmutableSingleSignedTransaction.
Initialize attributes and then invoke the build() method to create an
immutable instance.
Builder is not thread-safe and generally should not be stored in a field or collection,
but instead used immediately to create instances.
-
Method Summary
Modifier and TypeMethodDescriptionbuild()Builds a newImmutableSingleSignedTransaction.from(SignedTransaction<T> instance) Fill a builder with attribute values from the providedorg.xrpl.xrpl4j.crypto.signing.SignedTransactioninstance.from(SingleSignedTransaction<T> instance) Fill a builder with attribute values from the providedorg.xrpl.xrpl4j.crypto.signing.SingleSignedTransactioninstance.Initializes the value for thesignatureattribute.signedTransaction(T signedTransaction) Initializes the value for thesignedTransactionattribute.unsignedTransaction(T unsignedTransaction) Initializes the value for theunsignedTransactionattribute.
-
Method Details
-
from
@CanIgnoreReturnValue public final ImmutableSingleSignedTransaction.Builder<T> from(SingleSignedTransaction<T> instance) Fill a builder with attribute values from the providedorg.xrpl.xrpl4j.crypto.signing.SingleSignedTransactioninstance.- Parameters:
instance- The instance from which to copy values- Returns:
thisbuilder for use in a chained invocation
-
from
@CanIgnoreReturnValue public final ImmutableSingleSignedTransaction.Builder<T> from(SignedTransaction<T> instance) Fill a builder with attribute values from the providedorg.xrpl.xrpl4j.crypto.signing.SignedTransactioninstance.- Parameters:
instance- The instance from which to copy values- Returns:
thisbuilder for use in a chained invocation
-
unsignedTransaction
@CanIgnoreReturnValue public final ImmutableSingleSignedTransaction.Builder<T> unsignedTransaction(T unsignedTransaction) Initializes the value for theunsignedTransactionattribute.- Parameters:
unsignedTransaction- The value for unsignedTransaction- Returns:
thisbuilder for use in a chained invocation
-
signedTransaction
@CanIgnoreReturnValue public final ImmutableSingleSignedTransaction.Builder<T> signedTransaction(T signedTransaction) Initializes the value for thesignedTransactionattribute.- Parameters:
signedTransaction- The value for signedTransaction- Returns:
thisbuilder for use in a chained invocation
-
signature
@CanIgnoreReturnValue public final ImmutableSingleSignedTransaction.Builder<T> signature(Signature signature) Initializes the value for thesignatureattribute.- Parameters:
signature- The value for signature- Returns:
thisbuilder for use in a chained invocation
-
build
Builds a newImmutableSingleSignedTransaction.- Returns:
- An immutable instance of SingleSignedTransaction
- Throws:
IllegalStateException- if any required attributes are missing
-