xdb-digitalbits-base
Version:
Low level digitalbits support library
1,903 lines (1,242 loc) • 221 kB
TypeScript
// The type definitions inside the namespace xdr were automatically generated on 2021-03-19T18:40:30Z
// using https://github.com/xdbfoundation/dts-xdr.
// DO NOT EDIT definitions inside the xdr namespace or your changes may be overwritten
import { Operation } from './index';
export {};
// Hidden namespace as hack to work around name collision.
declare namespace xdrHidden {
// tslint:disable-line:strict-export-declare-modifiers
class Operation2<T extends Operation = Operation> {
constructor(attributes: {
sourceAccount: null | xdr.MuxedAccount;
body: xdr.OperationBody;
});
sourceAccount(value?: null | xdr.MuxedAccount): null | xdr.MuxedAccount;
body(value?: xdr.OperationBody): xdr.OperationBody;
toXDR(format?: 'raw'): Buffer;
toXDR(format: 'hex' | 'base64'): string;
static read(io: Buffer): xdr.Operation;
static write(value: xdr.Operation, io: Buffer): void;
static isValid(value: xdr.Operation): boolean;
static toXDR(value: xdr.Operation): Buffer;
static fromXDR(input: Buffer, format?: 'raw'): xdr.Operation;
static fromXDR(input: string, format: 'hex' | 'base64'): xdr.Operation;
static validateXDR(input: Buffer, format?: 'raw'): boolean;
static validateXDR(input: string, format: 'hex' | 'base64'): boolean;
}
}
export namespace xdr {
export import Operation = xdrHidden.Operation2; // tslint:disable-line:strict-export-declare-modifiers
interface SignedInt {
readonly MAX_VALUE: 2147483647;
readonly MIN_VALUE: -2147483648;
read(io: Buffer): number;
write(value: number, io: Buffer): void;
isValid(value: number): boolean;
toXDR(value: number): Buffer;
fromXDR(input: Buffer, format?: 'raw'): number;
fromXDR(input: string, format: 'hex' | 'base64'): number;
validateXDR(input: Buffer, format?: 'raw'): boolean;
validateXDR(input: string, format: 'hex' | 'base64'): boolean;
}
interface UnsignedInt {
readonly MAX_VALUE: 4294967295;
readonly MIN_VALUE: 0;
read(io: Buffer): number;
write(value: number, io: Buffer): void;
isValid(value: number): boolean;
toXDR(value: number): Buffer;
fromXDR(input: Buffer, format?: 'raw'): number;
fromXDR(input: string, format: 'hex' | 'base64'): number;
validateXDR(input: Buffer, format?: 'raw'): boolean;
validateXDR(input: string, format: 'hex' | 'base64'): boolean;
}
class Hyper {
low: number;
high: number;
unsigned: boolean;
constructor(low: number, high: number);
toXDR(format?: 'raw'): Buffer;
toXDR(format: 'hex' | 'base64'): string;
static toXDR(value: Hyper): Buffer;
static fromXDR(input: Buffer, format?: 'raw'): Hyper;
static fromXDR(input: string, format: 'hex' | 'base64'): Hyper;
static validateXDR(input: Buffer, format?: 'raw'): boolean;
static validateXDR(input: string, format: 'hex' | 'base64'): boolean;
static readonly MAX_VALUE: Hyper;
static readonly MIN_VALUE: Hyper;
static read(io: Buffer): Hyper;
static write(value: Hyper, io: Buffer): void;
static fromString(input: string): Hyper;
static fromBytes(low: number, high: number): Hyper;
static isValid(value: Hyper): boolean;
}
class UnsignedHyper {
low: number;
high: number;
unsigned: boolean;
constructor(low: number, high: number);
toXDR(format?: 'raw'): Buffer;
toXDR(format: 'hex' | 'base64'): string;
static toXDR(value: UnsignedHyper): Buffer;
static fromXDR(input: Buffer, format?: 'raw'): UnsignedHyper;
static fromXDR(input: string, format: 'hex' | 'base64'): UnsignedHyper;
static validateXDR(input: Buffer, format?: 'raw'): boolean;
static validateXDR(input: string, format: 'hex' | 'base64'): boolean;
static readonly MAX_VALUE: UnsignedHyper;
static readonly MIN_VALUE: UnsignedHyper;
static read(io: Buffer): UnsignedHyper;
static write(value: UnsignedHyper, io: Buffer): void;
static fromString(input: string): UnsignedHyper;
static fromBytes(low: number, high: number): UnsignedHyper;
static isValid(value: UnsignedHyper): boolean;
}
class XDRString {
constructor(maxLength: 4294967295);
read(io: Buffer): Buffer;
readString(io: Buffer): string;
write(value: string | Buffer, io: Buffer): void;
isValid(value: string | number[] | Buffer): boolean;
toXDR(value: string | Buffer): Buffer;
fromXDR(input: Buffer, format?: 'raw'): Buffer;
fromXDR(input: string, format: 'hex' | 'base64'): Buffer;
validateXDR(input: Buffer, format?: 'raw'): boolean;
validateXDR(input: string, format: 'hex' | 'base64'): boolean;
}
class XDRArray<T> {
read(io: Buffer): Buffer;
write(value: T[], io: Buffer): void;
isValid(value: T[]): boolean;
toXDR(value: T[]): Buffer;
fromXDR(input: Buffer, format?: 'raw'): T[];
fromXDR(input: string, format: 'hex' | 'base64'): T[];
validateXDR(input: Buffer, format?: 'raw'): boolean;
validateXDR(input: string, format: 'hex' | 'base64'): boolean;
}
class Opaque {
constructor(length: number);
read(io: Buffer): Buffer;
write(value: Buffer, io: Buffer): void;
isValid(value: Buffer): boolean;
toXDR(value: Buffer): Buffer;
fromXDR(input: Buffer, format?: 'raw'): Buffer;
fromXDR(input: string, format: 'hex' | 'base64'): Buffer;
validateXDR(input: Buffer, format?: 'raw'): boolean;
validateXDR(input: string, format: 'hex' | 'base64'): boolean;
}
class VarOpaque extends Opaque {}
class Option {
constructor(childType: {
read(io: any): any;
write(value: any, io: Buffer): void;
isValid(value: any): boolean;
});
read(io: Buffer): any;
write(value: any, io: Buffer): void;
isValid(value: any): boolean;
toXDR(value: any): Buffer;
fromXDR(input: Buffer, format?: 'raw'): any;
fromXDR(input: string, format: 'hex' | 'base64'): any;
validateXDR(input: Buffer, format?: 'raw'): boolean;
validateXDR(input: string, format: 'hex' | 'base64'): boolean;
}
class AssetType {
readonly name:
| 'assetTypeNative'
| 'assetTypeCreditAlphanum4'
| 'assetTypeCreditAlphanum12';
readonly value: 0 | 1 | 2;
static assetTypeNative(): AssetType;
static assetTypeCreditAlphanum4(): AssetType;
static assetTypeCreditAlphanum12(): AssetType;
}
class ThresholdIndices {
readonly name:
| 'thresholdMasterWeight'
| 'thresholdLow'
| 'thresholdMed'
| 'thresholdHigh';
readonly value: 0 | 1 | 2 | 3;
static thresholdMasterWeight(): ThresholdIndices;
static thresholdLow(): ThresholdIndices;
static thresholdMed(): ThresholdIndices;
static thresholdHigh(): ThresholdIndices;
}
class LedgerEntryType {
readonly name:
| 'account'
| 'trustline'
| 'offer'
| 'data'
| 'claimableBalance';
readonly value: 0 | 1 | 2 | 3 | 4;
static account(): LedgerEntryType;
static trustline(): LedgerEntryType;
static offer(): LedgerEntryType;
static data(): LedgerEntryType;
static claimableBalance(): LedgerEntryType;
}
class AccountFlags {
readonly name:
| 'authRequiredFlag'
| 'authRevocableFlag'
| 'authImmutableFlag'
| 'authClawbackEnabledFlag';
readonly value: 1 | 2 | 4 | 8;
static authRequiredFlag(): AccountFlags;
static authRevocableFlag(): AccountFlags;
static authImmutableFlag(): AccountFlags;
static authClawbackEnabledFlag(): AccountFlags;
}
class TrustLineFlags {
readonly name:
| 'authorizedFlag'
| 'authorizedToMaintainLiabilitiesFlag'
| 'trustlineClawbackEnabledFlag';
readonly value: 1 | 2 | 4;
static authorizedFlag(): TrustLineFlags;
static authorizedToMaintainLiabilitiesFlag(): TrustLineFlags;
static trustlineClawbackEnabledFlag(): TrustLineFlags;
}
class OfferEntryFlags {
readonly name: 'passiveFlag';
readonly value: 1;
static passiveFlag(): OfferEntryFlags;
}
class ClaimPredicateType {
readonly name:
| 'claimPredicateUnconditional'
| 'claimPredicateAnd'
| 'claimPredicateOr'
| 'claimPredicateNot'
| 'claimPredicateBeforeAbsoluteTime'
| 'claimPredicateBeforeRelativeTime';
readonly value: 0 | 1 | 2 | 3 | 4 | 5;
static claimPredicateUnconditional(): ClaimPredicateType;
static claimPredicateAnd(): ClaimPredicateType;
static claimPredicateOr(): ClaimPredicateType;
static claimPredicateNot(): ClaimPredicateType;
static claimPredicateBeforeAbsoluteTime(): ClaimPredicateType;
static claimPredicateBeforeRelativeTime(): ClaimPredicateType;
}
class ClaimantType {
readonly name: 'claimantTypeV0';
readonly value: 0;
static claimantTypeV0(): ClaimantType;
}
class ClaimableBalanceIdType {
readonly name: 'claimableBalanceIdTypeV0';
readonly value: 0;
static claimableBalanceIdTypeV0(): ClaimableBalanceIdType;
}
class ClaimableBalanceFlags {
readonly name: 'claimableBalanceClawbackEnabledFlag';
readonly value: 1;
static claimableBalanceClawbackEnabledFlag(): ClaimableBalanceFlags;
}
class EnvelopeType {
readonly name:
| 'envelopeTypeTxV0'
| 'envelopeTypeScp'
| 'envelopeTypeTx'
| 'envelopeTypeAuth'
| 'envelopeTypeScpvalue'
| 'envelopeTypeTxFeeBump'
| 'envelopeTypeOpId';
readonly value: 0 | 1 | 2 | 3 | 4 | 5 | 6;
static envelopeTypeTxV0(): EnvelopeType;
static envelopeTypeScp(): EnvelopeType;
static envelopeTypeTx(): EnvelopeType;
static envelopeTypeAuth(): EnvelopeType;
static envelopeTypeScpvalue(): EnvelopeType;
static envelopeTypeTxFeeBump(): EnvelopeType;
static envelopeTypeOpId(): EnvelopeType;
}
class DigitalBitsValueType {
readonly name: 'digitalBitsValueBasic' | 'digitalBitsValueSigned';
readonly value: 0 | 1;
static digitalBitsValueBasic(): DigitalBitsValueType;
static digitalBitsValueSigned(): DigitalBitsValueType;
}
class LedgerUpgradeType {
readonly name:
| 'ledgerUpgradeVersion'
| 'ledgerUpgradeBaseFee'
| 'ledgerUpgradeMaxTxSetSize'
| 'ledgerUpgradeBaseReserve';
readonly value: 1 | 2 | 3 | 4;
static ledgerUpgradeVersion(): LedgerUpgradeType;
static ledgerUpgradeBaseFee(): LedgerUpgradeType;
static ledgerUpgradeMaxTxSetSize(): LedgerUpgradeType;
static ledgerUpgradeBaseReserve(): LedgerUpgradeType;
}
class BucketEntryType {
readonly name: 'metaentry' | 'liveentry' | 'deadentry' | 'initentry';
readonly value: -1 | 0 | 1 | 2;
static metaentry(): BucketEntryType;
static liveentry(): BucketEntryType;
static deadentry(): BucketEntryType;
static initentry(): BucketEntryType;
}
class LedgerEntryChangeType {
readonly name:
| 'ledgerEntryCreated'
| 'ledgerEntryUpdated'
| 'ledgerEntryRemoved'
| 'ledgerEntryState';
readonly value: 0 | 1 | 2 | 3;
static ledgerEntryCreated(): LedgerEntryChangeType;
static ledgerEntryUpdated(): LedgerEntryChangeType;
static ledgerEntryRemoved(): LedgerEntryChangeType;
static ledgerEntryState(): LedgerEntryChangeType;
}
class ErrorCode {
readonly name: 'errMisc' | 'errData' | 'errConf' | 'errAuth' | 'errLoad';
readonly value: 0 | 1 | 2 | 3 | 4;
static errMisc(): ErrorCode;
static errData(): ErrorCode;
static errConf(): ErrorCode;
static errAuth(): ErrorCode;
static errLoad(): ErrorCode;
}
class IpAddrType {
readonly name: 'iPv4' | 'iPv6';
readonly value: 0 | 1;
static iPv4(): IpAddrType;
static iPv6(): IpAddrType;
}
class MessageType {
readonly name:
| 'errorMsg'
| 'auth'
| 'dontHave'
| 'getPeers'
| 'peers'
| 'getTxSet'
| 'txSet'
| 'transaction'
| 'getScpQuorumset'
| 'scpQuorumset'
| 'scpMessage'
| 'getScpState'
| 'hello'
| 'surveyRequest'
| 'surveyResponse';
readonly value:
| 0
| 2
| 3
| 4
| 5
| 6
| 7
| 8
| 9
| 10
| 11
| 12
| 13
| 14
| 15;
static errorMsg(): MessageType;
static auth(): MessageType;
static dontHave(): MessageType;
static getPeers(): MessageType;
static peers(): MessageType;
static getTxSet(): MessageType;
static txSet(): MessageType;
static transaction(): MessageType;
static getScpQuorumset(): MessageType;
static scpQuorumset(): MessageType;
static scpMessage(): MessageType;
static getScpState(): MessageType;
static hello(): MessageType;
static surveyRequest(): MessageType;
static surveyResponse(): MessageType;
}
class SurveyMessageCommandType {
readonly name: 'surveyTopology';
readonly value: 0;
static surveyTopology(): SurveyMessageCommandType;
}
class ScpStatementType {
readonly name:
| 'scpStPrepare'
| 'scpStConfirm'
| 'scpStExternalize'
| 'scpStNominate';
readonly value: 0 | 1 | 2 | 3;
static scpStPrepare(): ScpStatementType;
static scpStConfirm(): ScpStatementType;
static scpStExternalize(): ScpStatementType;
static scpStNominate(): ScpStatementType;
}
class OperationType {
readonly name:
| 'createAccount'
| 'payment'
| 'pathPaymentStrictReceive'
| 'manageSellOffer'
| 'createPassiveSellOffer'
| 'setOptions'
| 'changeTrust'
| 'allowTrust'
| 'accountMerge'
| 'inflation'
| 'manageData'
| 'bumpSequence'
| 'manageBuyOffer'
| 'pathPaymentStrictSend'
| 'createClaimableBalance'
| 'claimClaimableBalance'
| 'beginSponsoringFutureReserves'
| 'endSponsoringFutureReserves'
| 'revokeSponsorship'
| 'clawback'
| 'clawbackClaimableBalance'
| 'setTrustLineFlags';
readonly value:
| 0
| 1
| 2
| 3
| 4
| 5
| 6
| 7
| 8
| 9
| 10
| 11
| 12
| 13
| 14
| 15
| 16
| 17
| 18
| 19
| 20
| 21;
static createAccount(): OperationType;
static payment(): OperationType;
static pathPaymentStrictReceive(): OperationType;
static manageSellOffer(): OperationType;
static createPassiveSellOffer(): OperationType;
static setOptions(): OperationType;
static changeTrust(): OperationType;
static allowTrust(): OperationType;
static accountMerge(): OperationType;
static inflation(): OperationType;
static manageData(): OperationType;
static bumpSequence(): OperationType;
static manageBuyOffer(): OperationType;
static pathPaymentStrictSend(): OperationType;
static createClaimableBalance(): OperationType;
static claimClaimableBalance(): OperationType;
static beginSponsoringFutureReserves(): OperationType;
static endSponsoringFutureReserves(): OperationType;
static revokeSponsorship(): OperationType;
static clawback(): OperationType;
static clawbackClaimableBalance(): OperationType;
static setTrustLineFlags(): OperationType;
}
class RevokeSponsorshipType {
readonly name: 'revokeSponsorshipLedgerEntry' | 'revokeSponsorshipSigner';
readonly value: 0 | 1;
static revokeSponsorshipLedgerEntry(): RevokeSponsorshipType;
static revokeSponsorshipSigner(): RevokeSponsorshipType;
}
class MemoType {
readonly name:
| 'memoNone'
| 'memoText'
| 'memoId'
| 'memoHash'
| 'memoReturn';
readonly value: 0 | 1 | 2 | 3 | 4;
static memoNone(): MemoType;
static memoText(): MemoType;
static memoId(): MemoType;
static memoHash(): MemoType;
static memoReturn(): MemoType;
}
class CreateAccountResultCode {
readonly name:
| 'createAccountSuccess'
| 'createAccountMalformed'
| 'createAccountUnderfunded'
| 'createAccountLowReserve'
| 'createAccountAlreadyExist';
readonly value: 0 | -1 | -2 | -3 | -4;
static createAccountSuccess(): CreateAccountResultCode;
static createAccountMalformed(): CreateAccountResultCode;
static createAccountUnderfunded(): CreateAccountResultCode;
static createAccountLowReserve(): CreateAccountResultCode;
static createAccountAlreadyExist(): CreateAccountResultCode;
}
class PaymentResultCode {
readonly name:
| 'paymentSuccess'
| 'paymentMalformed'
| 'paymentUnderfunded'
| 'paymentSrcNoTrust'
| 'paymentSrcNotAuthorized'
| 'paymentNoDestination'
| 'paymentNoTrust'
| 'paymentNotAuthorized'
| 'paymentLineFull'
| 'paymentNoIssuer';
readonly value: 0 | -1 | -2 | -3 | -4 | -5 | -6 | -7 | -8 | -9;
static paymentSuccess(): PaymentResultCode;
static paymentMalformed(): PaymentResultCode;
static paymentUnderfunded(): PaymentResultCode;
static paymentSrcNoTrust(): PaymentResultCode;
static paymentSrcNotAuthorized(): PaymentResultCode;
static paymentNoDestination(): PaymentResultCode;
static paymentNoTrust(): PaymentResultCode;
static paymentNotAuthorized(): PaymentResultCode;
static paymentLineFull(): PaymentResultCode;
static paymentNoIssuer(): PaymentResultCode;
}
class PathPaymentStrictReceiveResultCode {
readonly name:
| 'pathPaymentStrictReceiveSuccess'
| 'pathPaymentStrictReceiveMalformed'
| 'pathPaymentStrictReceiveUnderfunded'
| 'pathPaymentStrictReceiveSrcNoTrust'
| 'pathPaymentStrictReceiveSrcNotAuthorized'
| 'pathPaymentStrictReceiveNoDestination'
| 'pathPaymentStrictReceiveNoTrust'
| 'pathPaymentStrictReceiveNotAuthorized'
| 'pathPaymentStrictReceiveLineFull'
| 'pathPaymentStrictReceiveNoIssuer'
| 'pathPaymentStrictReceiveTooFewOffers'
| 'pathPaymentStrictReceiveOfferCrossSelf'
| 'pathPaymentStrictReceiveOverSendmax';
readonly value:
| 0
| -1
| -2
| -3
| -4
| -5
| -6
| -7
| -8
| -9
| -10
| -11
| -12;
static pathPaymentStrictReceiveSuccess(): PathPaymentStrictReceiveResultCode;
static pathPaymentStrictReceiveMalformed(): PathPaymentStrictReceiveResultCode;
static pathPaymentStrictReceiveUnderfunded(): PathPaymentStrictReceiveResultCode;
static pathPaymentStrictReceiveSrcNoTrust(): PathPaymentStrictReceiveResultCode;
static pathPaymentStrictReceiveSrcNotAuthorized(): PathPaymentStrictReceiveResultCode;
static pathPaymentStrictReceiveNoDestination(): PathPaymentStrictReceiveResultCode;
static pathPaymentStrictReceiveNoTrust(): PathPaymentStrictReceiveResultCode;
static pathPaymentStrictReceiveNotAuthorized(): PathPaymentStrictReceiveResultCode;
static pathPaymentStrictReceiveLineFull(): PathPaymentStrictReceiveResultCode;
static pathPaymentStrictReceiveNoIssuer(): PathPaymentStrictReceiveResultCode;
static pathPaymentStrictReceiveTooFewOffers(): PathPaymentStrictReceiveResultCode;
static pathPaymentStrictReceiveOfferCrossSelf(): PathPaymentStrictReceiveResultCode;
static pathPaymentStrictReceiveOverSendmax(): PathPaymentStrictReceiveResultCode;
}
class PathPaymentStrictSendResultCode {
readonly name:
| 'pathPaymentStrictSendSuccess'
| 'pathPaymentStrictSendMalformed'
| 'pathPaymentStrictSendUnderfunded'
| 'pathPaymentStrictSendSrcNoTrust'
| 'pathPaymentStrictSendSrcNotAuthorized'
| 'pathPaymentStrictSendNoDestination'
| 'pathPaymentStrictSendNoTrust'
| 'pathPaymentStrictSendNotAuthorized'
| 'pathPaymentStrictSendLineFull'
| 'pathPaymentStrictSendNoIssuer'
| 'pathPaymentStrictSendTooFewOffers'
| 'pathPaymentStrictSendOfferCrossSelf'
| 'pathPaymentStrictSendUnderDestmin';
readonly value:
| 0
| -1
| -2
| -3
| -4
| -5
| -6
| -7
| -8
| -9
| -10
| -11
| -12;
static pathPaymentStrictSendSuccess(): PathPaymentStrictSendResultCode;
static pathPaymentStrictSendMalformed(): PathPaymentStrictSendResultCode;
static pathPaymentStrictSendUnderfunded(): PathPaymentStrictSendResultCode;
static pathPaymentStrictSendSrcNoTrust(): PathPaymentStrictSendResultCode;
static pathPaymentStrictSendSrcNotAuthorized(): PathPaymentStrictSendResultCode;
static pathPaymentStrictSendNoDestination(): PathPaymentStrictSendResultCode;
static pathPaymentStrictSendNoTrust(): PathPaymentStrictSendResultCode;
static pathPaymentStrictSendNotAuthorized(): PathPaymentStrictSendResultCode;
static pathPaymentStrictSendLineFull(): PathPaymentStrictSendResultCode;
static pathPaymentStrictSendNoIssuer(): PathPaymentStrictSendResultCode;
static pathPaymentStrictSendTooFewOffers(): PathPaymentStrictSendResultCode;
static pathPaymentStrictSendOfferCrossSelf(): PathPaymentStrictSendResultCode;
static pathPaymentStrictSendUnderDestmin(): PathPaymentStrictSendResultCode;
}
class ManageSellOfferResultCode {
readonly name:
| 'manageSellOfferSuccess'
| 'manageSellOfferMalformed'
| 'manageSellOfferSellNoTrust'
| 'manageSellOfferBuyNoTrust'
| 'manageSellOfferSellNotAuthorized'
| 'manageSellOfferBuyNotAuthorized'
| 'manageSellOfferLineFull'
| 'manageSellOfferUnderfunded'
| 'manageSellOfferCrossSelf'
| 'manageSellOfferSellNoIssuer'
| 'manageSellOfferBuyNoIssuer'
| 'manageSellOfferNotFound'
| 'manageSellOfferLowReserve';
readonly value:
| 0
| -1
| -2
| -3
| -4
| -5
| -6
| -7
| -8
| -9
| -10
| -11
| -12;
static manageSellOfferSuccess(): ManageSellOfferResultCode;
static manageSellOfferMalformed(): ManageSellOfferResultCode;
static manageSellOfferSellNoTrust(): ManageSellOfferResultCode;
static manageSellOfferBuyNoTrust(): ManageSellOfferResultCode;
static manageSellOfferSellNotAuthorized(): ManageSellOfferResultCode;
static manageSellOfferBuyNotAuthorized(): ManageSellOfferResultCode;
static manageSellOfferLineFull(): ManageSellOfferResultCode;
static manageSellOfferUnderfunded(): ManageSellOfferResultCode;
static manageSellOfferCrossSelf(): ManageSellOfferResultCode;
static manageSellOfferSellNoIssuer(): ManageSellOfferResultCode;
static manageSellOfferBuyNoIssuer(): ManageSellOfferResultCode;
static manageSellOfferNotFound(): ManageSellOfferResultCode;
static manageSellOfferLowReserve(): ManageSellOfferResultCode;
}
class ManageOfferEffect {
readonly name:
| 'manageOfferCreated'
| 'manageOfferUpdated'
| 'manageOfferDeleted';
readonly value: 0 | 1 | 2;
static manageOfferCreated(): ManageOfferEffect;
static manageOfferUpdated(): ManageOfferEffect;
static manageOfferDeleted(): ManageOfferEffect;
}
class ManageBuyOfferResultCode {
readonly name:
| 'manageBuyOfferSuccess'
| 'manageBuyOfferMalformed'
| 'manageBuyOfferSellNoTrust'
| 'manageBuyOfferBuyNoTrust'
| 'manageBuyOfferSellNotAuthorized'
| 'manageBuyOfferBuyNotAuthorized'
| 'manageBuyOfferLineFull'
| 'manageBuyOfferUnderfunded'
| 'manageBuyOfferCrossSelf'
| 'manageBuyOfferSellNoIssuer'
| 'manageBuyOfferBuyNoIssuer'
| 'manageBuyOfferNotFound'
| 'manageBuyOfferLowReserve';
readonly value:
| 0
| -1
| -2
| -3
| -4
| -5
| -6
| -7
| -8
| -9
| -10
| -11
| -12;
static manageBuyOfferSuccess(): ManageBuyOfferResultCode;
static manageBuyOfferMalformed(): ManageBuyOfferResultCode;
static manageBuyOfferSellNoTrust(): ManageBuyOfferResultCode;
static manageBuyOfferBuyNoTrust(): ManageBuyOfferResultCode;
static manageBuyOfferSellNotAuthorized(): ManageBuyOfferResultCode;
static manageBuyOfferBuyNotAuthorized(): ManageBuyOfferResultCode;
static manageBuyOfferLineFull(): ManageBuyOfferResultCode;
static manageBuyOfferUnderfunded(): ManageBuyOfferResultCode;
static manageBuyOfferCrossSelf(): ManageBuyOfferResultCode;
static manageBuyOfferSellNoIssuer(): ManageBuyOfferResultCode;
static manageBuyOfferBuyNoIssuer(): ManageBuyOfferResultCode;
static manageBuyOfferNotFound(): ManageBuyOfferResultCode;
static manageBuyOfferLowReserve(): ManageBuyOfferResultCode;
}
class SetOptionsResultCode {
readonly name:
| 'setOptionsSuccess'
| 'setOptionsLowReserve'
| 'setOptionsTooManySigners'
| 'setOptionsBadFlags'
| 'setOptionsInvalidInflation'
| 'setOptionsCantChange'
| 'setOptionsUnknownFlag'
| 'setOptionsThresholdOutOfRange'
| 'setOptionsBadSigner'
| 'setOptionsInvalidHomeDomain'
| 'setOptionsAuthRevocableRequired';
readonly value: 0 | -1 | -2 | -3 | -4 | -5 | -6 | -7 | -8 | -9 | -10;
static setOptionsSuccess(): SetOptionsResultCode;
static setOptionsLowReserve(): SetOptionsResultCode;
static setOptionsTooManySigners(): SetOptionsResultCode;
static setOptionsBadFlags(): SetOptionsResultCode;
static setOptionsInvalidInflation(): SetOptionsResultCode;
static setOptionsCantChange(): SetOptionsResultCode;
static setOptionsUnknownFlag(): SetOptionsResultCode;
static setOptionsThresholdOutOfRange(): SetOptionsResultCode;
static setOptionsBadSigner(): SetOptionsResultCode;
static setOptionsInvalidHomeDomain(): SetOptionsResultCode;
static setOptionsAuthRevocableRequired(): SetOptionsResultCode;
}
class ChangeTrustResultCode {
readonly name:
| 'changeTrustSuccess'
| 'changeTrustMalformed'
| 'changeTrustNoIssuer'
| 'changeTrustInvalidLimit'
| 'changeTrustLowReserve'
| 'changeTrustSelfNotAllowed';
readonly value: 0 | -1 | -2 | -3 | -4 | -5;
static changeTrustSuccess(): ChangeTrustResultCode;
static changeTrustMalformed(): ChangeTrustResultCode;
static changeTrustNoIssuer(): ChangeTrustResultCode;
static changeTrustInvalidLimit(): ChangeTrustResultCode;
static changeTrustLowReserve(): ChangeTrustResultCode;
static changeTrustSelfNotAllowed(): ChangeTrustResultCode;
}
class AllowTrustResultCode {
readonly name:
| 'allowTrustSuccess'
| 'allowTrustMalformed'
| 'allowTrustNoTrustLine'
| 'allowTrustTrustNotRequired'
| 'allowTrustCantRevoke'
| 'allowTrustSelfNotAllowed';
readonly value: 0 | -1 | -2 | -3 | -4 | -5;
static allowTrustSuccess(): AllowTrustResultCode;
static allowTrustMalformed(): AllowTrustResultCode;
static allowTrustNoTrustLine(): AllowTrustResultCode;
static allowTrustTrustNotRequired(): AllowTrustResultCode;
static allowTrustCantRevoke(): AllowTrustResultCode;
static allowTrustSelfNotAllowed(): AllowTrustResultCode;
}
class AccountMergeResultCode {
readonly name:
| 'accountMergeSuccess'
| 'accountMergeMalformed'
| 'accountMergeNoAccount'
| 'accountMergeImmutableSet'
| 'accountMergeHasSubEntries'
| 'accountMergeSeqnumTooFar'
| 'accountMergeDestFull'
| 'accountMergeIsSponsor';
readonly value: 0 | -1 | -2 | -3 | -4 | -5 | -6 | -7;
static accountMergeSuccess(): AccountMergeResultCode;
static accountMergeMalformed(): AccountMergeResultCode;
static accountMergeNoAccount(): AccountMergeResultCode;
static accountMergeImmutableSet(): AccountMergeResultCode;
static accountMergeHasSubEntries(): AccountMergeResultCode;
static accountMergeSeqnumTooFar(): AccountMergeResultCode;
static accountMergeDestFull(): AccountMergeResultCode;
static accountMergeIsSponsor(): AccountMergeResultCode;
}
class InflationResultCode {
readonly name: 'inflationSuccess' | 'inflationNotTime';
readonly value: 0 | -1;
static inflationSuccess(): InflationResultCode;
static inflationNotTime(): InflationResultCode;
}
class ManageDataResultCode {
readonly name:
| 'manageDataSuccess'
| 'manageDataNotSupportedYet'
| 'manageDataNameNotFound'
| 'manageDataLowReserve'
| 'manageDataInvalidName';
readonly value: 0 | -1 | -2 | -3 | -4;
static manageDataSuccess(): ManageDataResultCode;
static manageDataNotSupportedYet(): ManageDataResultCode;
static manageDataNameNotFound(): ManageDataResultCode;
static manageDataLowReserve(): ManageDataResultCode;
static manageDataInvalidName(): ManageDataResultCode;
}
class BumpSequenceResultCode {
readonly name: 'bumpSequenceSuccess' | 'bumpSequenceBadSeq';
readonly value: 0 | -1;
static bumpSequenceSuccess(): BumpSequenceResultCode;
static bumpSequenceBadSeq(): BumpSequenceResultCode;
}
class CreateClaimableBalanceResultCode {
readonly name:
| 'createClaimableBalanceSuccess'
| 'createClaimableBalanceMalformed'
| 'createClaimableBalanceLowReserve'
| 'createClaimableBalanceNoTrust'
| 'createClaimableBalanceNotAuthorized'
| 'createClaimableBalanceUnderfunded';
readonly value: 0 | -1 | -2 | -3 | -4 | -5;
static createClaimableBalanceSuccess(): CreateClaimableBalanceResultCode;
static createClaimableBalanceMalformed(): CreateClaimableBalanceResultCode;
static createClaimableBalanceLowReserve(): CreateClaimableBalanceResultCode;
static createClaimableBalanceNoTrust(): CreateClaimableBalanceResultCode;
static createClaimableBalanceNotAuthorized(): CreateClaimableBalanceResultCode;
static createClaimableBalanceUnderfunded(): CreateClaimableBalanceResultCode;
}
class ClaimClaimableBalanceResultCode {
readonly name:
| 'claimClaimableBalanceSuccess'
| 'claimClaimableBalanceDoesNotExist'
| 'claimClaimableBalanceCannotClaim'
| 'claimClaimableBalanceLineFull'
| 'claimClaimableBalanceNoTrust'
| 'claimClaimableBalanceNotAuthorized';
readonly value: 0 | -1 | -2 | -3 | -4 | -5;
static claimClaimableBalanceSuccess(): ClaimClaimableBalanceResultCode;
static claimClaimableBalanceDoesNotExist(): ClaimClaimableBalanceResultCode;
static claimClaimableBalanceCannotClaim(): ClaimClaimableBalanceResultCode;
static claimClaimableBalanceLineFull(): ClaimClaimableBalanceResultCode;
static claimClaimableBalanceNoTrust(): ClaimClaimableBalanceResultCode;
static claimClaimableBalanceNotAuthorized(): ClaimClaimableBalanceResultCode;
}
class BeginSponsoringFutureReservesResultCode {
readonly name:
| 'beginSponsoringFutureReservesSuccess'
| 'beginSponsoringFutureReservesMalformed'
| 'beginSponsoringFutureReservesAlreadySponsored'
| 'beginSponsoringFutureReservesRecursive';
readonly value: 0 | -1 | -2 | -3;
static beginSponsoringFutureReservesSuccess(): BeginSponsoringFutureReservesResultCode;
static beginSponsoringFutureReservesMalformed(): BeginSponsoringFutureReservesResultCode;
static beginSponsoringFutureReservesAlreadySponsored(): BeginSponsoringFutureReservesResultCode;
static beginSponsoringFutureReservesRecursive(): BeginSponsoringFutureReservesResultCode;
}
class EndSponsoringFutureReservesResultCode {
readonly name:
| 'endSponsoringFutureReservesSuccess'
| 'endSponsoringFutureReservesNotSponsored';
readonly value: 0 | -1;
static endSponsoringFutureReservesSuccess(): EndSponsoringFutureReservesResultCode;
static endSponsoringFutureReservesNotSponsored(): EndSponsoringFutureReservesResultCode;
}
class RevokeSponsorshipResultCode {
readonly name:
| 'revokeSponsorshipSuccess'
| 'revokeSponsorshipDoesNotExist'
| 'revokeSponsorshipNotSponsor'
| 'revokeSponsorshipLowReserve'
| 'revokeSponsorshipOnlyTransferable';
readonly value: 0 | -1 | -2 | -3 | -4;
static revokeSponsorshipSuccess(): RevokeSponsorshipResultCode;
static revokeSponsorshipDoesNotExist(): RevokeSponsorshipResultCode;
static revokeSponsorshipNotSponsor(): RevokeSponsorshipResultCode;
static revokeSponsorshipLowReserve(): RevokeSponsorshipResultCode;
static revokeSponsorshipOnlyTransferable(): RevokeSponsorshipResultCode;
}
class ClawbackResultCode {
readonly name:
| 'clawbackSuccess'
| 'clawbackMalformed'
| 'clawbackNotClawbackEnabled'
| 'clawbackNoTrust'
| 'clawbackUnderfunded';
readonly value: 0 | -1 | -2 | -3 | -4;
static clawbackSuccess(): ClawbackResultCode;
static clawbackMalformed(): ClawbackResultCode;
static clawbackNotClawbackEnabled(): ClawbackResultCode;
static clawbackNoTrust(): ClawbackResultCode;
static clawbackUnderfunded(): ClawbackResultCode;
}
class ClawbackClaimableBalanceResultCode {
readonly name:
| 'clawbackClaimableBalanceSuccess'
| 'clawbackClaimableBalanceDoesNotExist'
| 'clawbackClaimableBalanceNotIssuer'
| 'clawbackClaimableBalanceNotClawbackEnabled';
readonly value: 0 | -1 | -2 | -3;
static clawbackClaimableBalanceSuccess(): ClawbackClaimableBalanceResultCode;
static clawbackClaimableBalanceDoesNotExist(): ClawbackClaimableBalanceResultCode;
static clawbackClaimableBalanceNotIssuer(): ClawbackClaimableBalanceResultCode;
static clawbackClaimableBalanceNotClawbackEnabled(): ClawbackClaimableBalanceResultCode;
}
class SetTrustLineFlagsResultCode {
readonly name:
| 'setTrustLineFlagsSuccess'
| 'setTrustLineFlagsMalformed'
| 'setTrustLineFlagsNoTrustLine'
| 'setTrustLineFlagsCantRevoke'
| 'setTrustLineFlagsInvalidState';
readonly value: 0 | -1 | -2 | -3 | -4;
static setTrustLineFlagsSuccess(): SetTrustLineFlagsResultCode;
static setTrustLineFlagsMalformed(): SetTrustLineFlagsResultCode;
static setTrustLineFlagsNoTrustLine(): SetTrustLineFlagsResultCode;
static setTrustLineFlagsCantRevoke(): SetTrustLineFlagsResultCode;
static setTrustLineFlagsInvalidState(): SetTrustLineFlagsResultCode;
}
class OperationResultCode {
readonly name:
| 'opInner'
| 'opBadAuth'
| 'opNoAccount'
| 'opNotSupported'
| 'opTooManySubentries'
| 'opExceededWorkLimit'
| 'opTooManySponsoring';
readonly value: 0 | -1 | -2 | -3 | -4 | -5 | -6;
static opInner(): OperationResultCode;
static opBadAuth(): OperationResultCode;
static opNoAccount(): OperationResultCode;
static opNotSupported(): OperationResultCode;
static opTooManySubentries(): OperationResultCode;
static opExceededWorkLimit(): OperationResultCode;
static opTooManySponsoring(): OperationResultCode;
}
class TransactionResultCode {
readonly name:
| 'txFeeBumpInnerSuccess'
| 'txSuccess'
| 'txFailed'
| 'txTooEarly'
| 'txTooLate'
| 'txMissingOperation'
| 'txBadSeq'
| 'txBadAuth'
| 'txInsufficientBalance'
| 'txNoAccount'
| 'txInsufficientFee'
| 'txBadAuthExtra'
| 'txInternalError'
| 'txNotSupported'
| 'txFeeBumpInnerFailed'
| 'txBadSponsorship';
readonly value:
| 1
| 0
| -1
| -2
| -3
| -4
| -5
| -6
| -7
| -8
| -9
| -10
| -11
| -12
| -13
| -14;
static txFeeBumpInnerSuccess(): TransactionResultCode;
static txSuccess(): TransactionResultCode;
static txFailed(): TransactionResultCode;
static txTooEarly(): TransactionResultCode;
static txTooLate(): TransactionResultCode;
static txMissingOperation(): TransactionResultCode;
static txBadSeq(): TransactionResultCode;
static txBadAuth(): TransactionResultCode;
static txInsufficientBalance(): TransactionResultCode;
static txNoAccount(): TransactionResultCode;
static txInsufficientFee(): TransactionResultCode;
static txBadAuthExtra(): TransactionResultCode;
static txInternalError(): TransactionResultCode;
static txNotSupported(): TransactionResultCode;
static txFeeBumpInnerFailed(): TransactionResultCode;
static txBadSponsorship(): TransactionResultCode;
}
class CryptoKeyType {
readonly name:
| 'keyTypeEd25519'
| 'keyTypePreAuthTx'
| 'keyTypeHashX'
| 'keyTypeMuxedEd25519';
readonly value: 0 | 1 | 2 | 256;
static keyTypeEd25519(): CryptoKeyType;
static keyTypePreAuthTx(): CryptoKeyType;
static keyTypeHashX(): CryptoKeyType;
static keyTypeMuxedEd25519(): CryptoKeyType;
}
class PublicKeyType {
readonly name: 'publicKeyTypeEd25519';
readonly value: 0;
static publicKeyTypeEd25519(): PublicKeyType;
}
class SignerKeyType {
readonly name:
| 'signerKeyTypeEd25519'
| 'signerKeyTypePreAuthTx'
| 'signerKeyTypeHashX';
readonly value: 0 | 1 | 2;
static signerKeyTypeEd25519(): SignerKeyType;
static signerKeyTypePreAuthTx(): SignerKeyType;
static signerKeyTypeHashX(): SignerKeyType;
}
type AccountId = PublicKey;
const Thresholds: Opaque;
const String32: XDRString;
const String64: XDRString;
type SequenceNumber = Int64;
type TimePoint = Uint64;
const DataValue: VarOpaque;
const AssetCode4: Opaque;
const AssetCode12: Opaque;
type SponsorshipDescriptor = undefined | AccountId;
const UpgradeType: VarOpaque;
const LedgerEntryChanges: XDRArray<LedgerEntryChange>;
const EncryptedBody: VarOpaque;
const PeerStatList: XDRArray<PeerStats>;
const Value: VarOpaque;
const Hash: Opaque;
const Uint256: Opaque;
const Uint32: UnsignedInt;
const Int32: SignedInt;
class Uint64 extends UnsignedHyper {}
class Int64 extends Hyper {}
const Signature: VarOpaque;
const SignatureHint: Opaque;
type NodeId = PublicKey;
class AssetAlphaNum4 {
constructor(attributes: { assetCode: Buffer; issuer: AccountId });
assetCode(value?: Buffer): Buffer;
issuer(value?: AccountId): AccountId;
toXDR(format?: 'raw'): Buffer;
toXDR(format: 'hex' | 'base64'): string;
static read(io: Buffer): AssetAlphaNum4;
static write(value: AssetAlphaNum4, io: Buffer): void;
static isValid(value: AssetAlphaNum4): boolean;
static toXDR(value: AssetAlphaNum4): Buffer;
static fromXDR(input: Buffer, format?: 'raw'): AssetAlphaNum4;
static fromXDR(input: string, format: 'hex' | 'base64'): AssetAlphaNum4;
static validateXDR(input: Buffer, format?: 'raw'): boolean;
static validateXDR(input: string, format: 'hex' | 'base64'): boolean;
}
class AssetAlphaNum12 {
constructor(attributes: { assetCode: Buffer; issuer: AccountId });
assetCode(value?: Buffer): Buffer;
issuer(value?: AccountId): AccountId;
toXDR(format?: 'raw'): Buffer;
toXDR(format: 'hex' | 'base64'): string;
static read(io: Buffer): AssetAlphaNum12;
static write(value: AssetAlphaNum12, io: Buffer): void;
static isValid(value: AssetAlphaNum12): boolean;
static toXDR(value: AssetAlphaNum12): Buffer;
static fromXDR(input: Buffer, format?: 'raw'): AssetAlphaNum12;
static fromXDR(input: string, format: 'hex' | 'base64'): AssetAlphaNum12;
static validateXDR(input: Buffer, format?: 'raw'): boolean;
static validateXDR(input: string, format: 'hex' | 'base64'): boolean;
}
class Price {
constructor(attributes: { n: number; d: number });
n(value?: number): number;
d(value?: number): number;
toXDR(format?: 'raw'): Buffer;
toXDR(format: 'hex' | 'base64'): string;
static read(io: Buffer): Price;
static write(value: Price, io: Buffer): void;
static isValid(value: Price): boolean;
static toXDR(value: Price): Buffer;
static fromXDR(input: Buffer, format?: 'raw'): Price;
static fromXDR(input: string, format: 'hex' | 'base64'): Price;
static validateXDR(input: Buffer, format?: 'raw'): boolean;
static validateXDR(input: string, format: 'hex' | 'base64'): boolean;
}
class Liabilities {
constructor(attributes: { buying: Int64; selling: Int64 });
buying(value?: Int64): Int64;
selling(value?: Int64): Int64;
toXDR(format?: 'raw'): Buffer;
toXDR(format: 'hex' | 'base64'): string;
static read(io: Buffer): Liabilities;
static write(value: Liabilities, io: Buffer): void;
static isValid(value: Liabilities): boolean;
static toXDR(value: Liabilities): Buffer;
static fromXDR(input: Buffer, format?: 'raw'): Liabilities;
static fromXDR(input: string, format: 'hex' | 'base64'): Liabilities;
static validateXDR(input: Buffer, format?: 'raw'): boolean;
static validateXDR(input: string, format: 'hex' | 'base64'): boolean;
}
class Signer {
constructor(attributes: { key: SignerKey; weight: number });
key(value?: SignerKey): SignerKey;
weight(value?: number): number;
toXDR(format?: 'raw'): Buffer;
toXDR(format: 'hex' | 'base64'): string;
static read(io: Buffer): Signer;
static write(value: Signer, io: Buffer): void;
static isValid(value: Signer): boolean;
static toXDR(value: Signer): Buffer;
static fromXDR(input: Buffer, format?: 'raw'): Signer;
static fromXDR(input: string, format: 'hex' | 'base64'): Signer;
static validateXDR(input: Buffer, format?: 'raw'): boolean;
static validateXDR(input: string, format: 'hex' | 'base64'): boolean;
}
class AccountEntryExtensionV2 {
constructor(attributes: {
numSponsored: number;
numSponsoring: number;
signerSponsoringIDs: SponsorshipDescriptor[];
ext: AccountEntryExtensionV2Ext;
});
numSponsored(value?: number): number;
numSponsoring(value?: number): number;
signerSponsoringIDs(
value?: SponsorshipDescriptor[]
): SponsorshipDescriptor[];
ext(value?: AccountEntryExtensionV2Ext): AccountEntryExtensionV2Ext;
toXDR(format?: 'raw'): Buffer;
toXDR(format: 'hex' | 'base64'): string;
static read(io: Buffer): AccountEntryExtensionV2;
static write(value: AccountEntryExtensionV2, io: Buffer): void;
static isValid(value: AccountEntryExtensionV2): boolean;
static toXDR(value: AccountEntryExtensionV2): Buffer;
static fromXDR(input: Buffer, format?: 'raw'): AccountEntryExtensionV2;
static fromXDR(
input: string,
format: 'hex' | 'base64'
): AccountEntryExtensionV2;
static validateXDR(input: Buffer, format?: 'raw'): boolean;
static validateXDR(input: string, format: 'hex' | 'base64'): boolean;
}
class AccountEntryExtensionV1 {
constructor(attributes: {
liabilities: Liabilities;
ext: AccountEntryExtensionV1Ext;
});
liabilities(value?: Liabilities): Liabilities;
ext(value?: AccountEntryExtensionV1Ext): AccountEntryExtensionV1Ext;
toXDR(format?: 'raw'): Buffer;
toXDR(format: 'hex' | 'base64'): string;
static read(io: Buffer): AccountEntryExtensionV1;
static write(value: AccountEntryExtensionV1, io: Buffer): void;
static isValid(value: AccountEntryExtensionV1): boolean;
static toXDR(value: AccountEntryExtensionV1): Buffer;
static fromXDR(input: Buffer, format?: 'raw'): AccountEntryExtensionV1;
static fromXDR(
input: string,
format: 'hex' | 'base64'
): AccountEntryExtensionV1;
static validateXDR(input: Buffer, format?: 'raw'): boolean;
static validateXDR(input: string, format: 'hex' | 'base64'): boolean;
}
class AccountEntry {
constructor(attributes: {
accountId: AccountId;
balance: Int64;
seqNum: SequenceNumber;
numSubEntries: number;
inflationDest: null | AccountId;
flags: number;
homeDomain: string | Buffer;
thresholds: Buffer;
signers: Signer[];
ext: AccountEntryExt;
});
accountId(value?: AccountId): AccountId;
balance(value?: Int64): Int64;
seqNum(value?: SequenceNumber): SequenceNumber;
numSubEntries(value?: number): number;
inflationDest(value?: null | AccountId): null | AccountId;
flags(value?: number): number;
homeDomain(value?: string | Buffer): string | Buffer;
thresholds(value?: Buffer): Buffer;
signers(value?: Signer[]): Signer[];
ext(value?: AccountEntryExt): AccountEntryExt;
toXDR(format?: 'raw'): Buffer;
toXDR(format: 'hex' | 'base64'): string;
static read(io: Buffer): AccountEntry;
static write(value: AccountEntry, io: Buffer): void;
static isValid(value: AccountEntry): boolean;
static toXDR(value: AccountEntry): Buffer;
static fromXDR(input: Buffer, format?: 'raw'): AccountEntry;
static fromXDR(input: string, format: 'hex' | 'base64'): AccountEntry;
static validateXDR(input: Buffer, format?: 'raw'): boolean;
static validateXDR(input: string, format: 'hex' | 'base64'): boolean;
}
class TrustLineEntryV1 {
constructor(attributes: {
liabilities: Liabilities;
ext: TrustLineEntryV1Ext;
});
liabilities(value?: Liabilities): Liabilities;
ext(value?: TrustLineEntryV1Ext): TrustLineEntryV1Ext;
toXDR(format?: 'raw'): Buffer;
toXDR(format: 'hex' | 'base64'): string;
static read(io: Buffer): TrustLineEntryV1;
static write(value: TrustLineEntryV1, io: Buffer): void;
static isValid(value: TrustLineEntryV1): boolean;
static toXDR(value: TrustLineEntryV1): Buffer;
static fromXDR(input: Buffer, format?: 'raw'): TrustLineEntryV1;
static fromXDR(input: string, format: 'hex' | 'base64'): TrustLineEntryV1;
static validateXDR(input: Buffer, format?: 'raw'): boolean;
static validateXDR(input: string, format: 'hex' | 'base64'): boolean;
}
class TrustLineEntry {
constructor(attributes: {
accountId: AccountId;
asset: Asset;
balance: Int64;
limit: Int64;
flags: number;
ext: TrustLineEntryExt;
});
accountId(value?: AccountId): AccountId;
asset(value?: Asset): Asset;
balance(value?: Int64): Int64;
limit(value?: Int64): Int64;
flags(value?: number): number;
ext(value?: TrustLineEntryExt): TrustLineEntryExt;
toXDR(format?: 'raw'): Buffer;
toXDR(format: 'hex' | 'base64'): string;
static read(io: Buffer): TrustLineEntry;
static write(value: TrustLineEntry, io: Buffer): void;
static isValid(value: TrustLineEntry): boolean;
static toXDR(value: TrustLineEntry): Buffer;
static fromXDR(input: Buffer, format?: 'raw'): TrustLineEntry;
static fromXDR(input: string, format: 'hex' | 'base64'): TrustLineEntry;
static validateXDR(input: Buffer, format?: 'raw'): boolean;
static validateXDR(input: string, format: 'hex' | 'base64'): boolean;
}
class OfferEntry {
constructor(attributes: {
sellerId: AccountId;
offerId: Int64;
selling: Asset;
buying: Asset;
amount: Int64;
price: Price;
flags: number;
ext: OfferEntryExt;
});
sellerId(value?: AccountId): AccountId;
offerId(value?: Int64): Int64;
selling(value?: Asset): Asset;
buying(value?: Asset): Asset;
amount(value?: Int64): Int64;
price(value?: Price): Price;
flags(value?: number): number;
ext(value?: OfferEntryExt): OfferEntryExt;
toXDR(format?: 'raw'): Buffer;
toXDR(format: 'hex' | 'base64'): string;
static read(io: Buffer): OfferEntry;
static write(value: OfferEntry, io: Buffer): void;
static isValid(value: OfferEntry): boolean;
static toXDR(value: OfferEntry): Buffer;
static fromXDR(input: Buffer, format?: 'raw'): OfferEntry;
static fromXDR(input: string, format: 'hex' | 'base64'): OfferEntry;