/// import { AmountT } from "../primitives/index"; import { PublicKeyT } from "../crypto/index"; import { UInt256 } from "@radixdlt/uint256"; import { Byte } from "../util/index"; declare type REPrimitive = Readonly<{ toBuffer: () => Buffer; toString: () => string; }>; export declare enum InstructionType { END = 0, SYSCALL = 1, UP = 2, READ = 3, LREAD = 4, VREAD = 5, LVREAD = 6, DOWN = 7, LDOWN = 8, VDOWN = 9, LVDOWN = 10, SIG = 11, MSG = 12, HEADER = 13, READINDEX = 14, DOWNINDEX = 15 } export declare type BaseInstruction = REPrimitive & Readonly<{ toHumanReadableString?: () => string; instructionType: IT; }>; export declare enum REAddressType { SYSTEM = 0, RADIX_NATIVE_TOKEN = 1, HASHED_KEY_NONCE = 3, PUBLIC_KEY = 4 } export declare type REAddressBase = REPrimitive & Readonly<{ reAddressType: AT; }>; export declare type REAddressSystem = REAddressBase; export declare type REAddressNativeToken = REAddressBase; export declare type REAddressHashedKeyNonce = REAddressBase & Readonly<{ lower26Bytes: Buffer; }>; export declare type REAddressPublicKey = REAddressBase & Readonly<{ publicKey: PublicKeyT; }>; export declare type REAddressT = REAddressSystem | REAddressNativeToken | REAddressHashedKeyNonce | REAddressPublicKey; export declare enum SubStateType { TOKENS = 6, PREPARED_STAKE = 7, STAKE_OWNERSHIP = 8, PREPARED_UNSTAKE = 9, VALIDATOR_ALLOW_DELEGATION_FLAG = 14, VALIDATOR_OWNER_COPY = 17 } export declare type BaseSubstate = REPrimitive & Readonly<{ substateType: SST; toHumanReadableString?: () => string; }>; export declare type TokensT = BaseSubstate & { reserved: Byte; owner: REAddressT; resource: REAddressT; amount: AmountT; }; export declare type BaseValidatorSubstate = BaseSubstate & Readonly<{ reserved: Byte; validator: PublicKeyT; }>; export declare type BaseStakingSubstate = BaseValidatorSubstate & Readonly<{ owner: REAddressT; amount: AmountT; }>; export declare type PreparedStakeT = BaseStakingSubstate; export declare type PreparedUnstakeT = BaseStakingSubstate; export declare type StakeOwnershipT = BaseStakingSubstate; export declare type ValidatorAllowDelegationFlagT = BaseValidatorSubstate & Readonly<{ isDelegationAllowed: boolean; }>; export declare type ValidatorOwnerCopyT = BaseValidatorSubstate & Readonly<{ owner: REAddressT; }>; export declare type SubstateT = TokensT | PreparedStakeT | PreparedUnstakeT | StakeOwnershipT | ValidatorAllowDelegationFlagT | ValidatorOwnerCopyT; export declare const stringifySubstateType: (substateType: SubStateType) => string; export declare type BaseInstructionWithSubState = BaseInstruction & Readonly<{ substate: SubstateT; }>; export declare type BytesT = REPrimitive & Readonly<{ length: number; data: Buffer; }>; export declare type Ins_END = BaseInstruction; export declare type Ins_UP = BaseInstructionWithSubState; export declare type Ins_MSG = BaseInstruction & Readonly<{ bytes: BytesT; }>; export declare type UInt32 = number; export declare type SubstateIdT = REPrimitive & Readonly<{ hash: Buffer; index: UInt32; }>; export declare type Ins_DOWN = BaseInstruction & Readonly<{ substateId: SubstateIdT; }>; export declare type Ins_LDOWN = BaseInstruction & Readonly<{ substateIndex: UInt32; }>; export declare type TXSig = REPrimitive & Readonly<{ v: Byte; r: UInt256; s: UInt256; }>; export declare type Ins_SIG = BaseInstruction & Readonly<{ signature: TXSig; }>; export declare const SYSCALL_TX_FEE_RESERVE_PUT = 0; export declare const SYSCALL_TX_FEE_RESERVE_TAKE = 1; export declare type Ins_SYSCALL = BaseInstruction & Readonly<{ callData: BytesT; }>; export declare type Ins_HEADER = BaseInstruction & Readonly<{ version: Byte; flag: Byte; }>; export declare type Ins_VREAD = BaseInstruction & Readonly<{ callData: BytesT; }>; export declare type Ins_VDOWN = BaseInstruction & Readonly<{ callData: BytesT; }>; export declare type Ins_READ = BaseInstruction & Readonly<{ substateId: SubstateIdT; }>; export declare type InstructionT = Ins_END | Ins_UP | Ins_DOWN | Ins_LDOWN | Ins_MSG | Ins_SIG | Ins_SYSCALL | Ins_HEADER | Ins_VREAD | Ins_VDOWN | Ins_READ; export declare type TransactionT = REPrimitive & Readonly<{ instructions: InstructionT[]; txID: () => string; }>; export {}; //# sourceMappingURL=_types.d.ts.map