Documentation
¶
Index ¶
- Variables
- type AccStatusChange
- type Account
- type AccountBlock
- type AccountID
- func AccountIDFromBase64Url(s string) (*AccountID, error)
- func AccountIDFromCell(cell *boc.Cell) (*AccountID, error)
- func AccountIDFromRaw(s string) (*AccountID, error)
- func MustParseAccountID(s string) *AccountID
- func NewAccountId(id int32, addr [32]byte) *AccountID
- func ParseAccountID(s string) (*AccountID, error)
- func (id AccountID) IsZero() bool
- func (id AccountID) MarshalJSON() ([]byte, error)
- func (id AccountID) MarshalTL() ([]byte, error)
- func (id AccountID) MarshalTLB(c *boc.Cell, tag string) error
- func (id AccountID) String() string
- func (id AccountID) ToHuman(bounce, testnet bool) string
- func (id AccountID) ToRaw() string
- func (id *AccountID) UnmarshalJSON(data []byte) error
- func (id *AccountID) UnmarshalTL(r io.Reader) error
- type AccountInfo
- type AccountState
- type AccountStatus
- type AccountStorage
- type AllShardsInfo
- type Anycast
- type BlkMasterInfo
- type BlkPrevInfo
- type Block
- type BlockCreateStats
- type BlockExtra
- type BlockHeader
- type BlockIdExt
- type BlockInfo
- type BlockInfoPart
- type BlockProof
- type BlockSignatures
- type BlockSignaturesPure
- type Certificate
- type ChunkedData
- type CommonMsgInfo
- type ComputeSkipReason
- type ConfigHashMap
- type ConfigParams
- type ContentData
- type Counters
- type CreatorStats
- type CryptoSignature
- type CryptoSignaturePair
- type CryptoSignatureSimple
- type CryptoSignatureSimpleData
- type CurrencyCollection
- type DNSRecord
- type DNSRecordSet
- type DNSText
- type DepthBalanceInfo
- type EnqueuedMsg
- type ExtBlkRef
- type ExtraCurrencyCollection
- type FullContent
- type GlobalVersion
- type Grams
- type Hash
- func (h Hash) Base64() string
- func (h *Hash) FromBase64(s string) error
- func (h *Hash) FromBase64URL(s string) error
- func (h *Hash) FromBytes(b []byte) error
- func (h *Hash) FromHex(s string) error
- func (h *Hash) FromUnknownString(s string) error
- func (h Hash) Hex() string
- func (h Hash) MarshalJSON() ([]byte, error)
- func (h Hash) MarshalTL() ([]byte, error)
- func (h Hash) MarshalTLB(c *boc.Cell, tag string) error
- func (h *Hash) Scan(src interface{}) error
- func (h *Hash) UnmarshalTL(r io.Reader) error
- func (h *Hash) UnmarshalTLB(c *boc.Cell, tag string) error
- func (h Hash) Value() (driver.Value, error)
- type HashUpdate
- type IhrPendingInfo
- type IhrPendingSince
- type ImportFees
- type InMsg
- type InMsgDescr
- type Int257
- type IntermediateAddress
- type JettonMetadata
- type KeyExtBlkRef
- type KeyMaxLt
- type LibDescr
- type McBlockExtra
- type McStateExtra
- type McStateExtraOther
- type MerkleProof
- type Message
- type MsgAddress
- type MsgEnvelope
- type OldMcBlocksInfo
- type OutMsg
- type OutMsgDescr
- type OutMsgQueue
- type OutMsgQueueInfo
- type ProcessedInfo
- type ProcessedUpto
- type RawBlock
- type ShardAccount
- type ShardAccountBlocks
- type ShardAccounts
- type ShardDesc
- type ShardFeeCreated
- type ShardFees
- type ShardHashes
- type ShardID
- type ShardIdent
- type ShardInfoBinTree
- type ShardState
- type ShardStateUnsplit
- type ShardStateUnsplitData
- type ShardStateUnsplitOther
- type SigPubKey
- type SignedSertificate
- type SimpleLib
- type SmcCapabilities
- type SnakeData
- type SplitMergeInfo
- type StateInit
- type StorageInfo
- type StorageUsed
- type StorageUsedShort
- type Text
- type TickTock
- type TonNodeBlockId
- type TonNodeBlockIdExt
- type TrActionPhase
- type TrBouncePhase
- type TrComputePhase
- type TrCreditPhase
- type TrStoragePhase
- type Transaction
- type TransactionDescr
- type ValidatorBaseInfo
- type ValidatorDescr
- type ValidatorInfo
- type ValidatorsSet
- type ValueFlow
- type VmCellSlice
- type VmCont
- type VmStack
- type VmStackValue
- func (v VmStackValue) Cell() *boc.Celldeprecated
- func (v VmStackValue) CellSlice() *boc.Celldeprecated
- func (v VmStackValue) Int() big.Intdeprecated
- func (v VmStackValue) Int64() int64deprecated
- func (v VmStackValue) IsCell() booldeprecated
- func (v VmStackValue) IsCellSlice() booldeprecated
- func (v VmStackValue) IsInt() booldeprecated
- func (v VmStackValue) IsNull() booldeprecated
- func (v VmStackValue) IsTuple() booldeprecated
- func (v VmStackValue) Tuple() []VmStackValuedeprecated
- func (v VmStackValue) Uint64() uint64deprecated
- type VmStkTuple
- type VmTuple
- type VmTupleRef
Constants ¶
This section is empty.
Variables ¶
var BlockchainInterfaceIsNil = errors.New("blockchain interface is nil")
var ErrEntityNotFound = errors.New("entity not found")
Functions ¶
This section is empty.
Types ¶
type AccStatusChange ¶
type AccStatusChange string
AccStatusChange acst_unchanged$0 = AccStatusChange; // x -> x acst_frozen$10 = AccStatusChange; // init -> frozen acst_deleted$11 = AccStatusChange; // frozen -> deleted
const ( AccStatusChangeUnchanged AccStatusChange = "acst_unchanged" AccStatusChangeFrozen AccStatusChange = "acst_frozen" AccStatusChangeDeleted AccStatusChange = "acst_deleted" )
func (AccStatusChange) MarshalTLB ¶
func (a AccStatusChange) MarshalTLB(c *boc.Cell, tag string) error
func (*AccStatusChange) UnmarshalTLB ¶
func (a *AccStatusChange) UnmarshalTLB(c *boc.Cell, tag string) error
type Account ¶
type Account struct {
tlb.SumType
AccountNone struct {
} `tlbSumType:"account_none$0"`
Account struct {
Addr MsgAddress
StorageStat StorageInfo
Storage AccountStorage
} `tlbSumType:"account$1"`
}
Account account_none$0 = Account; account$1 addr:MsgAddressInt storage_stat:StorageInfo storage:AccountStorage = Account;
type AccountBlock ¶
type AccountBlock struct {
Magic tlb.Magic `tlb:"acc_trans#5"`
AccountAddr Hash
Transactions tlb.HashmapAug[tlb.Ref[Transaction], CurrencyCollection] `tlb:"64bits"`
StateUpdate HashUpdate `tlb:"^"`
}
acc_trans#5 account_addr:bits256
transactions:(HashmapAug 64 ^Transaction CurrencyCollection) state_update:^(HASH_UPDATE Account) = AccountBlock;
type AccountID ¶
func AccountIDFromBase64Url ¶
func AccountIDFromRaw ¶
func MustParseAccountID ¶
func NewAccountId ¶
func ParseAccountID ¶
func (AccountID) MarshalJSON ¶
func (*AccountID) UnmarshalJSON ¶
type AccountInfo ¶
type AccountState ¶
type AccountState struct {
tlb.SumType
AccountUninit struct {
} `tlbSumType:"account_uninit$00"`
AccountActive struct {
StateInit StateInit
} `tlbSumType:"account_active$1"`
AccountFrozen struct {
StateHash Hash
} `tlbSumType:"account_frozen$01"`
}
AccountState account_uninit$00 = AccountState; account_active$1 _:StateInit = AccountState; account_frozen$01 state_hash:bits256 = AccountState;
type AccountStatus ¶
type AccountStatus string
AccountStatus acc_state_uninit$00 = AccountStatus; acc_state_frozen$01 = AccountStatus; acc_state_active$10 = AccountStatus; acc_state_nonexist$11 = AccountStatus;
const ( AccountEmpty AccountStatus = "empty" // empty state from node AccountNone AccountStatus = "nonexist" AccountUninit AccountStatus = "uninit" AccountActive AccountStatus = "active" AccountFrozen AccountStatus = "frozen" )
func (AccountStatus) MarshalTLB ¶
func (a AccountStatus) MarshalTLB(c *boc.Cell, tag string) error
func (*AccountStatus) UnmarshalTLB ¶
func (a *AccountStatus) UnmarshalTLB(c *boc.Cell, tag string) error
type AccountStorage ¶
type AccountStorage struct {
LastTransLt uint64
Balance CurrencyCollection
State AccountState
}
AccountStorage account_storage$_ last_trans_lt:uint64 balance:CurrencyCollection state:AccountState = AccountStorage;
type AllShardsInfo ¶
type AllShardsInfo struct {
ShardHashes tlb.HashmapE[tlb.Ref[ShardInfoBinTree]] `tlb:"32bits"`
}
type Anycast ¶
Anycast anycast_info$_ depth:(#<= 30) { depth >= 1 } rewrite_pfx:(bits depth) = Anycast;
type BlkMasterInfo ¶
type BlkMasterInfo struct {
Master ExtBlkRef
}
BlkMasterInfo master_info$_ master:ExtBlkRef = BlkMasterInfo; ext_blk_ref$_ end_lt:uint64 seq_no:uint32 root_hash:bits256 file_hash:bits256 = ExtBlkRef;
type BlkPrevInfo ¶
type BlkPrevInfo struct {
tlb.SumType
PrevBlkInfo struct {
Prev ExtBlkRef
} `tlbSumType:"prev_blk_info$_"`
PrevBlksInfo struct {
Prev1 ExtBlkRef // ^ but decodes manually
Prev2 ExtBlkRef // ^ but decodes manually
} `tlbSumType:"prev_blks_info$_"`
}
BlkPrevInfo prev_blk_info$_ prev:ExtBlkRef = BlkPrevInfo 0; prev_blks_info$_ prev1:^ExtBlkRef prev2:^ExtBlkRef = BlkPrevInfo 1;
func (*BlkPrevInfo) UnmarshalTLB ¶
func (i *BlkPrevInfo) UnmarshalTLB(c *boc.Cell, isBlks bool) error
type Block ¶
type Block struct {
Magic tlb.Magic `tlb:"block#11ef55aa"`
GlobalId int32
Info BlockInfo `tlb:"^"`
ValueFlow tlb.Any `tlb:"^"` // ValueFlow
StateUpdate tlb.Any `tlb:"^"` //MerkleUpdate[ShardState] `tlb:"^"` //
Extra BlockExtra `tlb:"^"`
}
Block block#11ef55aa global_id:int32 info:^BlockInfo value_flow:^ValueFlow state_update:^(MERKLE_UPDATE ShardState) extra:^BlockExtra = Block;
func (*Block) ShardIDs ¶
func (blk *Block) ShardIDs() ([]TonNodeBlockIdExt, error)
ShardIDs returns a list of IDs of shard blocks this block refers to.
type BlockCreateStats ¶
type BlockCreateStats struct {
tlb.SumType
BlockCreateStats struct {
Counters tlb.HashmapE[CreatorStats] `tlb:"256bits"`
} `tlbSumType:"block_create_stats#17"`
BlockCreateStatsExt struct {
Counters tlb.HashmapAugE[CreatorStats, uint32] `tlb:"256bits"`
} `tlbSumType:"block_create_stats_ext#34"`
}
block_create_stats#17 counters:(HashmapE 256 CreatorStats) = BlockCreateStats; block_create_stats_ext#34 counters:(HashmapAugE 256 CreatorStats uint32) = BlockCreateStats;
type BlockExtra ¶
type BlockExtra struct {
Magic tlb.Magic `tlb:"block_extra#4a33f6fd"`
InMsgDescr InMsgDescr `tlb:"^"` // tlb.Any `tlb:"^"`
OutMsgDescr OutMsgDescr `tlb:"^"` // tlb.Any `tlb:"^"`
AccountBlocks ShardAccountBlocks `tlb:"^"` // tlb.Any `tlb:"^"` //
RandSeed Hash
CreatedBy Hash
Custom tlb.Maybe[tlb.Ref[McBlockExtra]]
}
BlockExtra block_extra in_msg_descr:^InMsgDescr out_msg_descr:^OutMsgDescr account_blocks:^ShardAccountBlocks rand_seed:bits256 created_by:bits256 custom:(Maybe ^McBlockExtra) = BlockExtra;
type BlockHeader ¶
type BlockHeader struct {
Magic tlb.Magic `tlb:"block#11ef55aa"`
GlobalId int32
Info BlockInfo `tlb:"^"`
}
TODO: clarify the description of the structure
type BlockIdExt ¶
type BlockIdExt struct {
ShardId ShardIdent
SeqNo uint32
RootHash Hash
FileHash Hash
}
block_id_ext$_ shard_id:ShardIdent seq_no:uint32 root_hash:bits256 file_hash:bits256 = BlockIdExt;
type BlockInfo ¶
type BlockInfo struct {
BlockInfoPart
GenSoftware *GlobalVersion
MasterRef *BlkMasterInfo
PrevRef BlkPrevInfo
PrevVertRef *BlkPrevInfo
}
BlockInfo block_info#9bc7a987 version:uint32 not_master:(## 1) after_merge:(## 1) before_split:(## 1) after_split:(## 1) want_split:Bool want_merge:Bool key_block:Bool vert_seqno_incr:(## 1) flags:(## 8) { flags <= 1 } seq_no:# vert_seq_no:# { vert_seq_no >= vert_seqno_incr } { prev_seq_no:# } { ~prev_seq_no + 1 = seq_no } shard:ShardIdent gen_utime:uint32 start_lt:uint64 end_lt:uint64 gen_validator_list_hash_short:uint32 gen_catchain_seqno:uint32 min_ref_mc_seqno:uint32 prev_key_block_seqno:uint32 gen_software:flags . 0?GlobalVersion master_ref:not_master?^BlkMasterInfo prev_ref:^(BlkPrevInfo after_merge) prev_vert_ref:vert_seqno_incr?^(BlkPrevInfo 0) = BlockInfo;
func (*BlockInfo) GetParents ¶
func (i *BlockInfo) GetParents() ([]TonNodeBlockIdExt, error)
type BlockInfoPart ¶
type BlockInfoPart struct {
Version uint32
NotMaster bool
AfterMerge bool
BeforeSplit bool
AfterSplit bool
WantSplit bool
WantMerge bool
KeyBlock bool
VertSeqnoIncr bool
Flags uint32 `tlb:"8bits"`
SeqNo uint32
VertSeqNo uint32
Shard ShardIdent
GenUtime uint32
StartLt uint64
EndLt uint64
GenValidatorListHashShort uint32
GenCatchainSeqno uint32
MinRefMcSeqno uint32
PrevKeyBlockSeqno uint32
}
type BlockProof ¶
type BlockProof struct {
Magic tlb.Magic `tlb:"block_proof#c3"`
ProofFor BlockIdExt
Root boc.Cell `tlb:"^"`
Signatures tlb.Maybe[tlb.Ref[BlockSignatures]]
}
block_proof#c3 proof_for:BlockIdExt root:^Cell signatures:(Maybe ^BlockSignatures) = BlockProof;
type BlockSignatures ¶
type BlockSignatures struct {
Magic tlb.Magic `tlb:"block_signatures#11"`
ValidatorInfo ValidatorBaseInfo
PureSignatures BlockSignaturesPure
}
block_signatures#11 validator_info:ValidatorBaseInfo pure_signatures:BlockSignaturesPure = BlockSignatures;
type BlockSignaturesPure ¶
type BlockSignaturesPure struct {
SigCount uint32
SigWeight uint64
Signatures tlb.HashmapE[CryptoSignaturePair] `tlb:"16bits"`
}
type Certificate ¶
type Certificate struct {
Magic tlb.Magic `tlb:"certificate#4"`
TempKey SigPubKey
ValidSince uint32
ValidUntil uint32
}
certificate#4 temp_key:SigPubKey valid_since:uint32 valid_until:uint32 = Certificate; // 356 bits
type ChunkedData ¶
ChunkedData chunked_data#_ data:(HashMapE 32 ^(SnakeData ~0)) = ChunkedData;
func (ChunkedData) MarshalTLB ¶
func (d ChunkedData) MarshalTLB(c *boc.Cell, tag string) error
func (*ChunkedData) UnmarshalTLB ¶
func (d *ChunkedData) UnmarshalTLB(c *boc.Cell, tag string) error
type CommonMsgInfo ¶
type CommonMsgInfo struct {
tlb.SumType
IntMsgInfo struct {
IhrDisabled bool
Bounce bool
Bounced bool
Src MsgAddress
Dest MsgAddress
Value CurrencyCollection
IhrFee Grams
FwdFee Grams
CreatedLt uint64
CreatedAt uint32
} `tlbSumType:"int_msg_info$0"`
ExtInMsgInfo struct {
Src MsgAddress
Dest MsgAddress
ImportFee Grams
} `tlbSumType:"ext_in_msg_info$10"`
ExtOutMsgInfo struct {
Src MsgAddress
Dest MsgAddress
CreatedLt uint64
CreatedAt uint32
} `tlbSumType:"ext_out_msg_info$11"`
}
CommonMsgInfo int_msg_info$0 ihr_disabled:Bool bounce:Bool bounced:Bool src:MsgAddressInt dest:MsgAddressInt value:CurrencyCollection ihr_fee:Grams fwd_fee:Grams created_lt:uint64 created_at:uint32 = CommonMsgInfo; ext_in_msg_info$10 src:MsgAddressExt dest:MsgAddressInt import_fee:Grams = CommonMsgInfo; ext_out_msg_info$11 src:MsgAddressInt dest:MsgAddressExt created_lt:uint64 created_at:uint32 = CommonMsgInfo;
type ComputeSkipReason ¶
type ComputeSkipReason string
ComputeSkipReason cskip_no_state$00 = ComputeSkipReason; cskip_bad_state$01 = ComputeSkipReason; cskip_no_gas$10 = ComputeSkipReason;
const ( ComputeSkipReasonNoState ComputeSkipReason = "cskip_no_state" ComputeSkipReasonBadState ComputeSkipReason = "cskip_bad_state" ComputeSkipReasonNoGas ComputeSkipReason = "cskip_no_gas" )
func (ComputeSkipReason) MarshalTLB ¶
func (a ComputeSkipReason) MarshalTLB(c *boc.Cell, tag string) error
func (*ComputeSkipReason) UnmarshalTLB ¶
func (a *ComputeSkipReason) UnmarshalTLB(c *boc.Cell, tag string) error
type ConfigHashMap ¶
type ConfigParams ¶
type ConfigParams struct {
ConfigAddr Hash
Config ConfigHashMap `tlb:"^"`
}
ConfigParams _ config_addr:bits256 config:^(Hashmap 32 ^Cell) = ConfigParams;
type ContentData ¶
type ContentData struct {
tlb.SumType
Snake struct {
Data SnakeData
} `tlbSumType:"snake#00"`
Chunks struct {
Data ChunkedData
} `tlbSumType:"chunks#01"`
}
ContentData snake#00 data:(SnakeData ~n) = ContentData; chunks#01 data:ChunkedData = ContentData;
func (ContentData) Bytes ¶
func (c ContentData) Bytes() ([]byte, error)
type CreatorStats ¶
type CreatorStats struct {
Magic tlb.Magic `tlb:"creator_info#4"`
McBlocks Counters
ShardBlocks Counters
}
creator_info#4 mc_blocks:Counters shard_blocks:Counters = CreatorStats;
type CryptoSignature ¶
type CryptoSignature struct {
tlb.SumType
CryptoSignatureSimple CryptoSignatureSimpleData `tlbSumType:"ed25519_signature#5"`
CryptoSignature struct {
SignedCert *SignedSertificate `tlb:"^"`
TempKeySignature CryptoSignatureSimple
} `tlbSumType:"chained_signature#f"`
}
func (*CryptoSignature) UnmarshalTLB ¶
func (cr *CryptoSignature) UnmarshalTLB(c *boc.Cell, tag string) error
type CryptoSignaturePair ¶
type CryptoSignaturePair struct {
NodeIdShort Hash
Sign CryptoSignature
}
sig_pair$_ node_id_short:bits256 sign:CryptoSignature = CryptoSignaturePair; // 256+x ~ 772 bits
type CryptoSignatureSimple ¶
type CryptoSignatureSimple struct {
Magic tlb.Magic `tlb:"ed25519_signature#5"`
CryptoSignatureSimple CryptoSignatureSimpleData
}
ed25519_signature#5 R:bits256 s:bits256 = CryptoSignatureSimple; // 516 bits _ CryptoSignatureSimple = CryptoSignature; chained_signature#f signed_cert:^SignedCertificate temp_key_signature:CryptoSignatureSimple
= CryptoSignature; // 4+(356+516)+516 = 520 bits+ref (1392 bits total)
type CurrencyCollection ¶
type CurrencyCollection struct {
Grams Grams
Other ExtraCurrencyCollection
}
CurrencyCollection currencies$_ grams:Grams other:ExtraCurrencyCollection = CurrencyCollection;
type DNSRecord ¶
type DNSRecord struct {
tlb.SumType
DNSText DNSText `tlbSumType:"dns_text#1eda"`
DNSNextResolver AccountID `tlbSumType:"dns_next_resolver#ba93"`
DNSAdnlAddress struct {
Address [32]byte
ProtoList []string
} `tlbSumType:"dns_adnl_address#ad01"`
DNSSmcAddress struct {
Address AccountID
SmcCapability SmcCapabilities
} `tlbSumType:"dns_smc_address#9fd3"`
DNSStorageAddress Hash `tlbSumType:"dns_storage_address#7473"`
NotStandard *boc.Cell // only for custom unmarshaling
}
DNSRecord dns_text#1eda _:Text = DNSRecord; dns_next_resolver#ba93 resolver:MsgAddressInt = DNSRecord; // usually in record #-1 dns_adnl_address#ad01 adnl_addr:bits256 flags:(## 8) { flags <= 1 } proto_list:flags . 0?ProtoList = DNSRecord; // often in record #2 dns_smc_address#9fd3 smc_addr:MsgAddressInt flags:(## 8) { flags <= 1 } cap_list:flags . 0?SmcCapList = DNSRecord; // often in record #1 dns_storage_address#7473 bag_id:bits256 = DNSRecord;
type DNSRecordSet ¶
DNSRecordSet _ (HashmapE 256 DNSRecord) = DNS_RecordSet;
type DepthBalanceInfo ¶
type DepthBalanceInfo struct {
SplitDepth uint32 `tlb:"5bits"`
Balance CurrencyCollection
}
depth_balance$_ split_depth:(#<= 30) balance:CurrencyCollection = DepthBalanceInfo;
type EnqueuedMsg ¶
type EnqueuedMsg struct {
EnqueuedLt uint64
OutMsg MsgEnvelope `tlb:"^"`
}
_ enqueued_lt:uint64 out_msg:^MsgEnvelope = EnqueuedMsg;
type ExtBlkRef ¶
ExtBlkRef ext_blk_ref$_ end_lt:uint64 seq_no:uint32 root_hash:bits256 file_hash:bits256 = ExtBlkRef;
type ExtraCurrencyCollection ¶
type ExtraCurrencyCollection struct {
Dict tlb.HashmapE[struct {
Val tlb.VarUInteger `tlb:"32bytes"`
}] `tlb:"32bits"`
}
ExtraCurrencyCollection extra_currencies$_ dict:(HashmapE 32 (VarUInteger 32)) = ExtraCurrencyCollection;
type FullContent ¶
type FullContent struct {
tlb.SumType
Onchain struct {
Data tlb.HashmapE[tlb.Ref[ContentData]] `tlb:"256bits"`
} `tlbSumType:"onchain#00"`
Offchain struct {
Uri SnakeData // Text
} `tlbSumType:"offchain#01"`
}
FullContent onchain#00 data:(HashMapE 256 ^ContentData) = FullContent; offchain#01 uri:Text = FullContent; text#_ {n:#} data:(SnakeData ~n) = Text;
type GlobalVersion ¶
type GlobalVersion struct {
Magic tlb.Magic `tlb:"capabilities#c4"`
Version uint32
Capabilities uint64
}
GlobalVersion capabilities#c4 version:uint32 capabilities:uint64 = GlobalVersion;
type Grams ¶
type Grams uint64 // total value fit to uint64
Grams nanograms$_ amount:(VarUInteger 16) = Grams;
const OneTON Grams = 1_000_000_000
func (Grams) MarshalJSON ¶
func (*Grams) UnmarshalJSON ¶
type Hash ¶
type Hash [32]byte
func MustParseHash ¶
func (*Hash) FromBase64 ¶
func (*Hash) FromBase64URL ¶
func (*Hash) FromUnknownString ¶
func (Hash) MarshalJSON ¶
type HashUpdate ¶
HashUpdate update_hashes#72 {X:Type} old_hash:bits256 new_hash:bits256 = HASH_UPDATE X;
type IhrPendingInfo ¶
type IhrPendingInfo struct {
IhrPendingInfo tlb.HashmapE[IhrPendingSince] `tlb:"320bits"`
}
_ (HashmapE 320 IhrPendingSince) = IhrPendingInfo;
type IhrPendingSince ¶
type IhrPendingSince struct {
ImportLt uint64
}
ihr_pending$_ import_lt:uint64 = IhrPendingSince;
type ImportFees ¶
type ImportFees struct {
FeesCollected Grams
ValueImported CurrencyCollection
}
import_fees$_ fees_collected:Grams
value_imported:CurrencyCollection = ImportFees;
type InMsg ¶
type InMsg struct {
tlb.SumType
MsgImportExt struct {
Msg Message `tlb:"^"`
Transaction Transaction `tlb:"^"`
} `tlbSumType:"msg_import_ext$000"`
MsgImportIhr struct {
Msg Message `tlb:"^"`
Transaction Transaction `tlb:"^"`
IhrFee Grams
ProofCreated boc.Cell `tlb:"^"`
} `tlbSumType:"msg_import_ihr$010"`
MsgImportImm struct {
InMsg MsgEnvelope `tlb:"^"`
Transaction Transaction `tlb:"^"`
FwdFee Grams
} `tlbSumType:"msg_import_imm$011"`
MsgImportFin struct {
InMsg MsgEnvelope `tlb:"^"`
Transaction Transaction `tlb:"^"`
FwdFee Grams
} `tlbSumType:"msg_import_fin$100"`
MsgImportTr struct {
InMsg MsgEnvelope `tlb:"^"`
OutMsg MsgEnvelope `tlb:"^"`
TransitFee Grams
} `tlbSumType:"msg_import_tr$101"`
MsgDiscardFin struct {
InMsg MsgEnvelope `tlb:"^"`
TransactionId uint64
FwdFee Grams
} `tlbSumType:"msg_discard_fin$110"`
MsgDiscardTr struct {
InMsg MsgEnvelope `tlb:"^"`
TransactionId uint64
FwdFee Grams
ProofDelivered boc.Cell `tlb:"^"`
} `tlbSumType:"msg_discard_tr$111"`
}
msg_import_ext$000 msg:^(Message Any) transaction:^Transaction
= InMsg;
msg_import_ihr$010 msg:^(Message Any) transaction:^Transaction
ihr_fee:Grams proof_created:^Cell = InMsg;
msg_import_imm$011 in_msg:^MsgEnvelope
transaction:^Transaction fwd_fee:Grams = InMsg;
msg_import_fin$100 in_msg:^MsgEnvelope
transaction:^Transaction fwd_fee:Grams = InMsg;
msg_import_tr$101 in_msg:^MsgEnvelope out_msg:^MsgEnvelope
transit_fee:Grams = InMsg;
msg_discard_fin$110 in_msg:^MsgEnvelope transaction_id:uint64
fwd_fee:Grams = InMsg;
msg_discard_tr$111 in_msg:^MsgEnvelope transaction_id:uint64
fwd_fee:Grams proof_delivered:^Cell = InMsg;
type InMsgDescr ¶
type InMsgDescr struct {
Hashmap tlb.HashmapAugE[InMsg, ImportFees] `tlb:"256bits"`
}
_ (HashmapAugE 256 InMsg ImportFees) = InMsgDescr;
type IntermediateAddress ¶
type IntermediateAddress struct {
tlb.SumType
IntermediateAddressRegular struct {
UseDestBits boc.BitString `tlb:"7bits"`
} `tlbSumType:"interm_addr_regular$0"`
IntermediateAddressSimple struct {
WorkchainId int32 `tlb:"8bits"`
AddressPrefix uint64
} `tlbSumType:"interm_addr_simple$10"`
IntermediateAddressExt struct {
WorkchainId int32
AddressPrefix uint64
} `tlbSumType:"interm_addr_ext$11"`
}
interm_addr_regular$0 use_dest_bits:(#<= 96) = IntermediateAddress; interm_addr_simple$10 workchain_id:int8 addr_pfx:uint64 = IntermediateAddress; interm_addr_ext$11 workchain_id:int32 addr_pfx:uint64 = IntermediateAddress;
type JettonMetadata ¶
type JettonMetadata struct {
Uri string `json:"uri,omitempty"`
Name string `json:"name,omitempty"`
Description string `json:"description,omitempty"`
Image string `json:"image,omitempty"`
ImageData []byte `json:"image_data,omitempty"`
Symbol string `json:"symbol,omitempty"`
Decimals string `json:"decimals,omitempty"`
}
type KeyExtBlkRef ¶
_ key:Bool blk_ref:ExtBlkRef = KeyExtBlkRef;
type LibDescr ¶
type LibDescr struct {
Magic tlb.Magic `tlb:"shared_lib_descr$00"`
Lib boc.Cell `tlb:"^"`
Publishers tlb.Hashmap[bool] `tlb:"256bits"`
}
shared_lib_descr$00 lib:^Cell publishers:(Hashmap 256 True)
= LibDescr;
type McBlockExtra ¶
type McBlockExtra struct {
Magic tlb.Magic `tlb:"masterchain_block_extra#cca5"`
KeyBlock bool
ShardHashes ShardHashes
ShardFees ShardFees
McExtraOther struct {
PrevBlkSignatures tlb.HashmapE[CryptoSignaturePair] `tlb:"16bits"`
RecoverCreate tlb.Maybe[tlb.Ref[InMsg]]
MintMsg tlb.Maybe[tlb.Ref[InMsg]]
} `tlb:"^"`
Config ConfigParams
}
masterchain_block_extra#cca5
key_block:(## 1) shard_hashes:ShardHashes shard_fees:ShardFees ^[ prev_blk_signatures:(HashmapE 16 CryptoSignaturePair) recover_create_msg:(Maybe ^InMsg) mint_msg:(Maybe ^InMsg) ] config:key_block?ConfigParams
= McBlockExtra;
func (*McBlockExtra) UnmarshalTLB ¶
func (m *McBlockExtra) UnmarshalTLB(c *boc.Cell, tag string) error
type McStateExtra ¶
type McStateExtra struct {
Magic tlb.Magic `tlb:"masterchain_state_extra#cc26"`
ShardHashes ShardHashes
Config ConfigParams
Other McStateExtraOther `tlb:"^"`
GlobalBalance CurrencyCollection
}
McStateExtra masterchain_state_extra#cc26 shard_hashes:ShardHashes config:ConfigParams ^[ flags:(## 16) { flags <= 1 } validator_info:ValidatorInfo prev_blocks:OldMcBlocksInfo after_key_block:Bool last_key_block:(Maybe ExtBlkRef) block_create_stats:(flags . 0)?BlockCreateStats ] global_balance:CurrencyCollection = McStateExtra;
type McStateExtraOther ¶
type McStateExtraOther struct {
Flags uint32 `tlb:"16bits"`
ValidatorInfo ValidatorInfo
PrevBlocks OldMcBlocksInfo
AfterKeyBlock bool
LastKeyBlock tlb.Maybe[ExtBlkRef]
BlockCreateStats BlockCreateStats
}
^[ flags:(## 16) { flags <= 1 } validator_info:ValidatorInfo prev_blocks:OldMcBlocksInfo after_key_block:Bool last_key_block:(Maybe ExtBlkRef) block_create_stats:(flags . 0)?BlockCreateStats ]
func (*McStateExtraOther) UnmarshalTLB ¶
func (m *McStateExtraOther) UnmarshalTLB(c *boc.Cell, tag string) error
type MerkleProof ¶
type MerkleProof[T any] struct { Magic tlb.Magic `tlb:"!merkle_proof#03"` VirtualHash Hash Depth boc.BitString `tlb:"16bits"` VirtualRoot T `tlb:"^"` }
MerkleProof !merkle_proof#03 {X:Type} virtual_hash:bits256 depth:uint16 virtual_root:^X = MERKLE_PROOF X;
type Message ¶
type Message struct {
Info CommonMsgInfo
Init tlb.Maybe[tlb.EitherRef[StateInit]]
Body tlb.EitherRef[tlb.Any]
}
Message message$_ {X:Type} info:CommonMsgInfo init:(Maybe (Either StateInit ^StateInit)) body:(Either X ^X) = Message X;
type MsgAddress ¶
type MsgAddress struct {
tlb.SumType
AddrNone struct {
} `tlbSumType:"addr_none$00"`
AddrExtern struct {
Len uint32 `tlb:"9bits"`
ExternalAddress boc.BitString
} `tlbSumType:"addr_extern$01"`
AddrStd struct {
Anycast tlb.Maybe[Anycast]
WorkchainId int32 `tlb:"8bits"`
Address Hash
} `tlbSumType:"addr_std$10"`
AddrVar struct {
Anycast tlb.Maybe[Anycast]
AddrLen uint32 `tlb:"9bits"`
WorkchainId int32
Address boc.BitString
} `tlbSumType:"addr_var$11"`
}
MsgAddress addr_none$00 = MsgAddressExt; addr_extern$01 len:(## 9) external_address:(bits len) = MsgAddressExt; addr_std$10 anycast:(Maybe Anycast) workchain_id:int8 address:bits256 = MsgAddressInt; addr_var$11 anycast:(Maybe Anycast) addr_len:(## 9) workchain_id:int32 address:(bits addr_len) = MsgAddressInt; _ _:MsgAddressInt = MsgAddress; _ _:MsgAddressExt = MsgAddress;
func MsgAddressFromAccountID ¶
func MsgAddressFromAccountID(id *AccountID) MsgAddress
func (MsgAddress) AccountID ¶
func (a MsgAddress) AccountID() (*AccountID, error)
func (*MsgAddress) UnmarshalTLB ¶
func (a *MsgAddress) UnmarshalTLB(c *boc.Cell, tag string) error
type MsgEnvelope ¶
type MsgEnvelope struct {
Magic tlb.Magic `tlb:"msg_envelope#4"`
CurrentAddress IntermediateAddress
NextAddress IntermediateAddress
FwdFeeRemaining Grams
Msg Message `tlb:"^"`
}
msg_envelope#4 cur_addr:IntermediateAddress next_addr:IntermediateAddress fwd_fee_remaining:Grams msg:^(Message Any) = MsgEnvelope;
type OldMcBlocksInfo ¶
type OldMcBlocksInfo struct {
Info tlb.HashmapAugE[KeyExtBlkRef, KeyMaxLt] `tlb:"32bits"`
}
_ (HashmapAugE 32 KeyExtBlkRef KeyMaxLt) = OldMcBlocksInfo
type OutMsg ¶
type OutMsg struct {
tlb.SumType
MsgExportExt struct {
Msg Message `tlb:"^"`
Transaction Transaction `tlb:"^"`
} `tlbSumType:"msg_export_ext$000"`
MsgExportImm struct {
OutMsg MsgEnvelope `tlb:"^"`
Transaction Transaction `tlb:"^"`
Reimport InMsg `tlb:"^"`
} `tlbSumType:"msg_export_imm$010"`
MsgExportNew struct {
OutMsg MsgEnvelope `tlb:"^"`
Transaction Transaction `tlb:"^"`
} `tlbSumType:"msg_export_new$001"`
MsgExportTr struct {
OutMsg MsgEnvelope `tlb:"^"`
Imported InMsg `tlb:"^"`
} `tlbSumType:"msg_export_tr$011"`
MsgExportDeq struct {
OutMsg MsgEnvelope `tlb:"^"`
ImportBlock boc.BitString `tlb:"63bits"`
} `tlbSumType:"msg_export_deq$1100"`
MsgExportDeqShort struct {
MsgEnvHash Hash
NextWorkchain uint32
NextAddrPrefix uint64
ImportBlockLt uint64
} `tlbSumType:"msg_export_deq_short$1101"`
MsgExportTrReq struct {
OutMsg MsgEnvelope `tlb:"^"`
Imported InMsg `tlb:"^"`
} `tlbSumType:"msg_export_tr_req$111"`
MsgExportDeqImm struct {
OutMsg MsgEnvelope `tlb:"^"`
Reimport InMsg `tlb:"^"`
} `tlbSumType:"msg_export_deq_imm$100"`
}
msg_export_ext$000 msg:^(Message Any)
transaction:^Transaction = OutMsg;
msg_export_imm$010 out_msg:^MsgEnvelope
transaction:^Transaction reimport:^InMsg = OutMsg;
msg_export_new$001 out_msg:^MsgEnvelope
transaction:^Transaction = OutMsg;
msg_export_tr$011 out_msg:^MsgEnvelope
imported:^InMsg = OutMsg;
msg_export_deq$1100 out_msg:^MsgEnvelope
import_block_lt:uint63 = OutMsg;
msg_export_deq_short$1101 msg_env_hash:bits256
next_workchain:int32 next_addr_pfx:uint64 import_block_lt:uint64 = OutMsg;
msg_export_tr_req$111 out_msg:^MsgEnvelope
imported:^InMsg = OutMsg;
msg_export_deq_imm$100 out_msg:^MsgEnvelope
reimport:^InMsg = OutMsg;
type OutMsgDescr ¶
type OutMsgDescr struct {
Hashmap tlb.HashmapAugE[OutMsg, CurrencyCollection] `tlb:"256bits"`
}
_ (HashmapAugE 256 OutMsg CurrencyCollection) = OutMsgDescr
type OutMsgQueue ¶
type OutMsgQueue struct {
Queue tlb.HashmapAugE[EnqueuedMsg, uint64] `tlb:"352bits"`
}
_ (HashmapAugE 352 EnqueuedMsg uint64) = OutMsgQueue;
type OutMsgQueueInfo ¶
type OutMsgQueueInfo struct {
OutQueue OutMsgQueue
ProcInfo ProcessedInfo
IhrPendig IhrPendingInfo
}
_ out_queue:OutMsgQueue proc_info:ProcessedInfo ihr_pending:IhrPendingInfo = OutMsgQueueInfo;
type ProcessedInfo ¶
type ProcessedInfo struct {
ProcessedInfo tlb.HashmapE[ProcessedUpto] `tlb:"96bits"`
}
_ (HashmapE 96 ProcessedUpto) = ProcessedInfo;
type ProcessedUpto ¶
processed_upto$_ last_msg_lt:uint64 last_msg_hash:bits256 = ProcessedUpto;
type RawBlock ¶
type RawBlock struct {
ID TonNodeBlockIdExt
// Data contains a BOC.
Data []byte
}
RawBlock contains a block's data without TL-B deserialization returned by a lite server's GetBlock method.
type ShardAccount ¶
ShardAccount account_descr$_ account:^Account last_trans_hash:bits256 last_trans_lt:uint64 = ShardAccount;
type ShardAccountBlocks ¶
type ShardAccountBlocks struct {
Hashmap tlb.HashmapAugE[AccountBlock, CurrencyCollection] `tlb:"256bits"`
}
_ (HashmapAugE 256 AccountBlock CurrencyCollection) = ShardAccountBlocks
type ShardAccounts ¶
type ShardAccounts struct {
Accounts tlb.HashmapAugE[ShardAccount, DepthBalanceInfo] `tlb:"256bits"`
}
_ (HashmapAugE 256 ShardAccount DepthBalanceInfo) = ShardAccounts;
type ShardDesc ¶
type ShardDesc struct {
tlb.SumType
Old struct {
SeqNo uint32
RegMcSeqno uint32
StartLT uint64
EndLT uint64
RootHash Hash
FileHash Hash
BeforeSplit bool
BeforeMerge bool
WantSplit bool
WantMerge bool
NXCCUpdated bool
Flags uint32 `tlb:"3bits"`
NextCatchainSeqNo uint32
NextValidatorShard int64
MinRefMcSeqNo uint32
GenUTime uint32
} `tlbSumType:"old#b"`
New struct {
SeqNo uint32
RegMcSeqno uint32
StartLT uint64
EndLT uint64
RootHash Hash
FileHash Hash
BeforeSplit bool
BeforeMerge bool
WantSplit bool
WantMerge bool
NXCCUpdated bool
Flags uint32 `tlb:"3bits"`
NextCatchainSeqNo uint32
NextValidatorShard int64
MinRefMcSeqNo uint32
GenUTime uint32
} `tlbSumType:"new#a"`
}
func (ShardDesc) ToBlockId ¶
func (s ShardDesc) ToBlockId(workchain int32) TonNodeBlockIdExt
type ShardFeeCreated ¶
type ShardFeeCreated struct {
Fees CurrencyCollection
Create CurrencyCollection
}
_ fees:CurrencyCollection create:CurrencyCollection = ShardFeeCreated;
type ShardFees ¶
type ShardFees struct {
Hashmap tlb.HashmapAugE[ShardFeeCreated, ShardFeeCreated] `tlb:"96bits"`
}
_ (HashmapAugE 96 ShardFeeCreated ShardFeeCreated) = ShardFees;
type ShardHashes ¶
type ShardHashes struct {
Hashes tlb.HashmapE[tlb.Ref[ShardInfoBinTree]] `tlb:"32bits"`
}
ShardHashes _ (HashmapE 32 ^(BinTree ShardDescr)) = ShardHashes;
type ShardID ¶
type ShardID struct {
// contains filtered or unexported fields
}
func MustParseShardID ¶
func ParseShardID ¶
func (ShardID) MatchAccountID ¶
func (ShardID) MatchBlockID ¶
func (s ShardID) MatchBlockID(block TonNodeBlockId) bool
type ShardIdent ¶
type ShardIdent struct {
Magic tlb.Magic `tlb:"shardident$00"`
ShardPfxBits uint64 `tlb:"6bits"`
WorkchainID int32
ShardPrefix uint64
}
ShardIdent shard_ident$00 shard_pfx_bits:(#<= 60) workchain_id:int32 shard_prefix:uint64 = ShardIdent;
type ShardInfoBinTree ¶
type ShardState ¶
type ShardState struct {
tlb.SumType
UnsplitState struct {
Value ShardStateUnsplit
} `tlbSumType:"_"`
SplitState struct {
Left ShardStateUnsplit `tlb:"^"` // ^ but decodes manually
Right ShardStateUnsplit `tlb:"^"` // ^ but decodes manually
} `tlbSumType:"split_state#5f327da5"`
}
ShardState _ ShardStateUnsplit = ShardState; split_state#5f327da5 left:^ShardStateUnsplit right:^ShardStateUnsplit = ShardState;
func (*ShardState) UnmarshalTLB ¶
func (s *ShardState) UnmarshalTLB(c *boc.Cell, tag string) error
type ShardStateUnsplit ¶
type ShardStateUnsplit struct {
Magic tlb.Magic `tlb:"shard_state#9023afe2"`
ShardStateUnsplit ShardStateUnsplitData
}
ShardStateUnsplit shard_state#9023afe2 global_id:int32 shard_id:ShardIdent seq_no:uint32 vert_seq_no:# gen_utime:uint32 gen_lt:uint64 min_ref_mc_seqno:uint32 out_msg_queue_info:^OutMsgQueueInfo before_split:(## 1) accounts:^ShardAccounts ^[ overload_history:uint64 underload_history:uint64 total_balance:CurrencyCollection total_validator_fees:CurrencyCollection libraries:(HashmapE 256 LibDescr) master_ref:(Maybe BlkMasterInfo) ] custom:(Maybe ^McStateExtra) = ShardStateUnsplit;
type ShardStateUnsplitData ¶
type ShardStateUnsplitData struct {
GlobalID int32
ShardID ShardIdent
SeqNo uint32
VertSeqNo uint32
GenUtime uint32
GenLt uint64
MinRefMcSeqno uint32
OutMsgQueueInfo OutMsgQueueInfo `tlb:"^"`
BeforeSplit bool
Accounts ShardAccounts `tlb:"^"`
Other ShardStateUnsplitOther `tlb:"^"`
Custom tlb.Maybe[tlb.Ref[McStateExtra]]
}
type ShardStateUnsplitOther ¶
type ShardStateUnsplitOther struct {
OverloadHistory uint64
UnderloadHistory uint64
TotalBalance CurrencyCollection
TotalValidatorFees CurrencyCollection
Libraries tlb.HashmapE[LibDescr] `tlb:"256bits"`
MasterRef tlb.Maybe[BlkMasterInfo]
}
^[ overload_history:uint64 underload_history:uint64 total_balance:CurrencyCollection total_validator_fees:CurrencyCollection libraries:(HashmapE 256 LibDescr) master_ref:(Maybe BlkMasterInfo) ]
type SignedSertificate ¶
type SignedSertificate struct {
Certificate Certificate
CertificateSignature CryptoSignature
}
signed_certificate$_ certificate:Certificate certificate_signature:CryptoSignature
= SignedCertificate; // 356+516 = 872 bits
type SmcCapabilities ¶
SmcCapabilities Reorganized SmcCapList type cap_list_nil$0 = SmcCapList; cap_list_next$1 head:SmcCapability tail:SmcCapList = SmcCapList; cap_method_seqno#5371 = SmcCapability; cap_method_pubkey#71f4 = SmcCapability; cap_is_wallet#2177 = SmcCapability; cap_name#ff name:Text = SmcCapability;
type SnakeData ¶
SnakeData tail#_ {bn:#} b:(bits bn) = SnakeData ~0; cons#_ {bn:#} {n:#} b:(bits bn) next:^(SnakeData ~n) = SnakeData ~(n + 1);
type SplitMergeInfo ¶
type SplitMergeInfo struct {
CurSHardPfxLen uint32 `tlb:"6bits"`
AccSplitDepth uint32 `tlb:"6bits"`
ThisAddr Hash
SiblingAddr Hash
}
split_merge_info$_ cur_shard_pfx_len:(## 6)
acc_split_depth:(## 6) this_addr:bits256 sibling_addr:bits256 = SplitMergeInfo;
type StateInit ¶
type StateInit struct {
SplitDepth tlb.Maybe[struct {
Depth uint64 `tlb:"5bits"`
}]
Special tlb.Maybe[TickTock]
Code tlb.Maybe[tlb.Ref[boc.Cell]]
Data tlb.Maybe[tlb.Ref[boc.Cell]]
Library tlb.HashmapE[SimpleLib] `tlb:"256bits"`
}
StateInit _ split_depth:(Maybe (## 5)) special:(Maybe TickTock) code:(Maybe ^Cell) data:(Maybe ^Cell) library:(HashmapE 256 SimpleLib) = StateInit;
type StorageInfo ¶
type StorageInfo struct {
Used StorageUsed
LastPaid uint32
DuePayment tlb.Maybe[Grams]
}
StorageInfo storage_info$_ used:StorageUsed last_paid:uint32 due_payment:(Maybe Grams) = StorageInfo;
type StorageUsed ¶
type StorageUsed struct {
Cells tlb.VarUInteger `tlb:"7bytes"`
Bits tlb.VarUInteger `tlb:"7bytes"`
PublicCells tlb.VarUInteger `tlb:"7bytes"`
}
StorageUsed storage_used$_ cells:(VarUInteger 7) bits:(VarUInteger 7) public_cells:(VarUInteger 7) = StorageUsed;
type StorageUsedShort ¶
type StorageUsedShort struct {
Cells tlb.VarUInteger `tlb:"7bytes"`
Bits tlb.VarUInteger `tlb:"7bytes"`
}
StorageUsedShort storage_used_short$_ cells:(VarUInteger 7) bits:(VarUInteger 7) = StorageUsedShort;
type TonNodeBlockId ¶
func (TonNodeBlockId) String ¶
func (id TonNodeBlockId) String() string
type TonNodeBlockIdExt ¶
type TonNodeBlockIdExt struct {
TonNodeBlockId
RootHash Hash
FileHash Hash
}
func NewTonBlockId ¶
func NewTonBlockId(fileHash, rootHash Hash, seqno int32, shard int64, workchain int32) *TonNodeBlockIdExt
func (TonNodeBlockIdExt) MarshalTL ¶
func (id TonNodeBlockIdExt) MarshalTL() ([]byte, error)
func (TonNodeBlockIdExt) String ¶
func (id TonNodeBlockIdExt) String() string
func (*TonNodeBlockIdExt) UnmarshalTL ¶
func (id *TonNodeBlockIdExt) UnmarshalTL(data []byte) error
type TrActionPhase ¶
type TrActionPhase struct {
Success bool
Valid bool
NoFunds bool
StatusChange AccStatusChange
TotalFwdFees tlb.Maybe[Grams]
TotalActionFees tlb.Maybe[Grams]
ResultCode int32
ResultArg tlb.Maybe[int32]
TotActions uint32 `tlb:"16bits"`
SpecActions uint32 `tlb:"16bits"`
SkippedActions uint32 `tlb:"16bits"`
MsgsCreated uint32 `tlb:"16bits"`
ActionListHash Hash
TotMsgSize StorageUsedShort
}
TrActionPhase tr_phase_action$_ success:Bool valid:Bool no_funds:Bool status_change:AccStatusChange total_fwd_fees:(Maybe Grams) total_action_fees:(Maybe Grams) result_code:int32 result_arg:(Maybe int32) tot_actions:uint16 spec_actions:uint16 skipped_actions:uint16 msgs_created:uint16 action_list_hash:bits256 tot_msg_size:StorageUsedShort = TrActionPhase;
type TrBouncePhase ¶
type TrBouncePhase struct {
tlb.SumType
TrPhaseBounceNegfunds struct {
} `tlbSumType:"tr_phase_bounce_negfunds$00"`
TrPhaseBounceNofunds struct {
MsgSize StorageUsedShort
ReqFwdFees Grams
} `tlbSumType:"tr_phase_bounce_nofunds$01"`
TrPhaseBounceOk struct {
MsgSize StorageUsedShort
MsgFees Grams
FwdFees Grams
} `tlbSumType:"tr_phase_bounce_ok$1"`
}
TrBouncePhase tr_phase_bounce_negfunds$00 = TrBouncePhase; tr_phase_bounce_nofunds$01 msg_size:StorageUsedShort req_fwd_fees:Grams = TrBouncePhase; tr_phase_bounce_ok$1 msg_size:StorageUsedShort msg_fees:Grams fwd_fees:Grams = TrBouncePhase;
type TrComputePhase ¶
type TrComputePhase struct {
tlb.SumType
TrPhaseComputeSkipped struct {
Reason ComputeSkipReason
} `tlbSumType:"tr_phase_compute_skipped$0"`
TrPhaseComputeVm struct {
Success bool
MsgStateUsed bool
AccountActivated bool
GasFees Grams
Vm struct {
GasUsed tlb.VarUInteger `tlb:"7bytes"`
GasLimit tlb.VarUInteger `tlb:"7bytes"`
GasCredit tlb.Maybe[struct {
Val tlb.VarUInteger `tlb:"3bytes"`
}]
Mode int32 `tlb:"8bits"`
ExitCode int32
ExitArg tlb.Maybe[int32]
VmSteps uint32
VmInitStateHash Hash
VmFinalStateHash Hash
} `tlb:"^"`
} `tlbSumType:"tr_phase_compute_vm$1"`
}
TrComputePhase tr_phase_compute_skipped$0 reason:ComputeSkipReason = TrComputePhase; tr_phase_compute_vm$1 success:Bool msg_state_used:Bool account_activated:Bool gas_fees:Grams ^[ gas_used:(VarUInteger 7) gas_limit:(VarUInteger 7) gas_credit:(Maybe (VarUInteger 3)) mode:int8 exit_code:int32 exit_arg:(Maybe int32) vm_steps:uint32 vm_init_state_hash:bits256 vm_final_state_hash:bits256 ] = TrComputePhase;
type TrCreditPhase ¶
type TrCreditPhase struct {
DueFeesCollected tlb.Maybe[Grams]
Credit CurrencyCollection
}
TrCreditPhase tr_phase_credit$_ due_fees_collected:(Maybe Grams) credit:CurrencyCollection = TrCreditPhase;
type TrStoragePhase ¶
type TrStoragePhase struct {
StorageFeesCollected Grams
StorageFeesDue tlb.Maybe[Grams]
StatusChange AccStatusChange
}
TrStoragePhase tr_phase_storage$_ storage_fees_collected:Grams storage_fees_due:(Maybe Grams) status_change:AccStatusChange = TrStoragePhase;
type Transaction ¶
type Transaction struct {
Magic tlb.Magic `tlb:"transaction$0111"`
AccountAddr Hash
Lt uint64
PrevTransHash Hash
PrevTransLt uint64
Now uint32
OutMsgCnt uint32 `tlb:"15bits"`
OrigStatus AccountStatus
EndStatus AccountStatus
Msgs struct {
InMsg tlb.Maybe[tlb.Ref[Message]]
OutMsgs tlb.HashmapE[tlb.Ref[Message]] `tlb:"15bits"`
} `tlb:"^"`
TotalFees CurrencyCollection
StateUpdate HashUpdate `tlb:"^"`
Description TransactionDescr `tlb:"^"`
// contains filtered or unexported fields
}
Transaction transaction$0111 account_addr:bits256 lt:uint64 prev_trans_hash:bits256 prev_trans_lt:uint64 now:uint32 outmsg_cnt:uint15 orig_status:AccountStatus end_status:AccountStatus ^[ in_msg:(Maybe ^(Message Any)) out_msgs:(HashmapE 15 ^(Message Any)) ] total_fees:CurrencyCollection state_update:^(HASH_UPDATE Account) description:^TransactionDescr = Transaction;
func (*Transaction) Hash ¶
func (tx *Transaction) Hash() Hash
Hash returns a hash of this transaction.
func (Transaction) IsSuccess ¶
func (tx Transaction) IsSuccess() bool
func (*Transaction) UnmarshalTLB ¶
func (tx *Transaction) UnmarshalTLB(c *boc.Cell, tag string) error
type TransactionDescr ¶
type TransactionDescr struct {
tlb.SumType
TransOrd struct {
CreditFirst bool
StoragePh tlb.Maybe[TrStoragePhase]
CreditPh tlb.Maybe[TrCreditPhase]
ComputePh TrComputePhase
Action tlb.Maybe[tlb.Ref[TrActionPhase]]
Aborted bool
Bounce tlb.Maybe[TrBouncePhase]
Destroyed bool
} `tlbSumType:"trans_ord$0000"`
TransStorage struct {
StoragePh TrStoragePhase
} `tlbSumType:"trans_storage$0001"`
TransTickTock struct {
IsTock bool
StoragePh TrStoragePhase
ComputePh TrComputePhase
Action tlb.Maybe[tlb.Ref[TrActionPhase]]
Aborted bool
Destroyed bool
} `tlbSumType:"trans_tick_tock$001"`
TransSplitPrepare struct {
SplitInfo SplitMergeInfo
StoragePh tlb.Maybe[TrStoragePhase]
ComputePh TrComputePhase
Action tlb.Maybe[tlb.Ref[TrActionPhase]]
Aborted bool
Destroyed bool
} `tlbSumType:"trans_split_prepare$0100"`
TransSplitInstall struct {
SplitInfo SplitMergeInfo
PrepareTransaction tlb.Any `tlb:"^"`
Installed bool
} `tlbSumType:"trans_split_install$0101"`
TransMergePrepare struct {
SplitInfo SplitMergeInfo
StoragePh TrStoragePhase
Aborted bool
} `tlbSumType:"trans_merge_prepare$0110"`
TransMergeInstall struct {
SplitInfo SplitMergeInfo
PrepareTransaction tlb.Any `tlb:"^"` //Transaction]
StoragePh tlb.Maybe[TrStoragePhase]
CreditPh tlb.Maybe[TrCreditPhase]
ComputePh TrComputePhase
Action tlb.Maybe[tlb.Ref[TrActionPhase]]
Aborted bool
Destroyed bool
} `tlbSumType:"trans_merge_install$0111"`
}
trans_merge_prepare$0110 split_info:SplitMergeInfo
storage_ph:TrStoragePhase aborted:Bool = TransactionDescr;
trans_merge_install$0111 split_info:SplitMergeInfo
prepare_transaction:^Transaction storage_ph:(Maybe TrStoragePhase) credit_ph:(Maybe TrCreditPhase) compute_ph:TrComputePhase action:(Maybe ^TrActionPhase) aborted:Bool destroyed:Bool = TransactionDescr;
type ValidatorBaseInfo ¶
validator_base_info$_
validator_list_hash_short:uint32 catchain_seqno:uint32
= ValidatorBaseInfo;
type ValidatorDescr ¶
type ValidatorDescr struct {
tlb.SumType
// validator#53 public_key:SigPubKey weight:uint64 = ValidatorDescr;
Validator struct {
PublicKey SigPubKey
Weight uint64
} `tlbSumType:"validator#53"`
// validator_addr#73 public_key:SigPubKey weight:uint64 adnl_addr:bits256 = ValidatorDescr;
ValidatorAddr struct {
PublicKey SigPubKey
Weight uint64
AdnlAddr Hash
} `tlbSumType:"validatoraddr#73"`
}
type ValidatorInfo ¶
validator_info$_
validator_list_hash_short:uint32 catchain_seqno:uint32 nx_cc_updated:Bool
= ValidatorInfo;
type ValidatorsSet ¶
type ValidatorsSet struct {
tlb.SumType
// validators#11 utime_since:uint32 utime_until:uint32
// total:(## 16) main:(## 16) { main <= total } { main >= 1 }
// list:(Hashmap 16 ValidatorDescr) = ValidatorSet;
Validators struct {
UtimeSince uint32
UtimeUntil uint32
Total uint32 `tlb:"16bits"`
Main uint32 `tlb:"16bits"`
List tlb.Hashmap[ValidatorDescr] `tlb:"16bits"`
} `tlbSumType:"validators#11"`
// validators_ext#12 utime_since:uint32 utime_until:uint32
// total:(## 16) main:(## 16) { main <= total } { main >= 1 }
// total_weight:uint64 list:(HashmapE 16 ValidatorDescr) = ValidatorSet;
ValidatorsExt struct {
UtimeSince uint32
UtimeUntil uint32
Total uint32 `tlb:"16bits"`
Main uint32 `tlb:"16bits"`
TotalWeight uint64
List tlb.HashmapE[ValidatorDescr] `tlb:"16bits"`
} `tlbSumType:"validatorsext#12"`
}
type ValueFlow ¶
type ValueFlow struct {
Magic tlb.Magic `tlb:"value_flow#b8e48dfb"`
Values1 struct {
FromPrevBlk CurrencyCollection
ToNextBlk CurrencyCollection
Imported CurrencyCollection
Exported CurrencyCollection
} `tlb:"^"`
FeesCollected CurrencyCollection
Values2 struct {
FeesImported CurrencyCollection
Recovered CurrencyCollection
Created CurrencyCollection
Minted CurrencyCollection
} `tlb:"^"`
}
ValueFlow value_flow ^[ from_prev_blk:CurrencyCollection to_next_blk:CurrencyCollection imported:CurrencyCollection exported:CurrencyCollection ] fees_collected:CurrencyCollection ^[ fees_imported:CurrencyCollection recovered:CurrencyCollection created:CurrencyCollection minted:CurrencyCollection ] = ValueFlow;
type VmCellSlice ¶
type VmCellSlice struct {
// contains filtered or unexported fields
}
VmCellSlice _ cell:^Cell st_bits:(## 10) end_bits:(## 10) { st_bits <= end_bits } st_ref:(#<= 4) end_ref:(#<= 4) { st_ref <= end_ref } = VmCellSlice;
func CellToVmCellSlice ¶
func CellToVmCellSlice(cell *boc.Cell) (VmCellSlice, error)
func TlbStructToVmCellSlice ¶
func TlbStructToVmCellSlice(s any) (VmCellSlice, error)
func (VmCellSlice) Cell ¶
func (s VmCellSlice) Cell() *boc.Cell
func (VmCellSlice) MarshalTLB ¶
func (s VmCellSlice) MarshalTLB(c *boc.Cell, tag string) error
func (*VmCellSlice) UnmarshalTLB ¶
func (s *VmCellSlice) UnmarshalTLB(c *boc.Cell, tag string) error
func (VmCellSlice) UnmarshalToTlbStruct ¶
func (s VmCellSlice) UnmarshalToTlbStruct(res any) error
type VmCont ¶
type VmCont struct {
}
VmCont _ cregs:(HashmapE 4 VmStackValue) = VmSaveList; vm_ctl_data$_ nargs:(Maybe uint13) stack:(Maybe VmStack) save:VmSaveList cp:(Maybe int16) = VmControlData; vmc_std$00 cdata:VmControlData code:VmCellSlice = VmCont; vmc_envelope$01 cdata:VmControlData next:^VmCont = VmCont; vmc_quit$1000 exit_code:int32 = VmCont; vmc_quit_exc$1001 = VmCont; vmc_repeat$10100 count:uint63 body:^VmCont after:^VmCont = VmCont; vmc_until$110000 body:^VmCont after:^VmCont = VmCont; vmc_again$110001 body:^VmCont = VmCont; vmc_while_cond$110010 cond:^VmCont body:^VmCont after:^VmCont = VmCont; vmc_while_body$110011 cond:^VmCont body:^VmCont after:^VmCont = VmCont; vmc_pushint$1111 value:int32 next:^VmCont = VmCont;
type VmStack ¶
type VmStack []VmStackValue
VmStack vm_stack#_ depth:(## 24) stack:(VmStackList depth) = VmStack; vm_stk_cons#_ {n:#} rest:^(VmStackList n) tos:VmStackValue = VmStackList (n + 1); vm_stk_nil#_ = VmStackList 0;
func (*VmStack) Put ¶
func (s *VmStack) Put(val VmStackValue)
type VmStackValue ¶
type VmStackValue struct {
tlb.SumType
VmStkNull struct{} `tlbSumType:"vm_stk_null#00"`
VmStkTinyInt int64 `tlbSumType:"vm_stk_tinyint#01"`
VmStkInt Int257 `tlbSumType:"vm_stk_int$000000100000000"` // vm_stk_int#0201_
VmStkNan struct{} `tlbSumType:"vm_stk_nan#02ff"`
VmStkCell tlb.Ref[boc.Cell] `tlbSumType:"vm_stk_cell#03"`
VmStkSlice VmCellSlice `tlbSumType:"vm_stk_slice#04"`
VmStkBuilder tlb.Ref[boc.Cell] `tlbSumType:"vm_stk_builder#05"`
VmStkCont VmCont `tlbSumType:"vm_stk_cont#06"`
VmStkTuple VmStkTuple `tlbSumType:"vm_stk_tuple#07"`
}
VmStackValue vm_stk_null#00 = VmStackValue; vm_stk_tinyint#01 value:int64 = VmStackValue; vm_stk_int#0201_ value:int257 = VmStackValue; vm_stk_nan#02ff = VmStackValue; vm_stk_cell#03 cell:^Cell = VmStackValue; vm_stk_slice#04 _:VmCellSlice = VmStackValue; vm_stk_builder#05 cell:^Cell = VmStackValue; vm_stk_cont#06 cont:VmCont = VmStackValue; vm_stk_tuple#07 len:(## 16) data:(VmTuple len) = VmStackValue;
func (VmStackValue) Cell
deprecated
func (v VmStackValue) Cell() *boc.Cell
Deprecated: Cell is deprecated.
func (VmStackValue) CellSlice
deprecated
func (v VmStackValue) CellSlice() *boc.Cell
Deprecated: CellSlice is deprecated.
func (VmStackValue) Int
deprecated
func (v VmStackValue) Int() big.Int
Deprecated: Int is deprecated.
func (VmStackValue) Int64
deprecated
func (v VmStackValue) Int64() int64
Deprecated: Int64 is deprecated.
func (VmStackValue) IsCell
deprecated
func (v VmStackValue) IsCell() bool
Deprecated: IsCell is deprecated.
func (VmStackValue) IsCellSlice
deprecated
func (v VmStackValue) IsCellSlice() bool
Deprecated: IsCellSlice is deprecated.
func (VmStackValue) IsInt
deprecated
func (v VmStackValue) IsInt() bool
Deprecated: IsInt is deprecated.
func (VmStackValue) IsNull
deprecated
func (v VmStackValue) IsNull() bool
Deprecated: IsNull is deprecated.
func (VmStackValue) IsTuple
deprecated
func (v VmStackValue) IsTuple() bool
Deprecated: IsTuple is deprecated.
func (VmStackValue) Tuple
deprecated
func (v VmStackValue) Tuple() []VmStackValue
Deprecated: Tuple is deprecated.
func (VmStackValue) Uint64
deprecated
func (v VmStackValue) Uint64() uint64
Deprecated: Uint64 is deprecated.
type VmStkTuple ¶
VmStkTuple Custom type: len:(## 16) data:(VmTuple len). Tag excluded. Use with VmStackValue type. vm_tupref_nil$_ = VmTupleRef 0; vm_tupref_single$_ entry:^VmStackValue = VmTupleRef 1; vm_tupref_any$_ {n:#} ref:^(VmTuple (n + 2)) = VmTupleRef (n + 2); vm_tuple_nil$_ = VmTuple 0; vm_tuple_tcons$_ {n:#} head:(VmTupleRef n) tail:^VmStackValue = VmTuple (n + 1); vm_stk_tuple#07 len:(## 16) data:(VmTuple len) = VmStackValue;
func (VmStkTuple) MarshalTLB ¶
func (t VmStkTuple) MarshalTLB(c *boc.Cell, tag string) error
func (*VmStkTuple) UnmarshalTLB ¶
func (t *VmStkTuple) UnmarshalTLB(c *boc.Cell, tag string) error
type VmTuple ¶
type VmTuple struct {
Head VmTupleRef
Tail VmStackValue `tlb:"^"`
}
type VmTupleRef ¶
type VmTupleRef struct {
Entry *VmStackValue `tlb:"^"`
Ref *VmTuple `tlb:"^"`
}