AllowTrustOperationBuilder
in package
Builder for creating AllowTrust operations.
This builder implements the builder pattern to construct AllowTrustOperation instances with a fluent interface. AllowTrust operations allow an issuing account to authorize or revoke authorization for another account to hold its assets.
Tags
Table of Contents
Methods
- __construct() : mixed
- Creates a new AllowTrust operation builder.
- build() : AllowTrustOperation
- Builds the AllowTrust operation.
- setMuxedSourceAccount() : $this
- Sets the muxed source account for this operation.
- setSourceAccount() : $this
- Sets the source account for this operation.
Methods
__construct()
Creates a new AllowTrust operation builder.
public
__construct(string $trustor, string $assetCode, bool $authorized, bool $authorizedToMaintainLiabilities) : mixed
Parameters
- $trustor : string
-
The account ID of the trustor being authorized or deauthorized
- $assetCode : string
-
The asset code (1-12 characters)
- $authorized : bool
-
Whether to authorize the trustline
- $authorizedToMaintainLiabilities : bool
-
Whether to authorize only maintaining liabilities
Tags
build()
Builds the AllowTrust operation.
public
build() : AllowTrustOperation
Return values
AllowTrustOperation —The constructed operation
setMuxedSourceAccount()
Sets the muxed source account for this operation.
public
setMuxedSourceAccount(MuxedAccount $sourceAccount) : $this
Parameters
- $sourceAccount : MuxedAccount
-
The muxed account to use as source
Return values
$this —Returns the builder instance for method chaining
setSourceAccount()
Sets the source account for this operation.
public
setSourceAccount(string $accountId) : $this
Parameters
- $accountId : string
-
The Stellar account ID (G...)
Return values
$this —Returns the builder instance for method chaining