XdrSorobanCredentials
extends XdrSorobanCredentialsBase
in package
Hand-written factory wrapper for XdrSorobanCredentialsBase.
Provides named constructors for all four credential arms. The generated base class (XdrSorobanCredentialsBase) handles encode/decode/JSON/TxRep; this subclass only adds the factory methods.
Table of Contents
Properties
- $address : XdrSorobanAddressCredentials|null
- $addressV2 : XdrSorobanAddressCredentials|null
- $addressWithDelegates : XdrSorobanAddressCredentialsWithDelegates|null
- $type : XdrSorobanCredentialsType
Methods
- __construct() : mixed
- decode() : static
- encode() : string
- forAddressCredentials() : XdrSorobanCredentials
- Creates legacy ADDRESS credentials.
- forAddressCredentialsV2() : XdrSorobanCredentials
- Creates ADDRESS_V2 credentials (Protocol 27, CAP-71).
- forAddressWithDelegates() : XdrSorobanCredentials
- Creates ADDRESS_WITH_DELEGATES credentials (Protocol 27, CAP-71).
- forSourceAccount() : XdrSorobanCredentials
- Creates source-account credentials.
- fromBase64Xdr() : static
- fromJson() : static
- fromJsonValue() : static
- fromTxRep() : static
- getAddress() : XdrSorobanAddressCredentials|null
- getAddressV2() : XdrSorobanAddressCredentials|null
- getAddressWithDelegates() : XdrSorobanAddressCredentialsWithDelegates|null
- getType() : XdrSorobanCredentialsType
- setAddress() : void
- setAddressV2() : void
- setAddressWithDelegates() : void
- setType() : void
- toBase64Xdr() : string
- toJson() : string
- toJsonValue() : mixed
- toTxRep() : void
Properties
$address
public
XdrSorobanAddressCredentials|null
$address
= null
$addressV2
public
XdrSorobanAddressCredentials|null
$addressV2
= null
$addressWithDelegates
public
XdrSorobanAddressCredentialsWithDelegates|null
$addressWithDelegates
= null
$type
public
XdrSorobanCredentialsType
$type
Methods
__construct()
public
__construct([XdrSorobanCredentialsType|null $type = null ]) : mixed
Parameters
- $type : XdrSorobanCredentialsType|null = null
decode()
public
static decode(XdrBuffer $xdr) : static
Parameters
- $xdr : XdrBuffer
Return values
staticencode()
public
encode() : string
Return values
stringforAddressCredentials()
Creates legacy ADDRESS credentials.
public
static forAddressCredentials(XdrSorobanAddressCredentials $addressCredentials) : XdrSorobanCredentials
Parameters
- $addressCredentials : XdrSorobanAddressCredentials
Return values
XdrSorobanCredentialsforAddressCredentialsV2()
Creates ADDRESS_V2 credentials (Protocol 27, CAP-71).
public
static forAddressCredentialsV2(XdrSorobanAddressCredentials $addressCredentials) : XdrSorobanCredentials
Uses ENVELOPE_TYPE_SOROBAN_AUTHORIZATION_WITH_ADDRESS (address-bound preimage). Invalid on networks below Protocol 27.
Parameters
- $addressCredentials : XdrSorobanAddressCredentials
Return values
XdrSorobanCredentialsforAddressWithDelegates()
Creates ADDRESS_WITH_DELEGATES credentials (Protocol 27, CAP-71).
public
static forAddressWithDelegates(XdrSorobanAddressCredentialsWithDelegates $addressWithDelegates) : XdrSorobanCredentials
Uses ENVELOPE_TYPE_SOROBAN_AUTHORIZATION_WITH_ADDRESS with a recursive delegate tree. Invalid on networks below Protocol 27.
Parameters
- $addressWithDelegates : XdrSorobanAddressCredentialsWithDelegates
Return values
XdrSorobanCredentialsforSourceAccount()
Creates source-account credentials.
public
static forSourceAccount() : XdrSorobanCredentials
Return values
XdrSorobanCredentialsfromBase64Xdr()
public
static fromBase64Xdr(string $xdr) : static
Parameters
- $xdr : string
Return values
staticfromJson()
public
static fromJson(string $json) : static
Parameters
- $json : string
Tags
Return values
staticfromJsonValue()
public
static fromJsonValue(mixed $value) : static
Parameters
- $value : mixed
Return values
staticfromTxRep()
public
static fromTxRep(array<string|int, mixed> $map, string $prefix) : static
Parameters
- $map : array<string|int, mixed>
- $prefix : string
Return values
staticgetAddress()
public
getAddress() : XdrSorobanAddressCredentials|null
Return values
XdrSorobanAddressCredentials|nullgetAddressV2()
public
getAddressV2() : XdrSorobanAddressCredentials|null
Return values
XdrSorobanAddressCredentials|nullgetAddressWithDelegates()
public
getAddressWithDelegates() : XdrSorobanAddressCredentialsWithDelegates|null
Return values
XdrSorobanAddressCredentialsWithDelegates|nullgetType()
public
getType() : XdrSorobanCredentialsType
Return values
XdrSorobanCredentialsTypesetAddress()
public
setAddress(XdrSorobanAddressCredentials|null $address) : void
Parameters
- $address : XdrSorobanAddressCredentials|null
setAddressV2()
public
setAddressV2(XdrSorobanAddressCredentials|null $addressV2) : void
Parameters
- $addressV2 : XdrSorobanAddressCredentials|null
setAddressWithDelegates()
public
setAddressWithDelegates(XdrSorobanAddressCredentialsWithDelegates|null $addressWithDelegates) : void
Parameters
- $addressWithDelegates : XdrSorobanAddressCredentialsWithDelegates|null
setType()
public
setType(XdrSorobanCredentialsType $type) : void
Parameters
- $type : XdrSorobanCredentialsType
toBase64Xdr()
public
toBase64Xdr() : string
Return values
stringtoJson()
public
toJson() : string
Tags
Return values
stringtoJsonValue()
public
toJsonValue() : mixed
toTxRep()
public
toTxRep(string $prefix, array<string|int, mixed> &$lines) : void
Parameters
- $prefix : string
- $lines : array<string|int, mixed>