diff --git a/src/commands/contract/structs.ts b/src/commands/contract/structs.ts index f3d2540..02fc54c 100644 --- a/src/commands/contract/structs.ts +++ b/src/commands/contract/structs.ts @@ -214,6 +214,7 @@ export function generateField( decoratorArguments ) ), + ts.factory.createModifier(ts.SyntaxKind.DeclareKeyword), ] const typeReferenceNode = ts.factory.createTypeReferenceNode( @@ -231,9 +232,7 @@ export function generateField( return ts.factory.createPropertyDeclaration( decorators, ts.factory.createIdentifier(fieldName), - ts.factory.createToken( - field.optional ? ts.SyntaxKind.QuestionToken : ts.SyntaxKind.ExclamationToken - ), + field.optional ? ts.factory.createToken(ts.SyntaxKind.QuestionToken) : undefined, typeNode, undefined // initializer ) @@ -330,6 +329,7 @@ function findVariantStructType( return ts.factory.createIdentifier(variantTypeString) } } + function findFieldStructType( typeString: string, namespace: string | undefined, diff --git a/test/data/contracts/mock-atomicassets.ts b/test/data/contracts/mock-atomicassets.ts index 29faaf7..02d789b 100644 --- a/test/data/contracts/mock-atomicassets.ts +++ b/test/data/contracts/mock-atomicassets.ts @@ -95,479 +95,479 @@ export namespace Types { @Struct.type('FORMAT') export class FORMAT extends Struct { @Struct.field('string') - name!: string + declare name: string @Struct.field('string') - type!: string + declare type: string } @Struct.type('acceptoffer') export class acceptoffer extends Struct { @Struct.field(UInt64) - offer_id!: UInt64 + declare offer_id: UInt64 } @Struct.type('addcolauth') export class addcolauth extends Struct { @Struct.field(Name) - collection_name!: Name + declare collection_name: Name @Struct.field(Name) - account_to_add!: Name + declare account_to_add: Name } @Struct.type('addconftoken') export class addconftoken extends Struct { @Struct.field(Name) - token_contract!: Name + declare token_contract: Name @Struct.field(Asset.Symbol) - token_symbol!: Asset.Symbol + declare token_symbol: Asset.Symbol } @Struct.type('addnotifyacc') export class addnotifyacc extends Struct { @Struct.field(Name) - collection_name!: Name + declare collection_name: Name @Struct.field(Name) - account_to_add!: Name + declare account_to_add: Name } @Struct.type('admincoledit') export class admincoledit extends Struct { @Struct.field(FORMAT, {array: true}) - collection_format_extension!: FORMAT[] + declare collection_format_extension: FORMAT[] } @Struct.type('announcedepo') export class announcedepo extends Struct { @Struct.field(Name) - owner!: Name + declare owner: Name @Struct.field(Asset.Symbol) - symbol_to_announce!: Asset.Symbol + declare symbol_to_announce: Asset.Symbol } @Struct.type('assets_s') export class assets_s extends Struct { @Struct.field(UInt64) - asset_id!: UInt64 + declare asset_id: UInt64 @Struct.field(Name) - collection_name!: Name + declare collection_name: Name @Struct.field(Name) - schema_name!: Name + declare schema_name: Name @Struct.field(Int32) - template_id!: Int32 + declare template_id: Int32 @Struct.field(Name) - ram_payer!: Name + declare ram_payer: Name @Struct.field(Asset, {array: true}) - backed_tokens!: Asset[] + declare backed_tokens: Asset[] @Struct.field(UInt8, {array: true}) - immutable_serialized_data!: UInt8[] + declare immutable_serialized_data: UInt8[] @Struct.field(UInt8, {array: true}) - mutable_serialized_data!: UInt8[] + declare mutable_serialized_data: UInt8[] } @Struct.type('backasset') export class backasset extends Struct { @Struct.field(Name) - payer!: Name + declare payer: Name @Struct.field(Name) - asset_owner!: Name + declare asset_owner: Name @Struct.field(UInt64) - asset_id!: UInt64 + declare asset_id: UInt64 @Struct.field(Asset) - token_to_back!: Asset + declare token_to_back: Asset } @Struct.type('balances_s') export class balances_s extends Struct { @Struct.field(Name) - owner!: Name + declare owner: Name @Struct.field(Asset, {array: true}) - quantities!: Asset[] + declare quantities: Asset[] } @Struct.type('burnasset') export class burnasset extends Struct { @Struct.field(Name) - asset_owner!: Name + declare asset_owner: Name @Struct.field(UInt64) - asset_id!: UInt64 + declare asset_id: UInt64 } @Struct.type('canceloffer') export class canceloffer extends Struct { @Struct.field(UInt64) - offer_id!: UInt64 + declare offer_id: UInt64 } @Struct.type('collections_s') export class collections_s extends Struct { @Struct.field(Name) - collection_name!: Name + declare collection_name: Name @Struct.field(Name) - author!: Name + declare author: Name @Struct.field('bool') - allow_notify!: boolean + declare allow_notify: boolean @Struct.field(Name, {array: true}) - authorized_accounts!: Name[] + declare authorized_accounts: Name[] @Struct.field(Name, {array: true}) - notify_accounts!: Name[] + declare notify_accounts: Name[] @Struct.field(Float64) - market_fee!: Float64 + declare market_fee: Float64 @Struct.field(UInt8, {array: true}) - serialized_data!: UInt8[] + declare serialized_data: UInt8[] } @Struct.type('extended_symbol') export class extended_symbol extends Struct { @Struct.field(Asset.Symbol) - sym!: Asset.Symbol + declare sym: Asset.Symbol @Struct.field(Name) - contract!: Name + declare contract: Name } @Struct.type('config_s') export class config_s extends Struct { @Struct.field(UInt64) - asset_counter!: UInt64 + declare asset_counter: UInt64 @Struct.field(Int32) - template_counter!: Int32 + declare template_counter: Int32 @Struct.field(UInt64) - offer_counter!: UInt64 + declare offer_counter: UInt64 @Struct.field(FORMAT, {array: true}) - collection_format!: FORMAT[] + declare collection_format: FORMAT[] @Struct.field(extended_symbol, {array: true}) - supported_tokens!: extended_symbol[] + declare supported_tokens: extended_symbol[] } @Struct.type('pair_string_ATOMIC_ATTRIBUTE') export class pair_string_ATOMIC_ATTRIBUTE extends Struct { @Struct.field('string') - key!: string + declare key: string @Struct.field( variant_int8_int16_int32_int64_uint8_uint16_uint32_uint64_float32_float64_string_INT8_VEC_INT16_VEC_INT32_VEC_INT64_VEC_UINT8_VEC_UINT16_VEC_UINT32_VEC_UINT64_VEC_FLOAT_VEC_DOUBLE_VEC_STRING_VEC ) - value!: variant_int8_int16_int32_int64_uint8_uint16_uint32_uint64_float32_float64_string_INT8_VEC_INT16_VEC_INT32_VEC_INT64_VEC_UINT8_VEC_UINT16_VEC_UINT32_VEC_UINT64_VEC_FLOAT_VEC_DOUBLE_VEC_STRING_VEC + declare value: variant_int8_int16_int32_int64_uint8_uint16_uint32_uint64_float32_float64_string_INT8_VEC_INT16_VEC_INT32_VEC_INT64_VEC_UINT8_VEC_UINT16_VEC_UINT32_VEC_UINT64_VEC_FLOAT_VEC_DOUBLE_VEC_STRING_VEC } @Struct.type('createcol') export class createcol extends Struct { @Struct.field(Name) - author!: Name + declare author: Name @Struct.field(Name) - collection_name!: Name + declare collection_name: Name @Struct.field('bool') - allow_notify!: boolean + declare allow_notify: boolean @Struct.field(Name, {array: true}) - authorized_accounts!: Name[] + declare authorized_accounts: Name[] @Struct.field(Name, {array: true}) - notify_accounts!: Name[] + declare notify_accounts: Name[] @Struct.field(Float64) - market_fee!: Float64 + declare market_fee: Float64 @Struct.field(pair_string_ATOMIC_ATTRIBUTE, {array: true}) - data!: pair_string_ATOMIC_ATTRIBUTE[] + declare data: pair_string_ATOMIC_ATTRIBUTE[] } @Struct.type('createoffer') export class createoffer extends Struct { @Struct.field(Name) - sender!: Name + declare sender: Name @Struct.field(Name) - recipient!: Name + declare recipient: Name @Struct.field(UInt64, {array: true}) - sender_asset_ids!: UInt64[] + declare sender_asset_ids: UInt64[] @Struct.field(UInt64, {array: true}) - recipient_asset_ids!: UInt64[] + declare recipient_asset_ids: UInt64[] @Struct.field('string') - memo!: string + declare memo: string } @Struct.type('createschema') export class createschema extends Struct { @Struct.field(Name) - authorized_creator!: Name + declare authorized_creator: Name @Struct.field(Name) - collection_name!: Name + declare collection_name: Name @Struct.field(Name) - schema_name!: Name + declare schema_name: Name @Struct.field(FORMAT, {array: true}) - schema_format!: FORMAT[] + declare schema_format: FORMAT[] } @Struct.type('createtempl') export class createtempl extends Struct { @Struct.field(Name) - authorized_creator!: Name + declare authorized_creator: Name @Struct.field(Name) - collection_name!: Name + declare collection_name: Name @Struct.field(Name) - schema_name!: Name + declare schema_name: Name @Struct.field('bool') - transferable!: boolean + declare transferable: boolean @Struct.field('bool') - burnable!: boolean + declare burnable: boolean @Struct.field(UInt32) - max_supply!: UInt32 + declare max_supply: UInt32 @Struct.field(pair_string_ATOMIC_ATTRIBUTE, {array: true}) - immutable_data!: pair_string_ATOMIC_ATTRIBUTE[] + declare immutable_data: pair_string_ATOMIC_ATTRIBUTE[] } @Struct.type('declineoffer') export class declineoffer extends Struct { @Struct.field(UInt64) - offer_id!: UInt64 + declare offer_id: UInt64 } @Struct.type('extendschema') export class extendschema extends Struct { @Struct.field(Name) - authorized_editor!: Name + declare authorized_editor: Name @Struct.field(Name) - collection_name!: Name + declare collection_name: Name @Struct.field(Name) - schema_name!: Name + declare schema_name: Name @Struct.field(FORMAT, {array: true}) - schema_format_extension!: FORMAT[] + declare schema_format_extension: FORMAT[] } @Struct.type('forbidnotify') export class forbidnotify extends Struct { @Struct.field(Name) - collection_name!: Name + declare collection_name: Name } @Struct.type('init') export class init extends Struct {} @Struct.type('locktemplate') export class locktemplate extends Struct { @Struct.field(Name) - authorized_editor!: Name + declare authorized_editor: Name @Struct.field(Name) - collection_name!: Name + declare collection_name: Name @Struct.field(Int32) - template_id!: Int32 + declare template_id: Int32 } @Struct.type('logbackasset') export class logbackasset extends Struct { @Struct.field(Name) - asset_owner!: Name + declare asset_owner: Name @Struct.field(UInt64) - asset_id!: UInt64 + declare asset_id: UInt64 @Struct.field(Asset) - backed_token!: Asset + declare backed_token: Asset } @Struct.type('logburnasset') export class logburnasset extends Struct { @Struct.field(Name) - asset_owner!: Name + declare asset_owner: Name @Struct.field(UInt64) - asset_id!: UInt64 + declare asset_id: UInt64 @Struct.field(Name) - collection_name!: Name + declare collection_name: Name @Struct.field(Name) - schema_name!: Name + declare schema_name: Name @Struct.field(Int32) - template_id!: Int32 + declare template_id: Int32 @Struct.field(Asset, {array: true}) - backed_tokens!: Asset[] + declare backed_tokens: Asset[] @Struct.field(pair_string_ATOMIC_ATTRIBUTE, {array: true}) - old_immutable_data!: pair_string_ATOMIC_ATTRIBUTE[] + declare old_immutable_data: pair_string_ATOMIC_ATTRIBUTE[] @Struct.field(pair_string_ATOMIC_ATTRIBUTE, {array: true}) - old_mutable_data!: pair_string_ATOMIC_ATTRIBUTE[] + declare old_mutable_data: pair_string_ATOMIC_ATTRIBUTE[] @Struct.field(Name) - asset_ram_payer!: Name + declare asset_ram_payer: Name } @Struct.type('logmint') export class logmint extends Struct { @Struct.field(UInt64) - asset_id!: UInt64 + declare asset_id: UInt64 @Struct.field(Name) - authorized_minter!: Name + declare authorized_minter: Name @Struct.field(Name) - collection_name!: Name + declare collection_name: Name @Struct.field(Name) - schema_name!: Name + declare schema_name: Name @Struct.field(Int32) - template_id!: Int32 + declare template_id: Int32 @Struct.field(Name) - new_asset_owner!: Name + declare new_asset_owner: Name @Struct.field(pair_string_ATOMIC_ATTRIBUTE, {array: true}) - immutable_data!: pair_string_ATOMIC_ATTRIBUTE[] + declare immutable_data: pair_string_ATOMIC_ATTRIBUTE[] @Struct.field(pair_string_ATOMIC_ATTRIBUTE, {array: true}) - mutable_data!: pair_string_ATOMIC_ATTRIBUTE[] + declare mutable_data: pair_string_ATOMIC_ATTRIBUTE[] @Struct.field(Asset, {array: true}) - backed_tokens!: Asset[] + declare backed_tokens: Asset[] @Struct.field(pair_string_ATOMIC_ATTRIBUTE, {array: true}) - immutable_template_data!: pair_string_ATOMIC_ATTRIBUTE[] + declare immutable_template_data: pair_string_ATOMIC_ATTRIBUTE[] } @Struct.type('lognewoffer') export class lognewoffer extends Struct { @Struct.field(UInt64) - offer_id!: UInt64 + declare offer_id: UInt64 @Struct.field(Name) - sender!: Name + declare sender: Name @Struct.field(Name) - recipient!: Name + declare recipient: Name @Struct.field(UInt64, {array: true}) - sender_asset_ids!: UInt64[] + declare sender_asset_ids: UInt64[] @Struct.field(UInt64, {array: true}) - recipient_asset_ids!: UInt64[] + declare recipient_asset_ids: UInt64[] @Struct.field('string') - memo!: string + declare memo: string } @Struct.type('lognewtempl') export class lognewtempl extends Struct { @Struct.field(Int32) - template_id!: Int32 + declare template_id: Int32 @Struct.field(Name) - authorized_creator!: Name + declare authorized_creator: Name @Struct.field(Name) - collection_name!: Name + declare collection_name: Name @Struct.field(Name) - schema_name!: Name + declare schema_name: Name @Struct.field('bool') - transferable!: boolean + declare transferable: boolean @Struct.field('bool') - burnable!: boolean + declare burnable: boolean @Struct.field(UInt32) - max_supply!: UInt32 + declare max_supply: UInt32 @Struct.field(pair_string_ATOMIC_ATTRIBUTE, {array: true}) - immutable_data!: pair_string_ATOMIC_ATTRIBUTE[] + declare immutable_data: pair_string_ATOMIC_ATTRIBUTE[] } @Struct.type('logsetdata') export class logsetdata extends Struct { @Struct.field(Name) - asset_owner!: Name + declare asset_owner: Name @Struct.field(UInt64) - asset_id!: UInt64 + declare asset_id: UInt64 @Struct.field(pair_string_ATOMIC_ATTRIBUTE, {array: true}) - old_data!: pair_string_ATOMIC_ATTRIBUTE[] + declare old_data: pair_string_ATOMIC_ATTRIBUTE[] @Struct.field(pair_string_ATOMIC_ATTRIBUTE, {array: true}) - new_data!: pair_string_ATOMIC_ATTRIBUTE[] + declare new_data: pair_string_ATOMIC_ATTRIBUTE[] } @Struct.type('logtransfer') export class logtransfer extends Struct { @Struct.field(Name) - collection_name!: Name + declare collection_name: Name @Struct.field(Name) - from!: Name + declare from: Name @Struct.field(Name) - to!: Name + declare to: Name @Struct.field(UInt64, {array: true}) - asset_ids!: UInt64[] + declare asset_ids: UInt64[] @Struct.field('string') - memo!: string + declare memo: string } @Struct.type('mintasset') export class mintasset extends Struct { @Struct.field(Name) - authorized_minter!: Name + declare authorized_minter: Name @Struct.field(Name) - collection_name!: Name + declare collection_name: Name @Struct.field(Name) - schema_name!: Name + declare schema_name: Name @Struct.field(Int32) - template_id!: Int32 + declare template_id: Int32 @Struct.field(Name) - new_asset_owner!: Name + declare new_asset_owner: Name @Struct.field(pair_string_ATOMIC_ATTRIBUTE, {array: true}) - immutable_data!: pair_string_ATOMIC_ATTRIBUTE[] + declare immutable_data: pair_string_ATOMIC_ATTRIBUTE[] @Struct.field(pair_string_ATOMIC_ATTRIBUTE, {array: true}) - mutable_data!: pair_string_ATOMIC_ATTRIBUTE[] + declare mutable_data: pair_string_ATOMIC_ATTRIBUTE[] @Struct.field(Asset, {array: true}) - tokens_to_back!: Asset[] + declare tokens_to_back: Asset[] } @Struct.type('offers_s') export class offers_s extends Struct { @Struct.field(UInt64) - offer_id!: UInt64 + declare offer_id: UInt64 @Struct.field(Name) - sender!: Name + declare sender: Name @Struct.field(Name) - recipient!: Name + declare recipient: Name @Struct.field(UInt64, {array: true}) - sender_asset_ids!: UInt64[] + declare sender_asset_ids: UInt64[] @Struct.field(UInt64, {array: true}) - recipient_asset_ids!: UInt64[] + declare recipient_asset_ids: UInt64[] @Struct.field('string') - memo!: string + declare memo: string @Struct.field(Name) - ram_payer!: Name + declare ram_payer: Name } @Struct.type('payofferram') export class payofferram extends Struct { @Struct.field(Name) - payer!: Name + declare payer: Name @Struct.field(UInt64) - offer_id!: UInt64 + declare offer_id: UInt64 } @Struct.type('remcolauth') export class remcolauth extends Struct { @Struct.field(Name) - collection_name!: Name + declare collection_name: Name @Struct.field(Name) - account_to_remove!: Name + declare account_to_remove: Name } @Struct.type('remnotifyacc') export class remnotifyacc extends Struct { @Struct.field(Name) - collection_name!: Name + declare collection_name: Name @Struct.field(Name) - account_to_remove!: Name + declare account_to_remove: Name } @Struct.type('schemas_s') export class schemas_s extends Struct { @Struct.field(Name) - schema_name!: Name + declare schema_name: Name @Struct.field(FORMAT, {array: true}) - format!: FORMAT[] + declare format: FORMAT[] } @Struct.type('setassetdata') export class setassetdata extends Struct { @Struct.field(Name) - authorized_editor!: Name + declare authorized_editor: Name @Struct.field(Name) - asset_owner!: Name + declare asset_owner: Name @Struct.field(UInt64) - asset_id!: UInt64 + declare asset_id: UInt64 @Struct.field(pair_string_ATOMIC_ATTRIBUTE, {array: true}) - new_mutable_data!: pair_string_ATOMIC_ATTRIBUTE[] + declare new_mutable_data: pair_string_ATOMIC_ATTRIBUTE[] } @Struct.type('setcoldata') export class setcoldata extends Struct { @Struct.field(Name) - collection_name!: Name + declare collection_name: Name @Struct.field(pair_string_ATOMIC_ATTRIBUTE, {array: true}) - data!: pair_string_ATOMIC_ATTRIBUTE[] + declare data: pair_string_ATOMIC_ATTRIBUTE[] } @Struct.type('setmarketfee') export class setmarketfee extends Struct { @Struct.field(Name) - collection_name!: Name + declare collection_name: Name @Struct.field(Float64) - market_fee!: Float64 + declare market_fee: Float64 } @Struct.type('setversion') export class setversion extends Struct { @Struct.field('string') - new_version!: string + declare new_version: string } @Struct.type('templates_s') export class templates_s extends Struct { @Struct.field(Int32) - template_id!: Int32 + declare template_id: Int32 @Struct.field(Name) - schema_name!: Name + declare schema_name: Name @Struct.field('bool') - transferable!: boolean + declare transferable: boolean @Struct.field('bool') - burnable!: boolean + declare burnable: boolean @Struct.field(UInt32) - max_supply!: UInt32 + declare max_supply: UInt32 @Struct.field(UInt32) - issued_supply!: UInt32 + declare issued_supply: UInt32 @Struct.field(UInt8, {array: true}) - immutable_serialized_data!: UInt8[] + declare immutable_serialized_data: UInt8[] } @Struct.type('tokenconfigs_s') export class tokenconfigs_s extends Struct { @Struct.field(Name) - standard!: Name + declare standard: Name @Struct.field('string') - version!: string + declare version: string } @Struct.type('transfer') export class transfer extends Struct { @Struct.field(Name) - from!: Name + declare from: Name @Struct.field(Name) - to!: Name + declare to: Name @Struct.field(UInt64, {array: true}) - asset_ids!: UInt64[] + declare asset_ids: UInt64[] @Struct.field('string') - memo!: string + declare memo: string } @Struct.type('withdraw') export class withdraw extends Struct { @Struct.field(Name) - owner!: Name + declare owner: Name @Struct.field(Asset) - token_to_withdraw!: Asset + declare token_to_withdraw: Asset } } export const TableMap = { diff --git a/test/data/contracts/mock-boid.ts b/test/data/contracts/mock-boid.ts index 62251fe..589c216 100644 --- a/test/data/contracts/mock-boid.ts +++ b/test/data/contracts/mock-boid.ts @@ -95,543 +95,543 @@ export namespace Types { @Struct.type('AccountAuth') export class AccountAuth extends Struct { @Struct.field(PublicKey, {array: true}) - keys!: PublicKey[] + declare keys: PublicKey[] @Struct.field(UInt8) - nonce!: UInt8 + declare nonce: UInt8 } @Struct.type('TokenUnstake') export class TokenUnstake extends Struct { @Struct.field(UInt16) - redeemable_after_round!: UInt16 + declare redeemable_after_round: UInt16 @Struct.field(UInt32) - quantity!: UInt32 + declare quantity: UInt32 } @Struct.type('AccountStake') export class AccountStake extends Struct { @Struct.field(TokenUnstake, {array: true}) - unstaking!: TokenUnstake[] + declare unstaking: TokenUnstake[] @Struct.field(UInt32) - self_staked!: UInt32 + declare self_staked: UInt32 @Struct.field(UInt16) - received_delegated_stake!: UInt16 + declare received_delegated_stake: UInt16 } @Struct.type('AccountBooster') export class AccountBooster extends Struct { @Struct.field(UInt8) - pwr_multiplier!: UInt8 + declare pwr_multiplier: UInt8 @Struct.field(UInt16) - pwr_add_per_round!: UInt16 + declare pwr_add_per_round: UInt16 @Struct.field(UInt16) - expires_round!: UInt16 + declare expires_round: UInt16 @Struct.field(UInt32) - aggregate_pwr_remaining!: UInt32 + declare aggregate_pwr_remaining: UInt32 } @Struct.type('AccountPower') export class AccountPower extends Struct { @Struct.field(UInt16) - last_claimed_round!: UInt16 + declare last_claimed_round: UInt16 @Struct.field(UInt16) - last_added_round!: UInt16 + declare last_added_round: UInt16 @Struct.field(UInt32) - rating!: UInt32 + declare rating: UInt32 @Struct.field(UInt16, {array: true}) - history!: UInt16[] + declare history: UInt16[] @Struct.field(AccountBooster, {array: true}) - mods!: AccountBooster[] + declare mods: AccountBooster[] } @Struct.type('AccountTeam') export class AccountTeam extends Struct { @Struct.field(UInt8) - team_id!: UInt8 + declare team_id: UInt8 @Struct.field(UInt16) - last_edit_round!: UInt16 + declare last_edit_round: UInt16 @Struct.field(UInt8) - team_tax_mult!: UInt8 + declare team_tax_mult: UInt8 @Struct.field(UInt32) - team_cumulative_contribution!: UInt32 + declare team_cumulative_contribution: UInt32 } @Struct.type('Account') export class Account extends Struct { @Struct.field(Name) - boid_id!: Name + declare boid_id: Name @Struct.field(Name, {array: true}) - owners!: Name[] + declare owners: Name[] @Struct.field(AccountAuth) - auth!: AccountAuth + declare auth: AccountAuth @Struct.field(Name, {array: true}) - sponsors!: Name[] + declare sponsors: Name[] @Struct.field(AccountStake) - stake!: AccountStake + declare stake: AccountStake @Struct.field(AccountPower) - power!: AccountPower + declare power: AccountPower @Struct.field(AccountTeam) - team!: AccountTeam + declare team: AccountTeam @Struct.field(UInt32) - balance!: UInt32 + declare balance: UInt32 @Struct.field(UInt16) - nft_balance!: UInt16 + declare nft_balance: UInt16 @Struct.field('bool') - recoverable!: boolean + declare recoverable: boolean } @Struct.type('AccountCreate') export class AccountCreate extends Struct { @Struct.field(Name) - boid_id!: Name + declare boid_id: Name @Struct.field(PublicKey, {array: true}) - keys!: PublicKey[] + declare keys: PublicKey[] @Struct.field(Name, {array: true}) - owners!: Name[] + declare owners: Name[] } @Struct.type('AcctMeta') export class AcctMeta extends Struct { @Struct.field(Name) - boid_id!: Name + declare boid_id: Name @Struct.field(Bytes) - meta!: Bytes + declare meta: Bytes } @Struct.type('PermissionLevel') export class PermissionLevel extends Struct { @Struct.field(Name) - actor!: Name + declare actor: Name @Struct.field(Name) - permission!: Name + declare permission: Name } @Struct.type('Action') export class Action extends Struct { @Struct.field(Name) - account!: Name + declare account: Name @Struct.field(Name) - name!: Name + declare name: Name @Struct.field(PermissionLevel, {array: true}) - authorization!: PermissionLevel[] + declare authorization: PermissionLevel[] @Struct.field(Bytes) - data!: Bytes + declare data: Bytes } @Struct.type('AtomicAttribute') export class AtomicAttribute extends Struct { @Struct.field('string') - key!: string + declare key: string @Struct.field(AtomicValue) - value!: AtomicValue + declare value: AtomicValue } @Struct.type('AtomicFormat') export class AtomicFormat extends Struct { @Struct.field('string') - name!: string + declare name: string @Struct.field('string') - type!: string + declare type: string } @Struct.type('Auth') export class Auth extends Struct { @Struct.field(Name) - boid_id_auth!: Name + declare boid_id_auth: Name } @Struct.type('Booster') export class Booster extends Struct { @Struct.field(UInt8) - mod_id!: UInt8 + declare mod_id: UInt8 @Struct.field(UInt8) - pwr_multiplier!: UInt8 + declare pwr_multiplier: UInt8 @Struct.field(UInt16) - pwr_add_per_round!: UInt16 + declare pwr_add_per_round: UInt16 @Struct.field(UInt16) - expire_after_elapsed_rounds!: UInt16 + declare expire_after_elapsed_rounds: UInt16 @Struct.field(UInt32) - aggregate_pwr_capacity!: UInt32 + declare aggregate_pwr_capacity: UInt32 } @Struct.type('ConfigAccount') export class ConfigAccount extends Struct { @Struct.field(UInt32) - invite_price!: UInt32 + declare invite_price: UInt32 @Struct.field(UInt32) - premium_purchase_price!: UInt32 + declare premium_purchase_price: UInt32 @Struct.field(UInt8) - max_premium_prefix!: UInt8 + declare max_premium_prefix: UInt8 @Struct.field(UInt8) - max_owners!: UInt8 + declare max_owners: UInt8 @Struct.field(UInt8) - max_boosters!: UInt8 + declare max_boosters: UInt8 @Struct.field(Name, {array: true}) - suffix_whitelist!: Name[] + declare suffix_whitelist: Name[] @Struct.field(UInt32) - remove_sponsor_price!: UInt32 + declare remove_sponsor_price: UInt32 @Struct.field(UInt8) - sponsor_max_invite_codes!: UInt8 + declare sponsor_max_invite_codes: UInt8 @Struct.field(UInt16) - invite_code_expire_rounds!: UInt16 + declare invite_code_expire_rounds: UInt16 } @Struct.type('ConfigPower') export class ConfigPower extends Struct { @Struct.field(Float32) - sponsor_tax_mult!: Float32 + declare sponsor_tax_mult: Float32 @Struct.field(Float32) - powered_stake_mult!: Float32 + declare powered_stake_mult: Float32 @Struct.field(UInt16) - claim_maximum_elapsed_rounds!: UInt16 + declare claim_maximum_elapsed_rounds: UInt16 @Struct.field(UInt16) - soft_max_pwr_add!: UInt16 + declare soft_max_pwr_add: UInt16 @Struct.field(UInt8) - history_slots_length!: UInt8 + declare history_slots_length: UInt8 } @Struct.type('ConfigMint') export class ConfigMint extends Struct { @Struct.field(Float32) - round_powered_stake_mult!: Float32 + declare round_powered_stake_mult: Float32 @Struct.field(Float32) - round_power_mult!: Float32 + declare round_power_mult: Float32 } @Struct.type('ConfigTeam') export class ConfigTeam extends Struct { @Struct.field(UInt16) - change_min_rounds!: UInt16 + declare change_min_rounds: UInt16 @Struct.field(UInt16) - edit_team_min_rounds!: UInt16 + declare edit_team_min_rounds: UInt16 @Struct.field(UInt16) - team_edit_max_pct_change!: UInt16 + declare team_edit_max_pct_change: UInt16 @Struct.field(UInt32) - buy_team_cost!: UInt32 + declare buy_team_cost: UInt32 @Struct.field(UInt32) - owner_stake_required!: UInt32 + declare owner_stake_required: UInt32 @Struct.field(UInt16) - owner_future_stake_lock_rounds_required!: UInt16 + declare owner_future_stake_lock_rounds_required: UInt16 } @Struct.type('ConfigStake') export class ConfigStake extends Struct { @Struct.field(UInt8) - unstake_rounds!: UInt8 + declare unstake_rounds: UInt8 @Struct.field(UInt8) - extra_stake_min_locked_rounds!: UInt8 + declare extra_stake_min_locked_rounds: UInt8 } @Struct.type('ConfigTime') export class ConfigTime extends Struct { @Struct.field(UInt32) - rounds_start_sec_since_epoch!: UInt32 + declare rounds_start_sec_since_epoch: UInt32 @Struct.field(UInt32) - round_length_sec!: UInt32 + declare round_length_sec: UInt32 } @Struct.type('ConfigAuth') export class ConfigAuth extends Struct { @Struct.field(Name, {array: true}) - key_actions_whitelist!: Name[] + declare key_actions_whitelist: Name[] @Struct.field(UInt32) - key_account_max_stake!: UInt32 + declare key_account_max_stake: UInt32 @Struct.field(UInt32) - key_account_max_balance!: UInt32 + declare key_account_max_balance: UInt32 @Struct.field(UInt8) - account_max_keys!: UInt8 + declare account_max_keys: UInt8 @Struct.field(UInt32) - worker_max_bill_per_action!: UInt32 + declare worker_max_bill_per_action: UInt32 } @Struct.type('ConfigNft') export class ConfigNft extends Struct { @Struct.field(UInt16) - boid_id_maximum_nfts!: UInt16 + declare boid_id_maximum_nfts: UInt16 @Struct.field(Name, {array: true}) - whitelist_collections!: Name[] + declare whitelist_collections: Name[] } @Struct.type('Config') export class Config extends Struct { @Struct.field(ConfigAccount) - account!: ConfigAccount + declare account: ConfigAccount @Struct.field(ConfigPower) - power!: ConfigPower + declare power: ConfigPower @Struct.field(ConfigMint) - mint!: ConfigMint + declare mint: ConfigMint @Struct.field(ConfigTeam) - team!: ConfigTeam + declare team: ConfigTeam @Struct.field(ConfigStake) - stake!: ConfigStake + declare stake: ConfigStake @Struct.field(ConfigTime) - time!: ConfigTime + declare time: ConfigTime @Struct.field(ConfigAuth) - auth!: ConfigAuth + declare auth: ConfigAuth @Struct.field(ConfigNft) - nft!: ConfigNft + declare nft: ConfigNft @Struct.field('bool') - paused!: boolean + declare paused: boolean @Struct.field('bool') - allow_deposits!: boolean + declare allow_deposits: boolean @Struct.field('bool') - allow_withdrawals!: boolean + declare allow_withdrawals: boolean @Struct.field(Name) - recoveryAccount!: Name + declare recoveryAccount: Name } @Struct.type('ExtendedSymbol') export class ExtendedSymbol extends Struct { @Struct.field(Asset.Symbol) - sym!: Asset.Symbol + declare sym: Asset.Symbol @Struct.field(Name) - contract!: Name + declare contract: Name } @Struct.type('Global') export class Global extends Struct { @Struct.field(Name) - chain_name!: Name + declare chain_name: Name @Struct.field(UInt64) - total_power!: UInt64 + declare total_power: UInt64 @Struct.field(UInt16) - last_inflation_adjust_round!: UInt16 + declare last_inflation_adjust_round: UInt16 } @Struct.type('Invite') export class Invite extends Struct { @Struct.field(UInt64) - invite_code!: UInt64 + declare invite_code: UInt64 @Struct.field(PublicKey) - key!: PublicKey + declare key: PublicKey @Struct.field(UInt16) - created_round!: UInt16 + declare created_round: UInt16 } @Struct.type('MintLog') export class MintLog extends Struct { @Struct.field(UInt32) - power_mint!: UInt32 + declare power_mint: UInt32 @Struct.field(UInt32) - powered_stake_mint!: UInt32 + declare powered_stake_mint: UInt32 @Struct.field(UInt32) - account_earned!: UInt32 + declare account_earned: UInt32 @Struct.field(UInt32) - team_cut!: UInt32 + declare team_cut: UInt32 @Struct.field(UInt32) - team_owner_earned!: UInt32 + declare team_owner_earned: UInt32 @Struct.field(UInt32) - overstake_mint!: UInt32 + declare overstake_mint: UInt32 @Struct.field(UInt32) - total!: UInt32 + declare total: UInt32 } @Struct.type('NFT') export class NFT extends Struct { @Struct.field(UInt64) - asset_id!: UInt64 + declare asset_id: UInt64 @Struct.field(UInt16) - locked_until_round!: UInt16 + declare locked_until_round: UInt16 } @Struct.type('NFTMint') export class NFTMint extends Struct { @Struct.field(Name) - mint_receiver_boid_id!: Name + declare mint_receiver_boid_id: Name @Struct.field(UInt16) - mint_quantity_remaining!: UInt16 + declare mint_quantity_remaining: UInt16 } @Struct.type('NftAction') export class NftAction extends Struct { @Struct.field(Name) - collection_name!: Name + declare collection_name: Name @Struct.field(Name) - schema_name!: Name + declare schema_name: Name @Struct.field(Int32) - template_id!: Int32 + declare template_id: Int32 @Struct.field(AtomicAttribute, {array: true}) - match_immutable_attributes!: AtomicAttribute[] + declare match_immutable_attributes: AtomicAttribute[] @Struct.field(AtomicAttribute, {array: true}) - match_mutable_attributes!: AtomicAttribute[] + declare match_mutable_attributes: AtomicAttribute[] @Struct.field('bool') - burn!: boolean + declare burn: boolean @Struct.field(UInt16) - lock_rounds!: UInt16 + declare lock_rounds: UInt16 } @Struct.type('NftMint') export class NftMint extends Struct { @Struct.field(Int32) - mint_template_id!: Int32 + declare mint_template_id: Int32 @Struct.field(Name) - mint_schema_name!: Name + declare mint_schema_name: Name @Struct.field(Name) - mint_collection_name!: Name + declare mint_collection_name: Name @Struct.field(AtomicAttribute, {array: true}) - immutable_data!: AtomicAttribute[] + declare immutable_data: AtomicAttribute[] @Struct.field(AtomicAttribute, {array: true}) - mutable_data!: AtomicAttribute[] + declare mutable_data: AtomicAttribute[] @Struct.field(UInt8) - quantity!: UInt8 + declare quantity: UInt8 } @Struct.type('OfferRequirements') export class OfferRequirements extends Struct { @Struct.field(Bytes) - team_id!: Bytes + declare team_id: Bytes @Struct.field(UInt16) - min_power!: UInt16 + declare min_power: UInt16 @Struct.field(UInt32) - min_balance!: UInt32 + declare min_balance: UInt32 @Struct.field(UInt32) - min_stake!: UInt32 + declare min_stake: UInt32 @Struct.field(UInt32) - min_cumulative_team_contribution!: UInt32 + declare min_cumulative_team_contribution: UInt32 } @Struct.type('OfferAction') export class OfferAction extends Struct { @Struct.field(UInt16) - delegated_stake!: UInt16 + declare delegated_stake: UInt16 @Struct.field(UInt16) - stake_locked_additional_rounds!: UInt16 + declare stake_locked_additional_rounds: UInt16 @Struct.field(NftAction, {array: true}) - nft_actions!: NftAction[] + declare nft_actions: NftAction[] @Struct.field(UInt32) - balance_payment!: UInt32 + declare balance_payment: UInt32 } @Struct.type('OfferRewards') export class OfferRewards extends Struct { @Struct.field(NftMint, {array: true}) - nft_mints!: NftMint[] + declare nft_mints: NftMint[] @Struct.field(UInt32) - balance_deposit!: UInt32 + declare balance_deposit: UInt32 @Struct.field(UInt16) - delegated_stake!: UInt16 + declare delegated_stake: UInt16 @Struct.field(UInt16) - stake_locked_additional_rounds!: UInt16 + declare stake_locked_additional_rounds: UInt16 @Struct.field(Bytes) - activate_powermod_ids!: Bytes + declare activate_powermod_ids: Bytes } @Struct.type('OfferLimits') export class OfferLimits extends Struct { @Struct.field(UInt32) - offer_quantity_remaining!: UInt32 + declare offer_quantity_remaining: UInt32 @Struct.field(UInt16) - available_until_round!: UInt16 + declare available_until_round: UInt16 } @Struct.type('Offer') export class Offer extends Struct { @Struct.field(UInt64) - offer_id!: UInt64 + declare offer_id: UInt64 @Struct.field(OfferRequirements) - requirements!: OfferRequirements + declare requirements: OfferRequirements @Struct.field(OfferAction) - actions!: OfferAction + declare actions: OfferAction @Struct.field(OfferRewards) - rewards!: OfferRewards + declare rewards: OfferRewards @Struct.field(OfferLimits) - limits!: OfferLimits + declare limits: OfferLimits @Struct.field(UInt32) - total_claimed!: UInt32 + declare total_claimed: UInt32 } @Struct.type('PowerClaimLog') export class PowerClaimLog extends Struct { @Struct.field(UInt32) - before!: UInt32 + declare before: UInt32 @Struct.field(UInt32) - after!: UInt32 + declare after: UInt32 @Struct.field(UInt32) - from_boosters!: UInt32 + declare from_boosters: UInt32 @Struct.field(UInt16) - elapsed_rounds!: UInt16 + declare elapsed_rounds: UInt16 } @Struct.type('Sponsor') export class Sponsor extends Struct { @Struct.field(Name) - sponsor_boid_id!: Name + declare sponsor_boid_id: Name @Struct.field(UInt16) - invites_balance!: UInt16 + declare invites_balance: UInt16 @Struct.field(UInt16) - invite_codes_unclaimed!: UInt16 + declare invite_codes_unclaimed: UInt16 @Struct.field(UInt32) - invite_codes_claimed!: UInt32 + declare invite_codes_claimed: UInt32 @Struct.field(UInt32) - sponsored_upgrades!: UInt32 + declare sponsored_upgrades: UInt32 @Struct.field(UInt32) - upgrades_total_earned!: UInt32 + declare upgrades_total_earned: UInt32 } @Struct.type('Stake') export class Stake extends Struct { @Struct.field(UInt64) - stake_id!: UInt64 + declare stake_id: UInt64 @Struct.field(Name) - from_boid_id!: Name + declare from_boid_id: Name @Struct.field(Name) - to_boid_id!: Name + declare to_boid_id: Name @Struct.field(UInt16) - stake_quantity!: UInt16 + declare stake_quantity: UInt16 @Struct.field(UInt16) - locked_until_round!: UInt16 + declare locked_until_round: UInt16 } @Struct.type('Team') export class Team extends Struct { @Struct.field(UInt16) - team_id!: UInt16 + declare team_id: UInt16 @Struct.field(UInt32) - balance!: UInt32 + declare balance: UInt32 @Struct.field(AccountStake) - stake!: AccountStake + declare stake: AccountStake @Struct.field(Name) - owner!: Name + declare owner: Name @Struct.field(Name, {array: true}) - managers!: Name[] + declare managers: Name[] @Struct.field(UInt8) - min_pwr_tax_mult!: UInt8 + declare min_pwr_tax_mult: UInt8 @Struct.field(UInt8) - owner_cut_mult!: UInt8 + declare owner_cut_mult: UInt8 @Struct.field('string') - url_safe_name!: string + declare url_safe_name: string @Struct.field(UInt64) - power!: UInt64 + declare power: UInt64 @Struct.field(UInt32) - members!: UInt32 + declare members: UInt32 @Struct.field(UInt16) - last_edit_round!: UInt16 + declare last_edit_round: UInt16 @Struct.field(Bytes) - meta!: Bytes + declare meta: Bytes } @Struct.type('account.add') export class accountadd extends Struct { @Struct.field(Name) - boid_id!: Name + declare boid_id: Name @Struct.field(Name, {array: true}) - owners!: Name[] + declare owners: Name[] @Struct.field(Name, {array: true}) - sponsors!: Name[] + declare sponsors: Name[] @Struct.field(PublicKey, {array: true}) - keys!: PublicKey[] + declare keys: PublicKey[] } @Struct.type('account.buy') export class accountbuy extends Struct { @Struct.field(Name) - payer_boid_id!: Name + declare payer_boid_id: Name @Struct.field(AccountCreate) - new_account!: AccountCreate + declare new_account: AccountCreate } @Struct.type('account.edit') export class accountedit extends Struct { @Struct.field(Name) - boid_id!: Name + declare boid_id: Name @Struct.field(Bytes) - meta!: Bytes + declare meta: Bytes } @Struct.type('account.free') export class accountfree extends Struct { @Struct.field(Name) - boid_id!: Name + declare boid_id: Name } @Struct.type('account.mod') export class accountmod extends Struct { @Struct.field(Name) - boid_id!: Name + declare boid_id: Name @Struct.field(UInt16) - received_delegated_stake!: UInt16 + declare received_delegated_stake: UInt16 } @Struct.type('account.rm') export class accountrm extends Struct { @Struct.field(Name) - boid_id!: Name + declare boid_id: Name } @Struct.type('accounts.clr') export class accountsclr extends Struct {} @Struct.type('auth') export class auth extends Struct { @Struct.field(Name) - boid_id!: Name + declare boid_id: Name @Struct.field(Action, {array: true}) - actions!: Action[] + declare actions: Action[] @Struct.field(Signature) - sig!: Signature + declare sig: Signature @Struct.field(Int32) - keyIndex!: Int32 + declare keyIndex: Int32 @Struct.field(UInt32) - expires_utc_sec!: UInt32 + declare expires_utc_sec: UInt32 } @Struct.type('auth.addkey') export class authaddkey extends Struct { @Struct.field(Name) - boid_id!: Name + declare boid_id: Name @Struct.field(PublicKey) - key!: PublicKey + declare key: PublicKey } @Struct.type('auth.clear') export class authclear extends Struct {} @@ -640,341 +640,341 @@ export namespace Types { @Struct.type('auth.rmkey') export class authrmkey extends Struct { @Struct.field(Name) - boid_id!: Name + declare boid_id: Name @Struct.field(Int32) - keyIndex!: Int32 + declare keyIndex: Int32 } @Struct.type('booster.add') export class boosteradd extends Struct { @Struct.field(Name) - boid_id!: Name + declare boid_id: Name @Struct.field(UInt8) - mod_id!: UInt8 + declare mod_id: UInt8 } @Struct.type('booster.new') export class boosternew extends Struct { @Struct.field(Booster) - mod!: Booster + declare mod: Booster } @Struct.type('booster.rm') export class boosterrm extends Struct { @Struct.field(Name) - boid_id!: Name + declare boid_id: Name @Struct.field(Int32, {array: true}) - booster_index!: Int32[] + declare booster_index: Int32[] } @Struct.type('config.clear') export class configclear extends Struct {} @Struct.type('config.set') export class configset extends Struct { @Struct.field(Config) - config!: Config + declare config: Config } @Struct.type('global.chain') export class globalchain extends Struct { @Struct.field(Name) - chain_name!: Name + declare chain_name: Name } @Struct.type('global.clear') export class globalclear extends Struct {} @Struct.type('global.set') export class globalset extends Struct { @Struct.field(Global) - globalData!: Global + declare globalData: Global } @Struct.type('internalxfer') export class internalxfer extends Struct { @Struct.field(Name) - from_boid_id!: Name + declare from_boid_id: Name @Struct.field(Name) - to_boid_id!: Name + declare to_boid_id: Name @Struct.field(UInt32) - quantity!: UInt32 + declare quantity: UInt32 @Struct.field('string') - memo!: string + declare memo: string } @Struct.type('invite.add') export class inviteadd extends Struct { @Struct.field(Name) - boid_id!: Name + declare boid_id: Name @Struct.field(UInt64) - invite_code!: UInt64 + declare invite_code: UInt64 @Struct.field(PublicKey) - key!: PublicKey + declare key: PublicKey } @Struct.type('invite.buy') export class invitebuy extends Struct { @Struct.field(Name) - boid_id!: Name + declare boid_id: Name @Struct.field(UInt16) - quantity!: UInt16 + declare quantity: UInt16 } @Struct.type('invite.claim') export class inviteclaim extends Struct { @Struct.field(Name) - sponsor_boid_id!: Name + declare sponsor_boid_id: Name @Struct.field(UInt64) - invite_code!: UInt64 + declare invite_code: UInt64 @Struct.field(Signature) - sig!: Signature + declare sig: Signature @Struct.field(AccountCreate) - new_account!: AccountCreate + declare new_account: AccountCreate } @Struct.type('invite.rm') export class inviterm extends Struct { @Struct.field(Name) - sponsor_boid_id!: Name + declare sponsor_boid_id: Name @Struct.field(UInt64) - invite_code!: UInt64 + declare invite_code: UInt64 } @Struct.type('logpwradd') export class logpwradd extends Struct { @Struct.field(Name) - boid_id!: Name + declare boid_id: Name @Struct.field(UInt16) - received!: UInt16 + declare received: UInt16 @Struct.field(UInt16) - from_mult_mods!: UInt16 + declare from_mult_mods: UInt16 @Struct.field(UInt16) - diverted_to_sponsor!: UInt16 + declare diverted_to_sponsor: UInt16 @Struct.field(UInt16) - power_increased!: UInt16 + declare power_increased: UInt16 @Struct.field(Name) - orign!: Name + declare orign: Name } @Struct.type('logpwrclaim') export class logpwrclaim extends Struct { @Struct.field(Name) - boid_id!: Name + declare boid_id: Name @Struct.field(PowerClaimLog) - power!: PowerClaimLog + declare power: PowerClaimLog @Struct.field(MintLog) - mint!: MintLog + declare mint: MintLog } @Struct.type('meta.clean') export class metaclean extends Struct {} @Struct.type('mint') export class mint extends Struct { @Struct.field(Name) - to!: Name + declare to: Name @Struct.field(UInt32) - whole_quantity!: UInt32 + declare whole_quantity: UInt32 } @Struct.type('nft.lock') export class nftlock extends Struct { @Struct.field(Name) - boid_id!: Name + declare boid_id: Name @Struct.field(UInt64) - asset_id!: UInt64 + declare asset_id: UInt64 @Struct.field(UInt16) - locked_until_round!: UInt16 + declare locked_until_round: UInt16 } @Struct.type('nft.receiver') export class nftreceiver extends Struct { @Struct.field(Name) - boid_id!: Name + declare boid_id: Name @Struct.field(UInt16) - mint_quantity!: UInt16 + declare mint_quantity: UInt16 } @Struct.type('nft.withdraw') export class nftwithdraw extends Struct { @Struct.field(Name) - boid_id!: Name + declare boid_id: Name @Struct.field(UInt64, {array: true}) - asset_ids!: UInt64[] + declare asset_ids: UInt64[] @Struct.field(Name) - to!: Name + declare to: Name } @Struct.type('nft.xfer') export class nftxfer extends Struct { @Struct.field(Name) - from_boid_id!: Name + declare from_boid_id: Name @Struct.field(Name) - to_boid_id!: Name + declare to_boid_id: Name @Struct.field(UInt64, {array: true}) - asset_ids!: UInt64[] + declare asset_ids: UInt64[] } @Struct.type('offer.add') export class offeradd extends Struct { @Struct.field(OfferRequirements) - requirements!: OfferRequirements + declare requirements: OfferRequirements @Struct.field(OfferAction) - actions!: OfferAction + declare actions: OfferAction @Struct.field(OfferRewards) - rewards!: OfferRewards + declare rewards: OfferRewards @Struct.field(OfferLimits) - limits!: OfferLimits + declare limits: OfferLimits } @Struct.type('offer.claim') export class offerclaim extends Struct { @Struct.field(Name) - boid_id!: Name + declare boid_id: Name @Struct.field(UInt64) - offer_id!: UInt64 + declare offer_id: UInt64 @Struct.field(UInt64, {array: true}) - required_nft_action_ids!: UInt64[] + declare required_nft_action_ids: UInt64[] } @Struct.type('offer.clean') export class offerclean extends Struct {} @Struct.type('offer.rm') export class offerrm extends Struct { @Struct.field(UInt64) - offer_id!: UInt64 + declare offer_id: UInt64 } @Struct.type('owner.add') export class owneradd extends Struct { @Struct.field(Name) - boid_id!: Name + declare boid_id: Name @Struct.field(Name) - owner!: Name + declare owner: Name } @Struct.type('owner.rm') export class ownerrm extends Struct { @Struct.field(Name) - boid_id!: Name + declare boid_id: Name @Struct.field(Name) - owner!: Name + declare owner: Name } @Struct.type('power.add') export class poweradd extends Struct { @Struct.field(Name) - boid_id!: Name + declare boid_id: Name @Struct.field(UInt16) - power!: UInt16 + declare power: UInt16 } @Struct.type('power.claim') export class powerclaim extends Struct { @Struct.field(Name) - boid_id!: Name + declare boid_id: Name } @Struct.type('rmdelegstake') export class rmdelegstake extends Struct { @Struct.field(UInt64) - stake_id!: UInt64 + declare stake_id: UInt64 } @Struct.type('sponsor.rm') export class sponsorrm extends Struct { @Struct.field(Name) - sponsor_boid_id!: Name + declare sponsor_boid_id: Name } @Struct.type('sponsor.set') export class sponsorset extends Struct { @Struct.field(Sponsor) - row!: Sponsor + declare row: Sponsor } @Struct.type('stake') export class stake extends Struct { @Struct.field(Name) - boid_id!: Name + declare boid_id: Name @Struct.field(UInt32) - quantity!: UInt32 + declare quantity: UInt32 } @Struct.type('stake.deleg') export class stakedeleg extends Struct { @Struct.field(Name) - from_boid_id!: Name + declare from_boid_id: Name @Struct.field(Name) - to_boid_id!: Name + declare to_boid_id: Name @Struct.field(UInt16) - stake_quantity!: UInt16 + declare stake_quantity: UInt16 @Struct.field(UInt16) - lock_until_round!: UInt16 + declare lock_until_round: UInt16 } @Struct.type('team.change') export class teamchange extends Struct { @Struct.field(Name) - boid_id!: Name + declare boid_id: Name @Struct.field(UInt8) - new_team_id!: UInt8 + declare new_team_id: UInt8 @Struct.field(UInt8) - new_pwr_tax_mult!: UInt8 + declare new_pwr_tax_mult: UInt8 } @Struct.type('team.create') export class teamcreate extends Struct { @Struct.field(Name) - owner!: Name + declare owner: Name @Struct.field(UInt8) - min_pwr_tax_mult!: UInt8 + declare min_pwr_tax_mult: UInt8 @Struct.field(UInt8) - owner_cut_mult!: UInt8 + declare owner_cut_mult: UInt8 @Struct.field('string') - url_safe_name!: string + declare url_safe_name: string } @Struct.type('team.edit') export class teamedit extends Struct { @Struct.field(UInt8) - team_id!: UInt8 + declare team_id: UInt8 @Struct.field(Name) - owner!: Name + declare owner: Name @Struct.field(Name, {array: true}) - managers!: Name[] + declare managers: Name[] @Struct.field(UInt8) - min_pwr_tax_mult!: UInt8 + declare min_pwr_tax_mult: UInt8 @Struct.field(UInt8) - owner_cut_mult!: UInt8 + declare owner_cut_mult: UInt8 @Struct.field('string') - url_safe_name!: string + declare url_safe_name: string @Struct.field(Bytes) - meta!: Bytes + declare meta: Bytes } @Struct.type('team.rm') export class teamrm extends Struct { @Struct.field(UInt8) - team_id!: UInt8 + declare team_id: UInt8 } @Struct.type('team.setmem') export class teamsetmem extends Struct { @Struct.field(UInt8) - team_id!: UInt8 + declare team_id: UInt8 @Struct.field(UInt32) - new_members!: UInt32 + declare new_members: UInt32 } @Struct.type('team.setpwr') export class teamsetpwr extends Struct { @Struct.field(UInt8) - team_id!: UInt8 + declare team_id: UInt8 @Struct.field(UInt32) - new_power!: UInt32 + declare new_power: UInt32 } @Struct.type('team.taxrate') export class teamtaxrate extends Struct { @Struct.field(Name) - boid_id!: Name + declare boid_id: Name @Struct.field(UInt8) - new_pwr_tax_mult!: UInt8 + declare new_pwr_tax_mult: UInt8 } @Struct.type('thisround') export class thisround extends Struct {} @Struct.type('unstake.end') export class unstakeend extends Struct { @Struct.field(Name) - boid_id!: Name + declare boid_id: Name } @Struct.type('unstake.init') export class unstakeinit extends Struct { @Struct.field(Name) - boid_id!: Name + declare boid_id: Name @Struct.field(UInt32) - quantity!: UInt32 + declare quantity: UInt32 } @Struct.type('unstake.stop') export class unstakestop extends Struct { @Struct.field(Name) - boid_id!: Name + declare boid_id: Name } @Struct.type('unstke.deleg') export class unstkedeleg extends Struct { @Struct.field(UInt64) - stake_id!: UInt64 + declare stake_id: UInt64 } @Struct.type('withdraw') export class withdraw extends Struct { @Struct.field(Name) - boid_id!: Name + declare boid_id: Name @Struct.field(UInt32) - quantity!: UInt32 + declare quantity: UInt32 @Struct.field(Name) - to!: Name + declare to: Name } } export const TableMap = { diff --git a/test/data/contracts/mock-eosio.msig.ts b/test/data/contracts/mock-eosio.msig.ts index af87899..f8ee3b4 100644 --- a/test/data/contracts/mock-eosio.msig.ts +++ b/test/data/contracts/mock-eosio.msig.ts @@ -23,148 +23,148 @@ export namespace Types { @Struct.type('permission_level') export class permission_level extends Struct { @Struct.field(Name) - actor!: Name + declare actor: Name @Struct.field(Name) - permission!: Name + declare permission: Name } @Struct.type('action') export class action extends Struct { @Struct.field(Name) - account!: Name + declare account: Name @Struct.field(Name) - name!: Name + declare name: Name @Struct.field(permission_level, {array: true}) - authorization!: permission_level[] + declare authorization: permission_level[] @Struct.field(Bytes) - data!: Bytes + declare data: Bytes } @Struct.type('approval') export class approval extends Struct { @Struct.field(permission_level) - level!: permission_level + declare level: permission_level @Struct.field(TimePoint) - time!: TimePoint + declare time: TimePoint } @Struct.type('approvals_info') export class approvals_info extends Struct { @Struct.field(UInt8) - version!: UInt8 + declare version: UInt8 @Struct.field(Name) - proposal_name!: Name + declare proposal_name: Name @Struct.field(approval, {array: true}) - requested_approvals!: approval[] + declare requested_approvals: approval[] @Struct.field(approval, {array: true}) - provided_approvals!: approval[] + declare provided_approvals: approval[] } @Struct.type('approve') export class approve extends Struct { @Struct.field(Name) - proposer!: Name + declare proposer: Name @Struct.field(Name) - proposal_name!: Name + declare proposal_name: Name @Struct.field(permission_level) - level!: permission_level + declare level: permission_level @Struct.field(Checksum256, {optional: true}) - proposal_hash?: Checksum256 + declare proposal_hash?: Checksum256 } @Struct.type('cancel') export class cancel extends Struct { @Struct.field(Name) - proposer!: Name + declare proposer: Name @Struct.field(Name) - proposal_name!: Name + declare proposal_name: Name @Struct.field(Name) - canceler!: Name + declare canceler: Name } @Struct.type('exec') export class exec extends Struct { @Struct.field(Name) - proposer!: Name + declare proposer: Name @Struct.field(Name) - proposal_name!: Name + declare proposal_name: Name @Struct.field(Name) - executer!: Name + declare executer: Name } @Struct.type('extension') export class extension extends Struct { @Struct.field(UInt16) - type!: UInt16 + declare type: UInt16 @Struct.field(Bytes) - data!: Bytes + declare data: Bytes } @Struct.type('invalidate') export class invalidate extends Struct { @Struct.field(Name) - account!: Name + declare account: Name } @Struct.type('invalidation') export class invalidation extends Struct { @Struct.field(Name) - account!: Name + declare account: Name @Struct.field(TimePoint) - last_invalidation_time!: TimePoint + declare last_invalidation_time: TimePoint } @Struct.type('old_approvals_info') export class old_approvals_info extends Struct { @Struct.field(Name) - proposal_name!: Name + declare proposal_name: Name @Struct.field(permission_level, {array: true}) - requested_approvals!: permission_level[] + declare requested_approvals: permission_level[] @Struct.field(permission_level, {array: true}) - provided_approvals!: permission_level[] + declare provided_approvals: permission_level[] } @Struct.type('proposal') export class proposal extends Struct { @Struct.field(Name) - proposal_name!: Name + declare proposal_name: Name @Struct.field(Bytes) - packed_transaction!: Bytes + declare packed_transaction: Bytes @Struct.field(TimePoint, {optional: true}) - earliest_exec_time?: TimePoint + declare earliest_exec_time?: TimePoint } @Struct.type('transaction_header') export class transaction_header extends Struct { @Struct.field(TimePointSec) - expiration!: TimePointSec + declare expiration: TimePointSec @Struct.field(UInt16) - ref_block_num!: UInt16 + declare ref_block_num: UInt16 @Struct.field(UInt32) - ref_block_prefix!: UInt32 + declare ref_block_prefix: UInt32 @Struct.field(VarUInt) - max_net_usage_words!: VarUInt + declare max_net_usage_words: VarUInt @Struct.field(UInt8) - max_cpu_usage_ms!: UInt8 + declare max_cpu_usage_ms: UInt8 @Struct.field(VarUInt) - delay_sec!: VarUInt + declare delay_sec: VarUInt } @Struct.type('transaction') export class transaction extends transaction_header { @Struct.field(action, {array: true}) - context_free_actions!: action[] + declare context_free_actions: action[] @Struct.field(action, {array: true}) - actions!: action[] + declare actions: action[] @Struct.field(extension, {array: true}) - transaction_extensions!: extension[] + declare transaction_extensions: extension[] } @Struct.type('propose') export class propose extends Struct { @Struct.field(Name) - proposer!: Name + declare proposer: Name @Struct.field(Name) - proposal_name!: Name + declare proposal_name: Name @Struct.field(permission_level, {array: true}) - requested!: permission_level[] + declare requested: permission_level[] @Struct.field(transaction) - trx!: transaction + declare trx: transaction } @Struct.type('unapprove') export class unapprove extends Struct { @Struct.field(Name) - proposer!: Name + declare proposer: Name @Struct.field(Name) - proposal_name!: Name + declare proposal_name: Name @Struct.field(permission_level) - level!: permission_level + declare level: permission_level } } export const TableMap = { diff --git a/test/data/contracts/mock-eosio.token.ts b/test/data/contracts/mock-eosio.token.ts index a7c9c0d..7157524 100644 --- a/test/data/contracts/mock-eosio.token.ts +++ b/test/data/contracts/mock-eosio.token.ts @@ -10,66 +10,66 @@ export namespace Types { @Struct.type('account') export class account extends Struct { @Struct.field(Asset) - balance!: Asset + declare balance: Asset } @Struct.type('close') export class close extends Struct { @Struct.field(Name) - owner!: Name + declare owner: Name @Struct.field(Asset.Symbol) - symbol!: Asset.Symbol + declare symbol: Asset.Symbol } @Struct.type('create') export class create extends Struct { @Struct.field(Name) - issuer!: Name + declare issuer: Name @Struct.field(Asset) - maximum_supply!: Asset + declare maximum_supply: Asset } @Struct.type('currency_stats') export class currency_stats extends Struct { @Struct.field(Asset) - supply!: Asset + declare supply: Asset @Struct.field(Asset) - max_supply!: Asset + declare max_supply: Asset @Struct.field(Name) - issuer!: Name + declare issuer: Name } @Struct.type('issue') export class issue extends Struct { @Struct.field(Name) - to!: Name + declare to: Name @Struct.field(Asset) - quantity!: Asset + declare quantity: Asset @Struct.field('string') - memo!: string + declare memo: string } @Struct.type('open') export class open extends Struct { @Struct.field(Name) - owner!: Name + declare owner: Name @Struct.field(Asset.Symbol) - symbol!: Asset.Symbol + declare symbol: Asset.Symbol @Struct.field(Name) - ram_payer!: Name + declare ram_payer: Name } @Struct.type('retire') export class retire extends Struct { @Struct.field(Asset) - quantity!: Asset + declare quantity: Asset @Struct.field('string') - memo!: string + declare memo: string } @Struct.type('transfer') export class transfer extends Struct { @Struct.field(Name) - from!: Name + declare from: Name @Struct.field(Name) - to!: Name + declare to: Name @Struct.field(Asset) - quantity!: Asset + declare quantity: Asset @Struct.field('string') - memo!: string + declare memo: string } } export const TableMap = { diff --git a/test/data/contracts/mock-eosio.ts b/test/data/contracts/mock-eosio.ts index 9002bcb..c17074c 100644 --- a/test/data/contracts/mock-eosio.ts +++ b/test/data/contracts/mock-eosio.ts @@ -46,16 +46,16 @@ export namespace Types { @Struct.type('key_weight') export class key_weight extends Struct { @Struct.field(PublicKey) - key!: PublicKey + declare key: PublicKey @Struct.field(UInt16) - weight!: UInt16 + declare weight: UInt16 } @Struct.type('block_signing_authority_v0') export class block_signing_authority_v0 extends Struct { @Struct.field(UInt32) - threshold!: UInt32 + declare threshold: UInt32 @Struct.field(key_weight, {array: true}) - keys!: key_weight[] + declare keys: key_weight[] } @Variant.type('variant_block_signing_authority_v0', [block_signing_authority_v0]) export class variant_block_signing_authority_v0 extends Variant { @@ -64,1005 +64,1005 @@ export namespace Types { @Struct.type('abi_hash') export class abi_hash extends Struct { @Struct.field(Name) - owner!: Name + declare owner: Name @Struct.field(Checksum256) - hash!: Checksum256 + declare hash: Checksum256 } @Struct.type('activate') export class activate extends Struct { @Struct.field(Checksum256) - feature_digest!: Checksum256 + declare feature_digest: Checksum256 } @Struct.type('permission_level') export class permission_level extends Struct { @Struct.field(Name) - actor!: Name + declare actor: Name @Struct.field(Name) - permission!: Name + declare permission: Name } @Struct.type('permission_level_weight') export class permission_level_weight extends Struct { @Struct.field(permission_level) - permission!: permission_level + declare permission: permission_level @Struct.field(UInt16) - weight!: UInt16 + declare weight: UInt16 } @Struct.type('wait_weight') export class wait_weight extends Struct { @Struct.field(UInt32) - wait_sec!: UInt32 + declare wait_sec: UInt32 @Struct.field(UInt16) - weight!: UInt16 + declare weight: UInt16 } @Struct.type('authority') export class authority extends Struct { @Struct.field(UInt32) - threshold!: UInt32 + declare threshold: UInt32 @Struct.field(key_weight, {array: true}) - keys!: key_weight[] + declare keys: key_weight[] @Struct.field(permission_level_weight, {array: true}) - accounts!: permission_level_weight[] + declare accounts: permission_level_weight[] @Struct.field(wait_weight, {array: true}) - waits!: wait_weight[] + declare waits: wait_weight[] } @Struct.type('bid_refund') export class bid_refund extends Struct { @Struct.field(Name) - bidder!: Name + declare bidder: Name @Struct.field(Asset) - amount!: Asset + declare amount: Asset } @Struct.type('bidname') export class bidname extends Struct { @Struct.field(Name) - bidder!: Name + declare bidder: Name @Struct.field(Name) - newname!: Name + declare newname: Name @Struct.field(Asset) - bid!: Asset + declare bid: Asset } @Struct.type('bidrefund') export class bidrefund extends Struct { @Struct.field(Name) - bidder!: Name + declare bidder: Name @Struct.field(Name) - newname!: Name + declare newname: Name } @Struct.type('producer_key') export class producer_key extends Struct { @Struct.field(Name) - producer_name!: Name + declare producer_name: Name @Struct.field(PublicKey) - block_signing_key!: PublicKey + declare block_signing_key: PublicKey } @Struct.type('producer_schedule') export class producer_schedule extends Struct { @Struct.field(UInt32) - version!: UInt32 + declare version: UInt32 @Struct.field(producer_key, {array: true}) - producers!: producer_key[] + declare producers: producer_key[] } @Struct.type('block_header') export class block_header extends Struct { @Struct.field(UInt32) - timestamp!: UInt32 + declare timestamp: UInt32 @Struct.field(Name) - producer!: Name + declare producer: Name @Struct.field(UInt16) - confirmed!: UInt16 + declare confirmed: UInt16 @Struct.field(Checksum256) - previous!: Checksum256 + declare previous: Checksum256 @Struct.field(Checksum256) - transaction_mroot!: Checksum256 + declare transaction_mroot: Checksum256 @Struct.field(Checksum256) - action_mroot!: Checksum256 + declare action_mroot: Checksum256 @Struct.field(UInt32) - schedule_version!: UInt32 + declare schedule_version: UInt32 @Struct.field(producer_schedule, {optional: true}) - new_producers?: producer_schedule + declare new_producers?: producer_schedule } @Struct.type('block_info_record') export class block_info_record extends Struct { @Struct.field(UInt8) - version!: UInt8 + declare version: UInt8 @Struct.field(UInt32) - block_height!: UInt32 + declare block_height: UInt32 @Struct.field(TimePoint) - block_timestamp!: TimePoint + declare block_timestamp: TimePoint } @Struct.type('blockchain_parameters') export class blockchain_parameters extends Struct { @Struct.field(UInt64) - max_block_net_usage!: UInt64 + declare max_block_net_usage: UInt64 @Struct.field(UInt32) - target_block_net_usage_pct!: UInt32 + declare target_block_net_usage_pct: UInt32 @Struct.field(UInt32) - max_transaction_net_usage!: UInt32 + declare max_transaction_net_usage: UInt32 @Struct.field(UInt32) - base_per_transaction_net_usage!: UInt32 + declare base_per_transaction_net_usage: UInt32 @Struct.field(UInt32) - net_usage_leeway!: UInt32 + declare net_usage_leeway: UInt32 @Struct.field(UInt32) - context_free_discount_net_usage_num!: UInt32 + declare context_free_discount_net_usage_num: UInt32 @Struct.field(UInt32) - context_free_discount_net_usage_den!: UInt32 + declare context_free_discount_net_usage_den: UInt32 @Struct.field(UInt32) - max_block_cpu_usage!: UInt32 + declare max_block_cpu_usage: UInt32 @Struct.field(UInt32) - target_block_cpu_usage_pct!: UInt32 + declare target_block_cpu_usage_pct: UInt32 @Struct.field(UInt32) - max_transaction_cpu_usage!: UInt32 + declare max_transaction_cpu_usage: UInt32 @Struct.field(UInt32) - min_transaction_cpu_usage!: UInt32 + declare min_transaction_cpu_usage: UInt32 @Struct.field(UInt32) - max_transaction_lifetime!: UInt32 + declare max_transaction_lifetime: UInt32 @Struct.field(UInt32) - deferred_trx_expiration_window!: UInt32 + declare deferred_trx_expiration_window: UInt32 @Struct.field(UInt32) - max_transaction_delay!: UInt32 + declare max_transaction_delay: UInt32 @Struct.field(UInt32) - max_inline_action_size!: UInt32 + declare max_inline_action_size: UInt32 @Struct.field(UInt16) - max_inline_action_depth!: UInt16 + declare max_inline_action_depth: UInt16 @Struct.field(UInt16) - max_authority_depth!: UInt16 + declare max_authority_depth: UInt16 } @Struct.type('blockchain_parameters_v1') export class blockchain_parameters_v1 extends blockchain_parameters { @Struct.field(UInt32, {optional: true}) - max_action_return_value_size?: UInt32 + declare max_action_return_value_size?: UInt32 } @Struct.type('buyram') export class buyram extends Struct { @Struct.field(Name) - payer!: Name + declare payer: Name @Struct.field(Name) - receiver!: Name + declare receiver: Name @Struct.field(Asset) - quant!: Asset + declare quant: Asset } @Struct.type('buyrambytes') export class buyrambytes extends Struct { @Struct.field(Name) - payer!: Name + declare payer: Name @Struct.field(Name) - receiver!: Name + declare receiver: Name @Struct.field(UInt32) - bytes!: UInt32 + declare bytes: UInt32 } @Struct.type('buyrex') export class buyrex extends Struct { @Struct.field(Name) - from!: Name + declare from: Name @Struct.field(Asset) - amount!: Asset + declare amount: Asset } @Struct.type('canceldelay') export class canceldelay extends Struct { @Struct.field(permission_level) - canceling_auth!: permission_level + declare canceling_auth: permission_level @Struct.field(Checksum256) - trx_id!: Checksum256 + declare trx_id: Checksum256 } @Struct.type('powerup_config_resource') export class powerup_config_resource extends Struct { @Struct.field(Int64, {optional: true}) - current_weight_ratio?: Int64 + declare current_weight_ratio?: Int64 @Struct.field(Int64, {optional: true}) - target_weight_ratio?: Int64 + declare target_weight_ratio?: Int64 @Struct.field(Int64, {optional: true}) - assumed_stake_weight?: Int64 + declare assumed_stake_weight?: Int64 @Struct.field(TimePointSec, {optional: true}) - target_timestamp?: TimePointSec + declare target_timestamp?: TimePointSec @Struct.field(Float64, {optional: true}) - exponent?: Float64 + declare exponent?: Float64 @Struct.field(UInt32, {optional: true}) - decay_secs?: UInt32 + declare decay_secs?: UInt32 @Struct.field(Asset, {optional: true}) - min_price?: Asset + declare min_price?: Asset @Struct.field(Asset, {optional: true}) - max_price?: Asset + declare max_price?: Asset } @Struct.type('powerup_config') export class powerup_config extends Struct { @Struct.field(powerup_config_resource) - net!: powerup_config_resource + declare net: powerup_config_resource @Struct.field(powerup_config_resource) - cpu!: powerup_config_resource + declare cpu: powerup_config_resource @Struct.field(UInt32, {optional: true}) - powerup_days?: UInt32 + declare powerup_days?: UInt32 @Struct.field(Asset, {optional: true}) - min_powerup_fee?: Asset + declare min_powerup_fee?: Asset } @Struct.type('cfgpowerup') export class cfgpowerup extends Struct { @Struct.field(powerup_config) - args!: powerup_config + declare args: powerup_config } @Struct.type('claimrewards') export class claimrewards extends Struct { @Struct.field(Name) - owner!: Name + declare owner: Name } @Struct.type('closerex') export class closerex extends Struct { @Struct.field(Name) - owner!: Name + declare owner: Name } @Struct.type('cnclrexorder') export class cnclrexorder extends Struct { @Struct.field(Name) - owner!: Name + declare owner: Name } @Struct.type('connector') export class connector extends Struct { @Struct.field(Asset) - balance!: Asset + declare balance: Asset @Struct.field(Float64) - weight!: Float64 + declare weight: Float64 } @Struct.type('consolidate') export class consolidate extends Struct { @Struct.field(Name) - owner!: Name + declare owner: Name } @Struct.type('defcpuloan') export class defcpuloan extends Struct { @Struct.field(Name) - from!: Name + declare from: Name @Struct.field(UInt64) - loan_num!: UInt64 + declare loan_num: UInt64 @Struct.field(Asset) - amount!: Asset + declare amount: Asset } @Struct.type('defnetloan') export class defnetloan extends Struct { @Struct.field(Name) - from!: Name + declare from: Name @Struct.field(UInt64) - loan_num!: UInt64 + declare loan_num: UInt64 @Struct.field(Asset) - amount!: Asset + declare amount: Asset } @Struct.type('delegatebw') export class delegatebw extends Struct { @Struct.field(Name) - from!: Name + declare from: Name @Struct.field(Name) - receiver!: Name + declare receiver: Name @Struct.field(Asset) - stake_net_quantity!: Asset + declare stake_net_quantity: Asset @Struct.field(Asset) - stake_cpu_quantity!: Asset + declare stake_cpu_quantity: Asset @Struct.field('bool') - transfer!: boolean + declare transfer: boolean } @Struct.type('delegated_bandwidth') export class delegated_bandwidth extends Struct { @Struct.field(Name) - from!: Name + declare from: Name @Struct.field(Name) - to!: Name + declare to: Name @Struct.field(Asset) - net_weight!: Asset + declare net_weight: Asset @Struct.field(Asset) - cpu_weight!: Asset + declare cpu_weight: Asset } @Struct.type('deleteauth') export class deleteauth extends Struct { @Struct.field(Name) - account!: Name + declare account: Name @Struct.field(Name) - permission!: Name + declare permission: Name @Struct.field(Name, {optional: true}) - authorized_by?: Name + declare authorized_by?: Name } @Struct.type('deposit') export class deposit extends Struct { @Struct.field(Name) - owner!: Name + declare owner: Name @Struct.field(Asset) - amount!: Asset + declare amount: Asset } @Struct.type('eosio_global_state') export class eosio_global_state extends blockchain_parameters { @Struct.field(UInt64) - max_ram_size!: UInt64 + declare max_ram_size: UInt64 @Struct.field(UInt64) - total_ram_bytes_reserved!: UInt64 + declare total_ram_bytes_reserved: UInt64 @Struct.field(Int64) - total_ram_stake!: Int64 + declare total_ram_stake: Int64 @Struct.field(BlockTimestamp) - last_producer_schedule_update!: BlockTimestamp + declare last_producer_schedule_update: BlockTimestamp @Struct.field(TimePoint) - last_pervote_bucket_fill!: TimePoint + declare last_pervote_bucket_fill: TimePoint @Struct.field(Int64) - pervote_bucket!: Int64 + declare pervote_bucket: Int64 @Struct.field(Int64) - perblock_bucket!: Int64 + declare perblock_bucket: Int64 @Struct.field(UInt32) - total_unpaid_blocks!: UInt32 + declare total_unpaid_blocks: UInt32 @Struct.field(Int64) - total_activated_stake!: Int64 + declare total_activated_stake: Int64 @Struct.field(TimePoint) - thresh_activated_stake_time!: TimePoint + declare thresh_activated_stake_time: TimePoint @Struct.field(UInt16) - last_producer_schedule_size!: UInt16 + declare last_producer_schedule_size: UInt16 @Struct.field(Float64) - total_producer_vote_weight!: Float64 + declare total_producer_vote_weight: Float64 @Struct.field(BlockTimestamp) - last_name_close!: BlockTimestamp + declare last_name_close: BlockTimestamp } @Struct.type('eosio_global_state2') export class eosio_global_state2 extends Struct { @Struct.field(UInt16) - new_ram_per_block!: UInt16 + declare new_ram_per_block: UInt16 @Struct.field(BlockTimestamp) - last_ram_increase!: BlockTimestamp + declare last_ram_increase: BlockTimestamp @Struct.field(BlockTimestamp) - last_block_num!: BlockTimestamp + declare last_block_num: BlockTimestamp @Struct.field(Float64) - total_producer_votepay_share!: Float64 + declare total_producer_votepay_share: Float64 @Struct.field(UInt8) - revision!: UInt8 + declare revision: UInt8 } @Struct.type('eosio_global_state3') export class eosio_global_state3 extends Struct { @Struct.field(TimePoint) - last_vpay_state_update!: TimePoint + declare last_vpay_state_update: TimePoint @Struct.field(Float64) - total_vpay_share_change_rate!: Float64 + declare total_vpay_share_change_rate: Float64 } @Struct.type('eosio_global_state4') export class eosio_global_state4 extends Struct { @Struct.field(Float64) - continuous_rate!: Float64 + declare continuous_rate: Float64 @Struct.field(Int64) - inflation_pay_factor!: Int64 + declare inflation_pay_factor: Int64 @Struct.field(Int64) - votepay_factor!: Int64 + declare votepay_factor: Int64 } @Struct.type('exchange_state') export class exchange_state extends Struct { @Struct.field(Asset) - supply!: Asset + declare supply: Asset @Struct.field(connector) - base!: connector + declare base: connector @Struct.field(connector) - quote!: connector + declare quote: connector } @Struct.type('fundcpuloan') export class fundcpuloan extends Struct { @Struct.field(Name) - from!: Name + declare from: Name @Struct.field(UInt64) - loan_num!: UInt64 + declare loan_num: UInt64 @Struct.field(Asset) - payment!: Asset + declare payment: Asset } @Struct.type('fundnetloan') export class fundnetloan extends Struct { @Struct.field(Name) - from!: Name + declare from: Name @Struct.field(UInt64) - loan_num!: UInt64 + declare loan_num: UInt64 @Struct.field(Asset) - payment!: Asset + declare payment: Asset } @Struct.type('init') export class init extends Struct { @Struct.field(VarUInt) - version!: VarUInt + declare version: VarUInt @Struct.field(Asset.Symbol) - core!: Asset.Symbol + declare core: Asset.Symbol } @Struct.type('limitauthchg') export class limitauthchg extends Struct { @Struct.field(Name) - account!: Name + declare account: Name @Struct.field(Name, {array: true}) - allow_perms!: Name[] + declare allow_perms: Name[] @Struct.field(Name, {array: true}) - disallow_perms!: Name[] + declare disallow_perms: Name[] } @Struct.type('linkauth') export class linkauth extends Struct { @Struct.field(Name) - account!: Name + declare account: Name @Struct.field(Name) - code!: Name + declare code: Name @Struct.field(Name) - type!: Name + declare type: Name @Struct.field(Name) - requirement!: Name + declare requirement: Name @Struct.field(Name, {optional: true}) - authorized_by?: Name + declare authorized_by?: Name } @Struct.type('mvfrsavings') export class mvfrsavings extends Struct { @Struct.field(Name) - owner!: Name + declare owner: Name @Struct.field(Asset) - rex!: Asset + declare rex: Asset } @Struct.type('mvtosavings') export class mvtosavings extends Struct { @Struct.field(Name) - owner!: Name + declare owner: Name @Struct.field(Asset) - rex!: Asset + declare rex: Asset } @Struct.type('name_bid') export class name_bid extends Struct { @Struct.field(Name) - newname!: Name + declare newname: Name @Struct.field(Name) - high_bidder!: Name + declare high_bidder: Name @Struct.field(Int64) - high_bid!: Int64 + declare high_bid: Int64 @Struct.field(TimePoint) - last_bid_time!: TimePoint + declare last_bid_time: TimePoint } @Struct.type('newaccount') export class newaccount extends Struct { @Struct.field(Name) - creator!: Name + declare creator: Name @Struct.field(Name) - name!: Name + declare name: Name @Struct.field(authority) - owner!: authority + declare owner: authority @Struct.field(authority) - active!: authority + declare active: authority } @Struct.type('onblock') export class onblock extends Struct { @Struct.field(block_header) - header!: block_header + declare header: block_header } @Struct.type('onerror') export class onerror extends Struct { @Struct.field(UInt128) - sender_id!: UInt128 + declare sender_id: UInt128 @Struct.field(Bytes) - sent_trx!: Bytes + declare sent_trx: Bytes } @Struct.type('pair_time_point_sec_int64') export class pair_time_point_sec_int64 extends Struct { @Struct.field(TimePointSec) - first!: TimePointSec + declare first: TimePointSec @Struct.field(Int64) - second!: Int64 + declare second: Int64 } @Struct.type('powerup') export class powerup extends Struct { @Struct.field(Name) - payer!: Name + declare payer: Name @Struct.field(Name) - receiver!: Name + declare receiver: Name @Struct.field(UInt32) - days!: UInt32 + declare days: UInt32 @Struct.field(Int64) - net_frac!: Int64 + declare net_frac: Int64 @Struct.field(Int64) - cpu_frac!: Int64 + declare cpu_frac: Int64 @Struct.field(Asset) - max_payment!: Asset + declare max_payment: Asset } @Struct.type('powerup_order') export class powerup_order extends Struct { @Struct.field(UInt8) - version!: UInt8 + declare version: UInt8 @Struct.field(UInt64) - id!: UInt64 + declare id: UInt64 @Struct.field(Name) - owner!: Name + declare owner: Name @Struct.field(Int64) - net_weight!: Int64 + declare net_weight: Int64 @Struct.field(Int64) - cpu_weight!: Int64 + declare cpu_weight: Int64 @Struct.field(TimePointSec) - expires!: TimePointSec + declare expires: TimePointSec } @Struct.type('powerup_state_resource') export class powerup_state_resource extends Struct { @Struct.field(UInt8) - version!: UInt8 + declare version: UInt8 @Struct.field(Int64) - weight!: Int64 + declare weight: Int64 @Struct.field(Int64) - weight_ratio!: Int64 + declare weight_ratio: Int64 @Struct.field(Int64) - assumed_stake_weight!: Int64 + declare assumed_stake_weight: Int64 @Struct.field(Int64) - initial_weight_ratio!: Int64 + declare initial_weight_ratio: Int64 @Struct.field(Int64) - target_weight_ratio!: Int64 + declare target_weight_ratio: Int64 @Struct.field(TimePointSec) - initial_timestamp!: TimePointSec + declare initial_timestamp: TimePointSec @Struct.field(TimePointSec) - target_timestamp!: TimePointSec + declare target_timestamp: TimePointSec @Struct.field(Float64) - exponent!: Float64 + declare exponent: Float64 @Struct.field(UInt32) - decay_secs!: UInt32 + declare decay_secs: UInt32 @Struct.field(Asset) - min_price!: Asset + declare min_price: Asset @Struct.field(Asset) - max_price!: Asset + declare max_price: Asset @Struct.field(Int64) - utilization!: Int64 + declare utilization: Int64 @Struct.field(Int64) - adjusted_utilization!: Int64 + declare adjusted_utilization: Int64 @Struct.field(TimePointSec) - utilization_timestamp!: TimePointSec + declare utilization_timestamp: TimePointSec } @Struct.type('powerup_state') export class powerup_state extends Struct { @Struct.field(UInt8) - version!: UInt8 + declare version: UInt8 @Struct.field(powerup_state_resource) - net!: powerup_state_resource + declare net: powerup_state_resource @Struct.field(powerup_state_resource) - cpu!: powerup_state_resource + declare cpu: powerup_state_resource @Struct.field(UInt32) - powerup_days!: UInt32 + declare powerup_days: UInt32 @Struct.field(Asset) - min_powerup_fee!: Asset + declare min_powerup_fee: Asset } @Struct.type('powerupexec') export class powerupexec extends Struct { @Struct.field(Name) - user!: Name + declare user: Name @Struct.field(UInt16) - max!: UInt16 + declare max: UInt16 } @Struct.type('producer_info') export class producer_info extends Struct { @Struct.field(Name) - owner!: Name + declare owner: Name @Struct.field(Float64) - total_votes!: Float64 + declare total_votes: Float64 @Struct.field(PublicKey) - producer_key!: PublicKey + declare producer_key: PublicKey @Struct.field('bool') - is_active!: boolean + declare is_active: boolean @Struct.field('string') - url!: string + declare url: string @Struct.field(UInt32) - unpaid_blocks!: UInt32 + declare unpaid_blocks: UInt32 @Struct.field(TimePoint) - last_claim_time!: TimePoint + declare last_claim_time: TimePoint @Struct.field(UInt16) - location!: UInt16 + declare location: UInt16 @Struct.field(variant_block_signing_authority_v0, {optional: true}) - producer_authority?: variant_block_signing_authority_v0 + declare producer_authority?: variant_block_signing_authority_v0 } @Struct.type('producer_info2') export class producer_info2 extends Struct { @Struct.field(Name) - owner!: Name + declare owner: Name @Struct.field(Float64) - votepay_share!: Float64 + declare votepay_share: Float64 @Struct.field(TimePoint) - last_votepay_share_update!: TimePoint + declare last_votepay_share_update: TimePoint } @Struct.type('refund') export class refund extends Struct { @Struct.field(Name) - owner!: Name + declare owner: Name } @Struct.type('refund_request') export class refund_request extends Struct { @Struct.field(Name) - owner!: Name + declare owner: Name @Struct.field(TimePointSec) - request_time!: TimePointSec + declare request_time: TimePointSec @Struct.field(Asset) - net_amount!: Asset + declare net_amount: Asset @Struct.field(Asset) - cpu_amount!: Asset + declare cpu_amount: Asset } @Struct.type('regproducer') export class regproducer extends Struct { @Struct.field(Name) - producer!: Name + declare producer: Name @Struct.field(PublicKey) - producer_key!: PublicKey + declare producer_key: PublicKey @Struct.field('string') - url!: string + declare url: string @Struct.field(UInt16) - location!: UInt16 + declare location: UInt16 } @Struct.type('regproducer2') export class regproducer2 extends Struct { @Struct.field(Name) - producer!: Name + declare producer: Name @Struct.field(variant_block_signing_authority_v0) - producer_authority!: variant_block_signing_authority_v0 + declare producer_authority: variant_block_signing_authority_v0 @Struct.field('string') - url!: string + declare url: string @Struct.field(UInt16) - location!: UInt16 + declare location: UInt16 } @Struct.type('regproxy') export class regproxy extends Struct { @Struct.field(Name) - proxy!: Name + declare proxy: Name @Struct.field('bool') - isproxy!: boolean + declare isproxy: boolean } @Struct.type('rentcpu') export class rentcpu extends Struct { @Struct.field(Name) - from!: Name + declare from: Name @Struct.field(Name) - receiver!: Name + declare receiver: Name @Struct.field(Asset) - loan_payment!: Asset + declare loan_payment: Asset @Struct.field(Asset) - loan_fund!: Asset + declare loan_fund: Asset } @Struct.type('rentnet') export class rentnet extends Struct { @Struct.field(Name) - from!: Name + declare from: Name @Struct.field(Name) - receiver!: Name + declare receiver: Name @Struct.field(Asset) - loan_payment!: Asset + declare loan_payment: Asset @Struct.field(Asset) - loan_fund!: Asset + declare loan_fund: Asset } @Struct.type('rex_balance') export class rex_balance extends Struct { @Struct.field(UInt8) - version!: UInt8 + declare version: UInt8 @Struct.field(Name) - owner!: Name + declare owner: Name @Struct.field(Asset) - vote_stake!: Asset + declare vote_stake: Asset @Struct.field(Asset) - rex_balance!: Asset + declare rex_balance: Asset @Struct.field(Int64) - matured_rex!: Int64 + declare matured_rex: Int64 @Struct.field(pair_time_point_sec_int64, {array: true}) - rex_maturities!: pair_time_point_sec_int64[] + declare rex_maturities: pair_time_point_sec_int64[] } @Struct.type('rex_fund') export class rex_fund extends Struct { @Struct.field(UInt8) - version!: UInt8 + declare version: UInt8 @Struct.field(Name) - owner!: Name + declare owner: Name @Struct.field(Asset) - balance!: Asset + declare balance: Asset } @Struct.type('rex_loan') export class rex_loan extends Struct { @Struct.field(UInt8) - version!: UInt8 + declare version: UInt8 @Struct.field(Name) - from!: Name + declare from: Name @Struct.field(Name) - receiver!: Name + declare receiver: Name @Struct.field(Asset) - payment!: Asset + declare payment: Asset @Struct.field(Asset) - balance!: Asset + declare balance: Asset @Struct.field(Asset) - total_staked!: Asset + declare total_staked: Asset @Struct.field(UInt64) - loan_num!: UInt64 + declare loan_num: UInt64 @Struct.field(TimePoint) - expiration!: TimePoint + declare expiration: TimePoint } @Struct.type('rex_order') export class rex_order extends Struct { @Struct.field(UInt8) - version!: UInt8 + declare version: UInt8 @Struct.field(Name) - owner!: Name + declare owner: Name @Struct.field(Asset) - rex_requested!: Asset + declare rex_requested: Asset @Struct.field(Asset) - proceeds!: Asset + declare proceeds: Asset @Struct.field(Asset) - stake_change!: Asset + declare stake_change: Asset @Struct.field(TimePoint) - order_time!: TimePoint + declare order_time: TimePoint @Struct.field('bool') - is_open!: boolean + declare is_open: boolean } @Struct.type('rex_pool') export class rex_pool extends Struct { @Struct.field(UInt8) - version!: UInt8 + declare version: UInt8 @Struct.field(Asset) - total_lent!: Asset + declare total_lent: Asset @Struct.field(Asset) - total_unlent!: Asset + declare total_unlent: Asset @Struct.field(Asset) - total_rent!: Asset + declare total_rent: Asset @Struct.field(Asset) - total_lendable!: Asset + declare total_lendable: Asset @Struct.field(Asset) - total_rex!: Asset + declare total_rex: Asset @Struct.field(Asset) - namebid_proceeds!: Asset + declare namebid_proceeds: Asset @Struct.field(UInt64) - loan_num!: UInt64 + declare loan_num: UInt64 } @Struct.type('rex_return_buckets') export class rex_return_buckets extends Struct { @Struct.field(UInt8) - version!: UInt8 + declare version: UInt8 @Struct.field(pair_time_point_sec_int64, {array: true}) - return_buckets!: pair_time_point_sec_int64[] + declare return_buckets: pair_time_point_sec_int64[] } @Struct.type('rex_return_pool') export class rex_return_pool extends Struct { @Struct.field(UInt8) - version!: UInt8 + declare version: UInt8 @Struct.field(TimePointSec) - last_dist_time!: TimePointSec + declare last_dist_time: TimePointSec @Struct.field(TimePointSec) - pending_bucket_time!: TimePointSec + declare pending_bucket_time: TimePointSec @Struct.field(TimePointSec) - oldest_bucket_time!: TimePointSec + declare oldest_bucket_time: TimePointSec @Struct.field(Int64) - pending_bucket_proceeds!: Int64 + declare pending_bucket_proceeds: Int64 @Struct.field(Int64) - current_rate_of_increase!: Int64 + declare current_rate_of_increase: Int64 @Struct.field(Int64) - proceeds!: Int64 + declare proceeds: Int64 } @Struct.type('rexexec') export class rexexec extends Struct { @Struct.field(Name) - user!: Name + declare user: Name @Struct.field(UInt16) - max!: UInt16 + declare max: UInt16 } @Struct.type('rmvproducer') export class rmvproducer extends Struct { @Struct.field(Name) - producer!: Name + declare producer: Name } @Struct.type('sellram') export class sellram extends Struct { @Struct.field(Name) - account!: Name + declare account: Name @Struct.field(Int64) - bytes!: Int64 + declare bytes: Int64 } @Struct.type('sellrex') export class sellrex extends Struct { @Struct.field(Name) - from!: Name + declare from: Name @Struct.field(Asset) - rex!: Asset + declare rex: Asset } @Struct.type('setabi') export class setabi extends Struct { @Struct.field(Name) - account!: Name + declare account: Name @Struct.field(Bytes) - abi!: Bytes + declare abi: Bytes @Struct.field('string', {optional: true}) - memo?: string + declare memo?: string } @Struct.type('setacctcpu') export class setacctcpu extends Struct { @Struct.field(Name) - account!: Name + declare account: Name @Struct.field(Int64, {optional: true}) - cpu_weight?: Int64 + declare cpu_weight?: Int64 } @Struct.type('setacctnet') export class setacctnet extends Struct { @Struct.field(Name) - account!: Name + declare account: Name @Struct.field(Int64, {optional: true}) - net_weight?: Int64 + declare net_weight?: Int64 } @Struct.type('setacctram') export class setacctram extends Struct { @Struct.field(Name) - account!: Name + declare account: Name @Struct.field(Int64, {optional: true}) - ram_bytes?: Int64 + declare ram_bytes?: Int64 } @Struct.type('setalimits') export class setalimits extends Struct { @Struct.field(Name) - account!: Name + declare account: Name @Struct.field(Int64) - ram_bytes!: Int64 + declare ram_bytes: Int64 @Struct.field(Int64) - net_weight!: Int64 + declare net_weight: Int64 @Struct.field(Int64) - cpu_weight!: Int64 + declare cpu_weight: Int64 } @Struct.type('setcode') export class setcode extends Struct { @Struct.field(Name) - account!: Name + declare account: Name @Struct.field(UInt8) - vmtype!: UInt8 + declare vmtype: UInt8 @Struct.field(UInt8) - vmversion!: UInt8 + declare vmversion: UInt8 @Struct.field(Bytes) - code!: Bytes + declare code: Bytes @Struct.field('string', {optional: true}) - memo?: string + declare memo?: string } @Struct.type('setinflation') export class setinflation extends Struct { @Struct.field(Int64) - annual_rate!: Int64 + declare annual_rate: Int64 @Struct.field(Int64) - inflation_pay_factor!: Int64 + declare inflation_pay_factor: Int64 @Struct.field(Int64) - votepay_factor!: Int64 + declare votepay_factor: Int64 } @Struct.type('setparams') export class setparams extends Struct { @Struct.field(blockchain_parameters_v1) - params!: blockchain_parameters_v1 + declare params: blockchain_parameters_v1 } @Struct.type('setpriv') export class setpriv extends Struct { @Struct.field(Name) - account!: Name + declare account: Name @Struct.field(UInt8) - is_priv!: UInt8 + declare is_priv: UInt8 } @Struct.type('setram') export class setram extends Struct { @Struct.field(UInt64) - max_ram_size!: UInt64 + declare max_ram_size: UInt64 } @Struct.type('setramrate') export class setramrate extends Struct { @Struct.field(UInt16) - bytes_per_block!: UInt16 + declare bytes_per_block: UInt16 } @Struct.type('setrex') export class setrex extends Struct { @Struct.field(Asset) - balance!: Asset + declare balance: Asset } @Struct.type('undelegatebw') export class undelegatebw extends Struct { @Struct.field(Name) - from!: Name + declare from: Name @Struct.field(Name) - receiver!: Name + declare receiver: Name @Struct.field(Asset) - unstake_net_quantity!: Asset + declare unstake_net_quantity: Asset @Struct.field(Asset) - unstake_cpu_quantity!: Asset + declare unstake_cpu_quantity: Asset } @Struct.type('unlinkauth') export class unlinkauth extends Struct { @Struct.field(Name) - account!: Name + declare account: Name @Struct.field(Name) - code!: Name + declare code: Name @Struct.field(Name) - type!: Name + declare type: Name @Struct.field(Name, {optional: true}) - authorized_by?: Name + declare authorized_by?: Name } @Struct.type('unregprod') export class unregprod extends Struct { @Struct.field(Name) - producer!: Name + declare producer: Name } @Struct.type('unstaketorex') export class unstaketorex extends Struct { @Struct.field(Name) - owner!: Name + declare owner: Name @Struct.field(Name) - receiver!: Name + declare receiver: Name @Struct.field(Asset) - from_net!: Asset + declare from_net: Asset @Struct.field(Asset) - from_cpu!: Asset + declare from_cpu: Asset } @Struct.type('updateauth') export class updateauth extends Struct { @Struct.field(Name) - account!: Name + declare account: Name @Struct.field(Name) - permission!: Name + declare permission: Name @Struct.field(Name) - parent!: Name + declare parent: Name @Struct.field(authority) - auth!: authority + declare auth: authority @Struct.field(Name, {optional: true}) - authorized_by?: Name + declare authorized_by?: Name } @Struct.type('updaterex') export class updaterex extends Struct { @Struct.field(Name) - owner!: Name + declare owner: Name } @Struct.type('updtrevision') export class updtrevision extends Struct { @Struct.field(UInt8) - revision!: UInt8 + declare revision: UInt8 } @Struct.type('user_resources') export class user_resources extends Struct { @Struct.field(Name) - owner!: Name + declare owner: Name @Struct.field(Asset) - net_weight!: Asset + declare net_weight: Asset @Struct.field(Asset) - cpu_weight!: Asset + declare cpu_weight: Asset @Struct.field(Int64) - ram_bytes!: Int64 + declare ram_bytes: Int64 } @Struct.type('voteproducer') export class voteproducer extends Struct { @Struct.field(Name) - voter!: Name + declare voter: Name @Struct.field(Name) - proxy!: Name + declare proxy: Name @Struct.field(Name, {array: true}) - producers!: Name[] + declare producers: Name[] } @Struct.type('voter_info') export class voter_info extends Struct { @Struct.field(Name) - owner!: Name + declare owner: Name @Struct.field(Name) - proxy!: Name + declare proxy: Name @Struct.field(Name, {array: true}) - producers!: Name[] + declare producers: Name[] @Struct.field(Int64) - staked!: Int64 + declare staked: Int64 @Struct.field(Float64) - last_vote_weight!: Float64 + declare last_vote_weight: Float64 @Struct.field(Float64) - proxied_vote_weight!: Float64 + declare proxied_vote_weight: Float64 @Struct.field('bool') - is_proxy!: boolean + declare is_proxy: boolean @Struct.field(UInt32) - flags1!: UInt32 + declare flags1: UInt32 @Struct.field(UInt32) - reserved2!: UInt32 + declare reserved2: UInt32 @Struct.field(Asset) - reserved3!: Asset + declare reserved3: Asset } @Struct.type('voteupdate') export class voteupdate extends Struct { @Struct.field(Name) - voter_name!: Name + declare voter_name: Name } @Struct.type('wasmcfg') export class wasmcfg extends Struct { @Struct.field(Name) - settings!: Name + declare settings: Name } @Struct.type('withdraw') export class withdraw extends Struct { @Struct.field(Name) - owner!: Name + declare owner: Name @Struct.field(Asset) - amount!: Asset + declare amount: Asset } @Struct.type('limit_auth_change') export class limit_auth_change extends Struct { @Struct.field(UInt8) - version!: UInt8 + declare version: UInt8 @Struct.field(Name) - account!: Name + declare account: Name @Struct.field(Name, {array: true}) - allow_perms!: Name[] + declare allow_perms: Name[] @Struct.field(Name, {array: true}) - disallow_perms!: Name[] + declare disallow_perms: Name[] } } export const TableMap = { diff --git a/test/data/contracts/mock-hegemon.hgm.ts b/test/data/contracts/mock-hegemon.hgm.ts index 9e0f080..fd25197 100644 --- a/test/data/contracts/mock-hegemon.hgm.ts +++ b/test/data/contracts/mock-hegemon.hgm.ts @@ -33,646 +33,646 @@ export namespace Types { @Struct.type('addbuilding') export class addbuilding extends Struct { @Struct.field(UInt64) - gameasset_id!: UInt64 + declare gameasset_id: UInt64 @Struct.field(UInt64) - tile_id!: UInt64 + declare tile_id: UInt64 @Struct.field(Name) - owner!: Name + declare owner: Name } @Struct.type('adddeposit') export class adddeposit extends Struct { @Struct.field(UInt64) - resource_type_id!: UInt64 + declare resource_type_id: UInt64 @Struct.field(UInt64) - location_tile_id!: UInt64 + declare location_tile_id: UInt64 } @Struct.type('addfaction') export class addfaction extends Struct { @Struct.field(UInt64) - id!: UInt64 + declare id: UInt64 @Struct.field('string') - name!: string + declare name: string @Struct.field(Name) - code!: Name + declare code: Name @Struct.field('string') - flag_asset_url!: string + declare flag_asset_url: string } @Struct.type('pair_uint32_uint64') export class pair_uint32_uint64 extends Struct { @Struct.field(UInt32) - first!: UInt32 + declare first: UInt32 @Struct.field(UInt64) - second!: UInt64 + declare second: UInt64 } @Struct.type('addinventory') export class addinventory extends Struct { @Struct.field(Name) - player!: Name + declare player: Name @Struct.field(pair_uint32_uint64, {array: true}) - ingredients!: pair_uint32_uint64[] + declare ingredients: pair_uint32_uint64[] } @Struct.type('addmap') export class addmap extends Struct { @Struct.field(Name) - area_map!: Name + declare area_map: Name @Struct.field('string') - name!: string + declare name: string @Struct.field(Name) - code!: Name + declare code: Name @Struct.field('string') - asset_url!: string + declare asset_url: string @Struct.field(UInt8) - r_color!: UInt8 + declare r_color: UInt8 @Struct.field(UInt8) - g_color!: UInt8 + declare g_color: UInt8 @Struct.field(UInt8) - b_color!: UInt8 + declare b_color: UInt8 } @Struct.type('addplanet') export class addplanet extends Struct { @Struct.field(UInt64) - id!: UInt64 + declare id: UInt64 @Struct.field(Name) - area_map!: Name + declare area_map: Name @Struct.field(Int8) - q_coord!: Int8 + declare q_coord: Int8 @Struct.field(Int8) - r_coord!: Int8 + declare r_coord: Int8 @Struct.field('string') - name!: string + declare name: string @Struct.field(Name) - code!: Name + declare code: Name @Struct.field('string') - asset_url!: string + declare asset_url: string @Struct.field(UInt8) - r_color!: UInt8 + declare r_color: UInt8 @Struct.field(UInt8) - g_color!: UInt8 + declare g_color: UInt8 @Struct.field(UInt8) - b_color!: UInt8 + declare b_color: UInt8 } @Struct.type('addregion') export class addregion extends Struct { @Struct.field(UInt64) - id!: UInt64 + declare id: UInt64 @Struct.field(Name) - area_map!: Name + declare area_map: Name @Struct.field('string') - name!: string + declare name: string @Struct.field(Name) - code!: Name + declare code: Name } @Struct.type('addresource') export class addresource extends Struct { @Struct.field(UInt64) - id!: UInt64 + declare id: UInt64 @Struct.field(UInt64) - gameasset_id!: UInt64 + declare gameasset_id: UInt64 @Struct.field('string') - name!: string + declare name: string @Struct.field('string') - asset_url!: string + declare asset_url: string @Struct.field(UInt32) - difficulty!: UInt32 + declare difficulty: UInt32 } @Struct.type('addterrain') export class addterrain extends Struct { @Struct.field(UInt64) - id!: UInt64 + declare id: UInt64 @Struct.field('string') - type!: string + declare type: string @Struct.field('string', {array: true}) - map_asset_urls!: string[] + declare map_asset_urls: string[] @Struct.field('string') - background_asset_url!: string + declare background_asset_url: string @Struct.field(UInt8) - building_slots!: UInt8 + declare building_slots: UInt8 @Struct.field(UInt64, {array: true}) - effects!: UInt64[] + declare effects: UInt64[] } @Struct.type('addtile') export class addtile extends Struct { @Struct.field(UInt64) - id!: UInt64 + declare id: UInt64 @Struct.field(Name) - area_map!: Name + declare area_map: Name @Struct.field(UInt64) - region_id!: UInt64 + declare region_id: UInt64 @Struct.field(Int8) - q_coord!: Int8 + declare q_coord: Int8 @Struct.field(Int8) - r_coord!: Int8 + declare r_coord: Int8 @Struct.field(UInt64) - terrain_type!: UInt64 + declare terrain_type: UInt64 } @Struct.type('addunit') export class addunit extends Struct { @Struct.field(UInt64) - unit_type_id!: UInt64 + declare unit_type_id: UInt64 @Struct.field(Name) - owner!: Name + declare owner: Name } @Struct.type('addvehicle') export class addvehicle extends Struct { @Struct.field(UInt64) - gameasset_id!: UInt64 + declare gameasset_id: UInt64 @Struct.field(UInt64) - tile_id!: UInt64 + declare tile_id: UInt64 @Struct.field(Name) - owner!: Name + declare owner: Name } @Struct.type('battle') export class battle extends Struct { @Struct.field(UInt64) - id!: UInt64 + declare id: UInt64 @Struct.field(UInt64) - location_tile_id!: UInt64 + declare location_tile_id: UInt64 @Struct.field(UInt64) - attacking_faction_id!: UInt64 + declare attacking_faction_id: UInt64 @Struct.field(UInt64) - defending_faction_id!: UInt64 + declare defending_faction_id: UInt64 @Struct.field(TimePoint) - battle_start!: TimePoint + declare battle_start: TimePoint @Struct.field(UInt32) - battle_round!: UInt32 + declare battle_round: UInt32 } @Struct.type('battleunit') export class battleunit extends Struct { @Struct.field(UInt64) - id!: UInt64 + declare id: UInt64 @Struct.field(Name) - owner!: Name + declare owner: Name @Struct.field(UInt64) - battle_id!: UInt64 + declare battle_id: UInt64 @Struct.field(UInt64) - external_id!: UInt64 + declare external_id: UInt64 @Struct.field(UInt64) - faction_id!: UInt64 + declare faction_id: UInt64 @Struct.field(UInt32) - hp!: UInt32 + declare hp: UInt32 @Struct.field(UInt32) - max_hp!: UInt32 + declare max_hp: UInt32 @Struct.field('bool') - is_character!: boolean + declare is_character: boolean @Struct.field('bool') - is_garrison!: boolean + declare is_garrison: boolean @Struct.field(UInt64) - retreat_to_tile!: UInt64 + declare retreat_to_tile: UInt64 } @Struct.type('building') export class building extends Struct { @Struct.field(UInt64) - id!: UInt64 + declare id: UInt64 @Struct.field(UInt64) - gameasset_id!: UInt64 + declare gameasset_id: UInt64 @Struct.field(Name) - owner!: Name + declare owner: Name @Struct.field('bool') - is_owner_faction!: boolean + declare is_owner_faction: boolean @Struct.field('bool') - disabled!: boolean + declare disabled: boolean @Struct.field(UInt32) - hp!: UInt32 + declare hp: UInt32 @Struct.field(UInt32) - max_hp!: UInt32 + declare max_hp: UInt32 @Struct.field(UInt64) - location_tile_id!: UInt64 + declare location_tile_id: UInt64 @Struct.field(TimePoint) - next_upkeep!: TimePoint + declare next_upkeep: TimePoint @Struct.field(pair_uint32_uint64, {array: true}) - inventory!: pair_uint32_uint64[] + declare inventory: pair_uint32_uint64[] } @Struct.type('calcenergy') export class calcenergy extends Struct { @Struct.field(UInt64) - character_id!: UInt64 + declare character_id: UInt64 } @Struct.type('character') export class character extends Struct { @Struct.field(UInt64) - id!: UInt64 + declare id: UInt64 @Struct.field('string') - first_name!: string + declare first_name: string @Struct.field('string') - middle_name!: string + declare middle_name: string @Struct.field('string') - last_name!: string + declare last_name: string @Struct.field('string') - asset_url!: string + declare asset_url: string @Struct.field(Float64) - energy!: Float64 + declare energy: Float64 @Struct.field(Float64) - max_energy!: Float64 + declare max_energy: Float64 @Struct.field(Name) - owner!: Name + declare owner: Name @Struct.field(TimePoint) - last_action_time!: TimePoint + declare last_action_time: TimePoint @Struct.field(TimePoint) - time_last_fed!: TimePoint + declare time_last_fed: TimePoint @Struct.field(UInt64) - tool_equipped!: UInt64 + declare tool_equipped: UInt64 @Struct.field(UInt64) - armor_equipped!: UInt64 + declare armor_equipped: UInt64 @Struct.field(UInt64) - melee_weapon_equipped!: UInt64 + declare melee_weapon_equipped: UInt64 @Struct.field(UInt64) - ranged_weapon_equipped!: UInt64 + declare ranged_weapon_equipped: UInt64 @Struct.field(UInt64) - on_board_vehicle!: UInt64 + declare on_board_vehicle: UInt64 @Struct.field(UInt64, {array: true}) - active_effects!: UInt64[] + declare active_effects: UInt64[] @Struct.field(UInt8) - base_character_role!: UInt8 + declare base_character_role: UInt8 @Struct.field(UInt8) - mid_character_role!: UInt8 + declare mid_character_role: UInt8 @Struct.field(UInt8) - character_role!: UInt8 + declare character_role: UInt8 @Struct.field(UInt32) - experience_level!: UInt32 + declare experience_level: UInt32 @Struct.field(UInt32) - experience_points!: UInt32 + declare experience_points: UInt32 @Struct.field(UInt32) - hp!: UInt32 + declare hp: UInt32 @Struct.field(UInt32) - max_hp!: UInt32 + declare max_hp: UInt32 @Struct.field('bool') - alive!: boolean + declare alive: boolean @Struct.field(UInt8) - temporal_deja_vu_score!: UInt8 + declare temporal_deja_vu_score: UInt8 } @Struct.type('clear') export class clear extends Struct {} @Struct.type('clearprim') export class clearprim extends Struct { @Struct.field(Name) - table_name!: Name + declare table_name: Name @Struct.field(Name) - scope!: Name + declare scope: Name } @Struct.type('clearsec1') export class clearsec1 extends Struct { @Struct.field(Name) - table_name!: Name + declare table_name: Name @Struct.field(UInt8) - index_num!: UInt8 + declare index_num: UInt8 @Struct.field(Name) - scope!: Name + declare scope: Name } @Struct.type('clearsec2') export class clearsec2 extends Struct { @Struct.field(Name) - table_name!: Name + declare table_name: Name @Struct.field(UInt8) - index_num!: UInt8 + declare index_num: UInt8 @Struct.field(Name) - scope!: Name + declare scope: Name } @Struct.type('combatant') export class combatant extends Struct { @Struct.field(UInt64) - player_id!: UInt64 + declare player_id: UInt64 @Struct.field(UInt64) - battle_id!: UInt64 + declare battle_id: UInt64 @Struct.field(UInt64) - faction_id!: UInt64 + declare faction_id: UInt64 @Struct.field(UInt64) - retreat_to_tile!: UInt64 + declare retreat_to_tile: UInt64 } @Struct.type('cooldown') export class cooldown extends Struct { @Struct.field(UInt8) - cooldown_type!: UInt8 + declare cooldown_type: UInt8 @Struct.field(TimePoint) - time_started!: TimePoint + declare time_started: TimePoint @Struct.field(UInt32) - cooldown_duration!: UInt32 + declare cooldown_duration: UInt32 } @Struct.type('createchar') export class createchar extends Struct { @Struct.field(Name) - player!: Name + declare player: Name } @Struct.type('crew') export class crew extends Struct { @Struct.field(UInt64) - character_id!: UInt64 + declare character_id: UInt64 @Struct.field(UInt64) - spaceship_id!: UInt64 + declare spaceship_id: UInt64 @Struct.field(UInt8) - role!: UInt8 + declare role: UInt8 } @Struct.type('day') export class day extends Struct { @Struct.field(TimePoint) - day_start!: TimePoint + declare day_start: TimePoint @Struct.field(TimePoint) - day_end!: TimePoint + declare day_end: TimePoint @Struct.field(UInt32) - total_active_players!: UInt32 + declare total_active_players: UInt32 @Struct.field(Float64) - energy_spent!: Float64 + declare energy_spent: Float64 } @Struct.type('deposit') export class deposit extends Struct { @Struct.field(UInt64) - id!: UInt64 + declare id: UInt64 @Struct.field(UInt64) - resource_type_id!: UInt64 + declare resource_type_id: UInt64 @Struct.field(UInt64) - location_tile_id!: UInt64 + declare location_tile_id: UInt64 } @Struct.type('detokenize') export class detokenize extends Struct { @Struct.field(Name) - player!: Name + declare player: Name @Struct.field(Asset) - resource!: Asset + declare resource: Asset } @Struct.type('discardchar') export class discardchar extends Struct { @Struct.field(UInt64) - character_id!: UInt64 + declare character_id: UInt64 } @Struct.type('doaddmats') export class doaddmats extends Struct { @Struct.field(UInt64) - character_id!: UInt64 + declare character_id: UInt64 @Struct.field(UInt64) - project_id!: UInt64 + declare project_id: UInt64 @Struct.field(pair_uint32_uint64) - materials!: pair_uint32_uint64 + declare materials: pair_uint32_uint64 } @Struct.type('doaddproj') export class doaddproj extends Struct { @Struct.field(UInt64) - character_id!: UInt64 + declare character_id: UInt64 @Struct.field(UInt64) - blueprint_id!: UInt64 + declare blueprint_id: UInt64 } @Struct.type('dobuild') export class dobuild extends Struct { @Struct.field(UInt64) - character_id!: UInt64 + declare character_id: UInt64 @Struct.field(UInt64) - project_id!: UInt64 + declare project_id: UInt64 } @Struct.type('docancelproj') export class docancelproj extends Struct { @Struct.field(UInt64) - character_id!: UInt64 + declare character_id: UInt64 @Struct.field(UInt64) - project_id!: UInt64 + declare project_id: UInt64 } @Struct.type('docombat') export class docombat extends Struct { @Struct.field(Name) - player!: Name + declare player: Name @Struct.field(UInt64) - faction_id!: UInt64 + declare faction_id: UInt64 } @Struct.type('doconquer') export class doconquer extends Struct { @Struct.field(Name) - player!: Name + declare player: Name @Struct.field(UInt64) - target_tile_id!: UInt64 + declare target_tile_id: UInt64 } @Struct.type('docontrol') export class docontrol extends Struct { @Struct.field(UInt64) - character_id!: UInt64 + declare character_id: UInt64 } @Struct.type('docraft') export class docraft extends Struct { @Struct.field(UInt64) - character_id!: UInt64 + declare character_id: UInt64 @Struct.field(UInt64) - recipe_id!: UInt64 + declare recipe_id: UInt64 } @Struct.type('docreateship') export class docreateship extends Struct { @Struct.field(UInt64) - character_id!: UInt64 + declare character_id: UInt64 @Struct.field(UInt64, {array: true}) - shipmodules!: UInt64[] + declare shipmodules: UInt64[] } @Struct.type('dodemobilize') export class dodemobilize extends Struct { @Struct.field(Name) - player!: Name + declare player: Name @Struct.field(UInt64, {array: true}) - units!: UInt64[] + declare units: UInt64[] } @Struct.type('dodevelop') export class dodevelop extends Struct { @Struct.field(UInt64) - character_id!: UInt64 + declare character_id: UInt64 } @Struct.type('dodisband') export class dodisband extends Struct { @Struct.field(Name) - player!: Name + declare player: Name @Struct.field(UInt64) - unit_id!: UInt64 + declare unit_id: UInt64 } @Struct.type('dodisembark') export class dodisembark extends Struct { @Struct.field(UInt64) - character_id!: UInt64 + declare character_id: UInt64 } @Struct.type('dodropoff') export class dodropoff extends Struct { @Struct.field(Name) - player!: Name + declare player: Name @Struct.field(pair_uint32_uint64) - items!: pair_uint32_uint64 + declare items: pair_uint32_uint64 } @Struct.type('doeat') export class doeat extends Struct { @Struct.field(UInt64) - character_id!: UInt64 + declare character_id: UInt64 } @Struct.type('doembark') export class doembark extends Struct { @Struct.field(UInt64) - character_id!: UInt64 + declare character_id: UInt64 @Struct.field(UInt64) - vehicle_id!: UInt64 + declare vehicle_id: UInt64 } @Struct.type('doentership') export class doentership extends Struct { @Struct.field(Name) - player!: Name + declare player: Name @Struct.field(UInt64) - spaceship_id!: UInt64 + declare spaceship_id: UInt64 } @Struct.type('doequip') export class doequip extends Struct { @Struct.field(UInt64) - character_id!: UInt64 + declare character_id: UInt64 @Struct.field(UInt64) - gameasset_id!: UInt64 + declare gameasset_id: UInt64 } @Struct.type('dogive') export class dogive extends Struct { @Struct.field(Name) - owner!: Name + declare owner: Name @Struct.field(Name) - recipient!: Name + declare recipient: Name @Struct.field(pair_uint32_uint64, {array: true}) - items!: pair_uint32_uint64[] + declare items: pair_uint32_uint64[] } @Struct.type('doheal') export class doheal extends Struct { @Struct.field(UInt64) - character_id!: UInt64 + declare character_id: UInt64 @Struct.field(UInt64) - patient_id!: UInt64 + declare patient_id: UInt64 @Struct.field('bool') - is_character!: boolean + declare is_character: boolean } @Struct.type('dojoinbattle') export class dojoinbattle extends Struct { @Struct.field(Name) - player!: Name + declare player: Name @Struct.field(UInt64) - battle_id!: UInt64 + declare battle_id: UInt64 } @Struct.type('doland') export class doland extends Struct { @Struct.field(UInt64) - spaceship_id!: UInt64 + declare spaceship_id: UInt64 @Struct.field(UInt64) - tile_id!: UInt64 + declare tile_id: UInt64 } @Struct.type('dolaunch') export class dolaunch extends Struct { @Struct.field(UInt64) - spaceship_id!: UInt64 + declare spaceship_id: UInt64 } @Struct.type('doleaveship') export class doleaveship extends Struct { @Struct.field(Name) - player!: Name + declare player: Name } @Struct.type('doload') export class doload extends Struct { @Struct.field(Name) - player!: Name + declare player: Name @Struct.field(UInt64) - vehicle_id!: UInt64 + declare vehicle_id: UInt64 @Struct.field(pair_uint32_uint64) - items!: pair_uint32_uint64 + declare items: pair_uint32_uint64 } @Struct.type('domobilize') export class domobilize extends Struct { @Struct.field(Name) - player!: Name + declare player: Name @Struct.field(UInt64, {array: true}) - units!: UInt64[] + declare units: UInt64[] } @Struct.type('domove') export class domove extends Struct { @Struct.field(Name) - player!: Name + declare player: Name @Struct.field(UInt64) - destination_tile_id!: UInt64 + declare destination_tile_id: UInt64 } @Struct.type('domoveship') export class domoveship extends Struct { @Struct.field(UInt64) - spaceship_id!: UInt64 + declare spaceship_id: UInt64 @Struct.field(UInt64) - tile_id!: UInt64 + declare tile_id: UInt64 } @Struct.type('dopayupkeep') export class dopayupkeep extends Struct { @Struct.field(UInt64) - character_id!: UInt64 + declare character_id: UInt64 @Struct.field(UInt8) - type!: UInt8 + declare type: UInt8 @Struct.field(UInt64) - entity!: UInt64 + declare entity: UInt64 } @Struct.type('dopickup') export class dopickup extends Struct { @Struct.field(Name) - player!: Name + declare player: Name @Struct.field(pair_uint32_uint64) - items!: pair_uint32_uint64 + declare items: pair_uint32_uint64 } @Struct.type('dorepair') export class dorepair extends Struct { @Struct.field(UInt64) - character_id!: UInt64 + declare character_id: UInt64 @Struct.field(UInt64) - entity_id!: UInt64 + declare entity_id: UInt64 @Struct.field(UInt8) - type!: UInt8 + declare type: UInt8 } @Struct.type('doresearch') export class doresearch extends Struct { @Struct.field(UInt64) - character_id!: UInt64 + declare character_id: UInt64 @Struct.field(UInt64) - technology_id!: UInt64 + declare technology_id: UInt64 } @Struct.type('doretreat') export class doretreat extends Struct { @Struct.field(Name) - player!: Name + declare player: Name @Struct.field(UInt64) - destination_tile_id!: UInt64 + declare destination_tile_id: UInt64 } @Struct.type('dotrain') export class dotrain extends Struct { @Struct.field(UInt64) - character_id!: UInt64 + declare character_id: UInt64 @Struct.field(UInt64) - recipe_id!: UInt64 + declare recipe_id: UInt64 @Struct.field('bool') - mobilize!: boolean + declare mobilize: boolean } @Struct.type('dotransfer') export class dotransfer extends Struct { @Struct.field(UInt64) - entity_id!: UInt64 + declare entity_id: UInt64 @Struct.field(UInt8) - type!: UInt8 + declare type: UInt8 @Struct.field(Name) - new_owner!: Name + declare new_owner: Name } @Struct.type('dounequip') export class dounequip extends Struct { @Struct.field(UInt64) - character_id!: UInt64 + declare character_id: UInt64 @Struct.field(UInt8) - item_type!: UInt8 + declare item_type: UInt8 } @Struct.type('dounload') export class dounload extends Struct { @Struct.field(Name) - player!: Name + declare player: Name @Struct.field(UInt64) - vehicle_id!: UInt64 + declare vehicle_id: UInt64 @Struct.field(pair_uint32_uint64) - items!: pair_uint32_uint64 + declare items: pair_uint32_uint64 } @Struct.type('dowork') export class dowork extends Struct { @Struct.field(UInt64) - character_id!: UInt64 + declare character_id: UInt64 @Struct.field(UInt8) - activity!: UInt8 + declare activity: UInt8 } @Struct.type('electresult') export class electresult extends Struct { @Struct.field(UInt64) - faction_id!: UInt64 + declare faction_id: UInt64 @Struct.field(UInt64) - leader!: UInt64 + declare leader: UInt64 @Struct.field(UInt64, {array: true}) - officers!: UInt64[] + declare officers: UInt64[] } @Struct.type('endday') export class endday extends Struct {} @@ -681,597 +681,597 @@ export namespace Types { @Struct.type('faction') export class faction extends Struct { @Struct.field(UInt64) - id!: UInt64 + declare id: UInt64 @Struct.field('string') - name!: string + declare name: string @Struct.field(Name) - code!: Name + declare code: Name @Struct.field('string') - flag_asset_url!: string + declare flag_asset_url: string @Struct.field('bool') - activated!: boolean + declare activated: boolean @Struct.field(UInt64) - leader!: UInt64 + declare leader: UInt64 @Struct.field(UInt64, {array: true}) - officers!: UInt64[] + declare officers: UInt64[] @Struct.field(UInt32) - total_players!: UInt32 + declare total_players: UInt32 @Struct.field(UInt64, {array: true}) - mining_characters!: UInt64[] + declare mining_characters: UInt64[] @Struct.field(UInt64, {array: true}) - engineering_characters!: UInt64[] + declare engineering_characters: UInt64[] @Struct.field(UInt64, {array: true}) - farming_characters!: UInt64[] + declare farming_characters: UInt64[] @Struct.field(UInt64, {array: true}) - logistics_characters!: UInt64[] + declare logistics_characters: UInt64[] @Struct.field(UInt64, {array: true}) - health_care_characters!: UInt64[] + declare health_care_characters: UInt64[] @Struct.field(UInt64, {array: true}) - commerce_characters!: UInt64[] + declare commerce_characters: UInt64[] @Struct.field(UInt64, {array: true}) - civil_service_characters!: UInt64[] + declare civil_service_characters: UInt64[] @Struct.field(UInt64, {array: true}) - intelligence_characters!: UInt64[] + declare intelligence_characters: UInt64[] @Struct.field(UInt64, {array: true}) - military_characters!: UInt64[] + declare military_characters: UInt64[] @Struct.field(UInt64, {array: true}) - research_characters!: UInt64[] + declare research_characters: UInt64[] @Struct.field(UInt64, {array: true}) - energy_characters!: UInt64[] + declare energy_characters: UInt64[] @Struct.field(UInt64, {array: true}) - infrastructure_characters!: UInt64[] + declare infrastructure_characters: UInt64[] @Struct.field(UInt64, {array: true}) - operations_characters!: UInt64[] + declare operations_characters: UInt64[] @Struct.field(UInt64, {array: true}) - governance_characters!: UInt64[] + declare governance_characters: UInt64[] @Struct.field(UInt64, {array: true}) - diplomacy_characters!: UInt64[] + declare diplomacy_characters: UInt64[] @Struct.field(day) - day_stats!: day + declare day_stats: day @Struct.field(UInt64, {array: true}) - active_effects!: UInt64[] + declare active_effects: UInt64[] } @Struct.type('global') export class global extends Struct { @Struct.field(Name) - game_master!: Name + declare game_master: Name @Struct.field(TimePoint) - game_started!: TimePoint + declare game_started: TimePoint @Struct.field(TimePoint) - game_end!: TimePoint + declare game_end: TimePoint @Struct.field(UInt8) - current_epoch!: UInt8 + declare current_epoch: UInt8 @Struct.field(UInt8) - current_period!: UInt8 + declare current_period: UInt8 @Struct.field(UInt8) - current_cycle!: UInt8 + declare current_cycle: UInt8 @Struct.field(UInt8) - current_day!: UInt8 + declare current_day: UInt8 @Struct.field(UInt32) - total_days!: UInt32 + declare total_days: UInt32 @Struct.field(Float64) - total_energy!: Float64 + declare total_energy: Float64 @Struct.field(UInt32) - total_players!: UInt32 + declare total_players: UInt32 @Struct.field(UInt32) - total_characters!: UInt32 + declare total_characters: UInt32 @Struct.field(TimePoint) - last_oracle_timestamp!: TimePoint + declare last_oracle_timestamp: TimePoint @Struct.field(Checksum256) - last_oracle_hash!: Checksum256 + declare last_oracle_hash: Checksum256 @Struct.field(day) - day_stats!: day + declare day_stats: day @Struct.field(day) - ind_day_stats!: day + declare ind_day_stats: day @Struct.field('bool') - players_inflation_bucket_active!: boolean + declare players_inflation_bucket_active: boolean @Struct.field('bool') - factions_inflation_bucket_active!: boolean + declare factions_inflation_bucket_active: boolean @Struct.field('bool') - regions_inflation_bucket_active!: boolean + declare regions_inflation_bucket_active: boolean @Struct.field('bool') - planets_inflation_bucket_active!: boolean + declare planets_inflation_bucket_active: boolean } @Struct.type('grantspoils') export class grantspoils extends Struct { @Struct.field(Name) - beneficiary!: Name + declare beneficiary: Name @Struct.field(UInt64) - entity_id!: UInt64 + declare entity_id: UInt64 @Struct.field(UInt8) - entity_type!: UInt8 + declare entity_type: UInt8 } @Struct.type('hashes') export class hashes extends Struct { @Struct.field(UInt64) - id!: UInt64 + declare id: UInt64 @Struct.field(Name) - owner!: Name + declare owner: Name @Struct.field(Checksum256) - multiparty!: Checksum256 + declare multiparty: Checksum256 @Struct.field(Checksum256) - hash!: Checksum256 + declare hash: Checksum256 @Struct.field('string') - reveal!: string + declare reveal: string @Struct.field(TimePoint) - timestamp!: TimePoint + declare timestamp: TimePoint } @Struct.type('init') export class init extends Struct { @Struct.field(UInt8) - epoch!: UInt8 + declare epoch: UInt8 } @Struct.type('joinfaction') export class joinfaction extends Struct { @Struct.field(Name) - player!: Name + declare player: Name @Struct.field(UInt64) - faction_id!: UInt64 + declare faction_id: UInt64 } @Struct.type('killchar') export class killchar extends Struct { @Struct.field(UInt64) - character_id!: UInt64 + declare character_id: UInt64 } @Struct.type('map') export class map extends Struct { @Struct.field(Name) - area_map!: Name + declare area_map: Name @Struct.field('string') - name!: string + declare name: string @Struct.field(Name) - code!: Name + declare code: Name @Struct.field('string') - asset_url!: string + declare asset_url: string @Struct.field(day) - day_stats!: day + declare day_stats: day @Struct.field(UInt8) - r_color!: UInt8 + declare r_color: UInt8 @Struct.field(UInt8) - g_color!: UInt8 + declare g_color: UInt8 @Struct.field(UInt8) - b_color!: UInt8 + declare b_color: UInt8 } @Struct.type('msigsuccess') export class msigsuccess extends Struct { @Struct.field(UInt64) - squad_id!: UInt64 + declare squad_id: UInt64 } @Struct.type('pair_uint64_CrewRole') export class pair_uint64_CrewRole extends Struct { @Struct.field(UInt64) - first!: UInt64 + declare first: UInt64 @Struct.field(UInt8) - second!: UInt8 + declare second: UInt8 } @Struct.type('passenger') export class passenger extends Struct { @Struct.field(Name) - player!: Name + declare player: Name @Struct.field(UInt64) - spaceship_id!: UInt64 + declare spaceship_id: UInt64 } @Struct.type('planet') export class planet extends Struct { @Struct.field(UInt64) - id!: UInt64 + declare id: UInt64 @Struct.field('string') - name!: string + declare name: string @Struct.field(Name) - code!: Name + declare code: Name @Struct.field(Int8) - q_coord!: Int8 + declare q_coord: Int8 @Struct.field(Int8) - r_coord!: Int8 + declare r_coord: Int8 @Struct.field('string') - asset_url!: string + declare asset_url: string @Struct.field(Name) - area_map!: Name + declare area_map: Name @Struct.field(day) - day_stats!: day + declare day_stats: day @Struct.field(UInt64) - control_faction!: UInt64 + declare control_faction: UInt64 @Struct.field(UInt8) - r_color!: UInt8 + declare r_color: UInt8 @Struct.field(UInt8) - g_color!: UInt8 + declare g_color: UInt8 @Struct.field(UInt8) - b_color!: UInt8 + declare b_color: UInt8 } @Struct.type('player') export class player extends Struct { @Struct.field(UInt64) - id!: UInt64 + declare id: UInt64 @Struct.field(Name) - owner!: Name + declare owner: Name @Struct.field('string') - asset_url!: string + declare asset_url: string @Struct.field(UInt8) - character_slots!: UInt8 + declare character_slots: UInt8 @Struct.field(UInt8) - reputation_level!: UInt8 + declare reputation_level: UInt8 @Struct.field(UInt32) - experience_level!: UInt32 + declare experience_level: UInt32 @Struct.field(UInt32) - experience_points!: UInt32 + declare experience_points: UInt32 @Struct.field(cooldown, {array: true}) - cooldowns!: cooldown[] + declare cooldowns: cooldown[] @Struct.field(UInt64) - active_project!: UInt64 + declare active_project: UInt64 @Struct.field(UInt64) - faction!: UInt64 + declare faction: UInt64 @Struct.field(Float64) - base_faction_voting_power!: Float64 + declare base_faction_voting_power: Float64 @Struct.field(UInt32) - max_inventory_size!: UInt32 + declare max_inventory_size: UInt32 @Struct.field(pair_uint32_uint64, {array: true}) - inventory!: pair_uint32_uint64[] + declare inventory: pair_uint32_uint64[] @Struct.field(Asset) - currency!: Asset + declare currency: Asset @Struct.field(TimePoint) - last_respawn!: TimePoint + declare last_respawn: TimePoint @Struct.field(UInt64) - location_tile_id!: UInt64 + declare location_tile_id: UInt64 @Struct.field('bool') - opted_out_of_politics!: boolean + declare opted_out_of_politics: boolean @Struct.field(UInt32) - mobilized_units!: UInt32 + declare mobilized_units: UInt32 } @Struct.type('primarykey') export class primarykey extends Struct { @Struct.field(Name) - table!: Name + declare table: Name @Struct.field(UInt64) - next_key!: UInt64 + declare next_key: UInt64 } @Struct.type('proc') export class proc extends Struct { @Struct.field(UInt32) - count!: UInt32 + declare count: UInt32 } @Struct.type('project') export class project extends Struct { @Struct.field(UInt64) - id!: UInt64 + declare id: UInt64 @Struct.field(UInt64) - blueprint_id!: UInt64 + declare blueprint_id: UInt64 @Struct.field(UInt64) - location_tile_id!: UInt64 + declare location_tile_id: UInt64 @Struct.field(TimePoint) - last_action_time!: TimePoint + declare last_action_time: TimePoint @Struct.field(pair_uint32_uint64, {array: true}) - materials!: pair_uint32_uint64[] + declare materials: pair_uint32_uint64[] @Struct.field(UInt32) - work!: UInt32 + declare work: UInt32 @Struct.field(Name) - owner!: Name + declare owner: Name @Struct.field('bool') - is_owner_faction!: boolean + declare is_owner_faction: boolean @Struct.field('bool') - is_building!: boolean + declare is_building: boolean } @Struct.type('region') export class region extends Struct { @Struct.field(UInt64) - id!: UInt64 + declare id: UInt64 @Struct.field(Name) - area_map!: Name + declare area_map: Name @Struct.field('string') - name!: string + declare name: string @Struct.field(Name) - code!: Name + declare code: Name @Struct.field(day) - day_stats!: day + declare day_stats: day @Struct.field(UInt64) - control_faction!: UInt64 + declare control_faction: UInt64 } @Struct.type('regplayer') export class regplayer extends Struct { @Struct.field(Name) - player!: Name + declare player: Name @Struct.field('bool') - opt_out_of_politics!: boolean + declare opt_out_of_politics: boolean } @Struct.type('resolverngs') export class resolverngs extends Struct { @Struct.field(UInt32) - count!: UInt32 + declare count: UInt32 } @Struct.type('resource') export class resource extends Struct { @Struct.field(UInt64) - id!: UInt64 + declare id: UInt64 @Struct.field(UInt64) - gameasset_id!: UInt64 + declare gameasset_id: UInt64 @Struct.field('string') - name!: string + declare name: string @Struct.field(UInt32) - difficulty!: UInt32 + declare difficulty: UInt32 @Struct.field('string') - asset_url!: string + declare asset_url: string } @Struct.type('restorehp') export class restorehp extends Struct { @Struct.field(UInt64) - character_id!: UInt64 + declare character_id: UInt64 } @Struct.type('revivechar') export class revivechar extends Struct { @Struct.field(UInt64) - character_id!: UInt64 + declare character_id: UInt64 @Struct.field(Name) - payer!: Name + declare payer: Name } @Struct.type('rngrequest') export class rngrequest extends Struct { @Struct.field(UInt64) - id!: UInt64 + declare id: UInt64 @Struct.field(TimePoint) - created!: TimePoint + declare created: TimePoint @Struct.field(TimePoint) - execution!: TimePoint + declare execution: TimePoint @Struct.field(UInt64) - external_id!: UInt64 + declare external_id: UInt64 @Struct.field('bool') - is_character_rng!: boolean + declare is_character_rng: boolean @Struct.field(UInt8) - rng_type!: UInt8 + declare rng_type: UInt8 @Struct.field(Checksum256) - result!: Checksum256 + declare result: Checksum256 } @Struct.type('rprog') export class rprog extends Struct { @Struct.field(UInt64) - id!: UInt64 + declare id: UInt64 @Struct.field(UInt64) - technology_id!: UInt64 + declare technology_id: UInt64 @Struct.field(UInt64) - faction_id!: UInt64 + declare faction_id: UInt64 @Struct.field(UInt64) - tree_id!: UInt64 + declare tree_id: UInt64 @Struct.field(Float64) - research_points!: Float64 + declare research_points: Float64 } @Struct.type('setcharacter') export class setcharacter extends Struct { @Struct.field(character) - c!: character + declare c: character } @Struct.type('setcrew') export class setcrew extends Struct { @Struct.field(UInt64) - spaceship_id!: UInt64 + declare spaceship_id: UInt64 @Struct.field(pair_uint64_CrewRole, {array: true}) - crew!: pair_uint64_CrewRole[] + declare crew: pair_uint64_CrewRole[] } @Struct.type('setgm') export class setgm extends Struct { @Struct.field(Name) - player!: Name + declare player: Name } @Struct.type('setoperator') export class setoperator extends Struct { @Struct.field(UInt64) - spaceship_id!: UInt64 + declare spaceship_id: UInt64 @Struct.field(Name) - ship_operator!: Name + declare ship_operator: Name } @Struct.type('setplayer') export class setplayer extends Struct { @Struct.field(player) - p!: player + declare p: player } @Struct.type('settilecw') export class settilecw extends Struct { @Struct.field(UInt64) - tile_id!: UInt64 + declare tile_id: UInt64 @Struct.field(Float64) - control!: Float64 + declare control: Float64 @Struct.field(Float64) - wildness!: Float64 + declare wildness: Float64 @Struct.field(UInt64) - controlling_faction_id!: UInt64 + declare controlling_faction_id: UInt64 } @Struct.type('shipmodule') export class shipmodule extends Struct { @Struct.field(UInt64) - id!: UInt64 + declare id: UInt64 @Struct.field(Name) - owner!: Name + declare owner: Name @Struct.field('bool') - is_owner_faction!: boolean + declare is_owner_faction: boolean @Struct.field(UInt64) - spaceship_id!: UInt64 + declare spaceship_id: UInt64 @Struct.field(UInt64) - gameasset_id!: UInt64 + declare gameasset_id: UInt64 @Struct.field(UInt64) - location_tile_id!: UInt64 + declare location_tile_id: UInt64 @Struct.field(UInt32) - hp!: UInt32 + declare hp: UInt32 @Struct.field(UInt32) - max_hp!: UInt32 + declare max_hp: UInt32 @Struct.field(TimePoint) - next_upkeep!: TimePoint + declare next_upkeep: TimePoint @Struct.field('bool') - disabled!: boolean + declare disabled: boolean } @Struct.type('spaceship') export class spaceship extends Struct { @Struct.field(UInt64) - id!: UInt64 + declare id: UInt64 @Struct.field(Name) - owner!: Name + declare owner: Name @Struct.field(Name) - ship_operator!: Name + declare ship_operator: Name @Struct.field('bool') - is_owner_faction!: boolean + declare is_owner_faction: boolean @Struct.field(UInt64) - location_tile_id!: UInt64 + declare location_tile_id: UInt64 @Struct.field(UInt32) - max_passengers!: UInt32 + declare max_passengers: UInt32 @Struct.field(UInt32) - max_inventory_size!: UInt32 + declare max_inventory_size: UInt32 @Struct.field(pair_uint32_uint64, {array: true}) - inventory!: pair_uint32_uint64[] + declare inventory: pair_uint32_uint64[] } @Struct.type('squad') export class squad extends Struct { @Struct.field(UInt64) - id!: UInt64 + declare id: UInt64 @Struct.field(UInt64) - faction_id!: UInt64 + declare faction_id: UInt64 @Struct.field('bool') - msig_succeeded!: boolean + declare msig_succeeded: boolean @Struct.field(UInt8) - character_role!: UInt8 + declare character_role: UInt8 } @Struct.type('startepoch') export class startepoch extends Struct {} @Struct.type('terrain') export class terrain extends Struct { @Struct.field(UInt64) - id!: UInt64 + declare id: UInt64 @Struct.field('string') - type!: string + declare type: string @Struct.field('string', {array: true}) - map_asset_urls!: string[] + declare map_asset_urls: string[] @Struct.field('string') - background_asset_url!: string + declare background_asset_url: string @Struct.field(UInt8) - building_slots!: UInt8 + declare building_slots: UInt8 @Struct.field(UInt8) - player_slots!: UInt8 + declare player_slots: UInt8 @Struct.field(UInt64, {array: true}) - effects!: UInt64[] + declare effects: UInt64[] } @Struct.type('test') export class test extends Struct {} @Struct.type('tile') export class tile extends Struct { @Struct.field(UInt64) - id!: UInt64 + declare id: UInt64 @Struct.field(Name) - area_map!: Name + declare area_map: Name @Struct.field(UInt64) - region_id!: UInt64 + declare region_id: UInt64 @Struct.field(Int8) - q_coord!: Int8 + declare q_coord: Int8 @Struct.field(Int8) - r_coord!: Int8 + declare r_coord: Int8 @Struct.field(UInt64) - terrain_type!: UInt64 + declare terrain_type: UInt64 @Struct.field(UInt64) - control_faction!: UInt64 + declare control_faction: UInt64 @Struct.field(Float64) - control!: Float64 + declare control: Float64 @Struct.field(Float64) - wildness!: Float64 + declare wildness: Float64 @Struct.field(TimePoint) - time_since_refresh!: TimePoint + declare time_since_refresh: TimePoint @Struct.field(UInt32) - max_inventory_size!: UInt32 + declare max_inventory_size: UInt32 @Struct.field(UInt32) - players_count!: UInt32 + declare players_count: UInt32 @Struct.field(pair_uint32_uint64, {array: true}) - inventory!: pair_uint32_uint64[] + declare inventory: pair_uint32_uint64[] @Struct.field(UInt64, {array: true}) - active_effects!: UInt64[] + declare active_effects: UInt64[] @Struct.field(UInt32) - garrisoned_units!: UInt32 + declare garrisoned_units: UInt32 } @Struct.type('timedeffect') export class timedeffect extends Struct { @Struct.field(UInt64) - id!: UInt64 + declare id: UInt64 @Struct.field(UInt64) - effect_id!: UInt64 + declare effect_id: UInt64 @Struct.field(UInt64) - entity_id!: UInt64 + declare entity_id: UInt64 @Struct.field(UInt8) - type!: UInt8 + declare type: UInt8 @Struct.field(TimePoint) - expiry!: TimePoint + declare expiry: TimePoint } @Struct.type('tokenize') export class tokenize extends Struct { @Struct.field(Name) - player!: Name + declare player: Name @Struct.field(Asset) - resource!: Asset + declare resource: Asset } @Struct.type('unit') export class unit extends Struct { @Struct.field(UInt64) - id!: UInt64 + declare id: UInt64 @Struct.field(UInt64) - unit_type_id!: UInt64 + declare unit_type_id: UInt64 @Struct.field(UInt64) - faction_id!: UInt64 + declare faction_id: UInt64 @Struct.field(Name) - owner!: Name + declare owner: Name @Struct.field(UInt32) - hp!: UInt32 + declare hp: UInt32 @Struct.field(UInt32) - max_hp!: UInt32 + declare max_hp: UInt32 @Struct.field('bool') - mobilized!: boolean + declare mobilized: boolean @Struct.field(TimePoint) - last_mobilization_action_time!: TimePoint + declare last_mobilization_action_time: TimePoint @Struct.field(UInt64) - location_tile_id!: UInt64 + declare location_tile_id: UInt64 @Struct.field(TimePoint) - next_upkeep!: TimePoint + declare next_upkeep: TimePoint @Struct.field(UInt64, {array: true}) - active_effects!: UInt64[] + declare active_effects: UInt64[] } @Struct.type('updatechars') export class updatechars extends Struct { @Struct.field(UInt32) - count!: UInt32 + declare count: UInt32 } @Struct.type('updaterng') export class updaterng extends Struct {} @Struct.type('updatetile') export class updatetile extends Struct { @Struct.field(UInt64) - tile_id!: UInt64 + declare tile_id: UInt64 } @Struct.type('updatetiles') export class updatetiles extends Struct { @Struct.field(UInt32) - count!: UInt32 + declare count: UInt32 } @Struct.type('upgradechar') export class upgradechar extends Struct { @Struct.field(UInt64) - character_id!: UInt64 + declare character_id: UInt64 @Struct.field(UInt8) - new_role!: UInt8 + declare new_role: UInt8 } @Struct.type('vehicle') export class vehicle extends Struct { @Struct.field(UInt64) - id!: UInt64 + declare id: UInt64 @Struct.field(UInt64) - gameasset_id!: UInt64 + declare gameasset_id: UInt64 @Struct.field(Name) - owner!: Name + declare owner: Name @Struct.field('bool') - is_owner_faction!: boolean + declare is_owner_faction: boolean @Struct.field(UInt32) - hp!: UInt32 + declare hp: UInt32 @Struct.field(UInt32) - max_hp!: UInt32 + declare max_hp: UInt32 @Struct.field(UInt64) - location_tile_id!: UInt64 + declare location_tile_id: UInt64 @Struct.field(TimePoint) - next_upkeep!: TimePoint + declare next_upkeep: TimePoint @Struct.field('bool') - disabled!: boolean + declare disabled: boolean @Struct.field(UInt64, {array: true}) - passengers!: UInt64[] + declare passengers: UInt64[] @Struct.field(pair_uint32_uint64, {array: true}) - inventory!: pair_uint32_uint64[] + declare inventory: pair_uint32_uint64[] } } export const TableMap = { diff --git a/test/data/contracts/mock-payroll.boid.ts b/test/data/contracts/mock-payroll.boid.ts index 8dc92a3..9e21dab 100644 --- a/test/data/contracts/mock-payroll.boid.ts +++ b/test/data/contracts/mock-payroll.boid.ts @@ -27,95 +27,95 @@ export namespace Types { @Struct.type('Payroll') export class Payroll extends Struct { @Struct.field(UInt64) - id!: UInt64 + declare id: UInt64 @Struct.field(Asset) - total!: Asset + declare total: Asset @Struct.field(Asset) - paid!: Asset + declare paid: Asset @Struct.field(TimePointSec) - startTime!: TimePointSec + declare startTime: TimePointSec @Struct.field(TimePointSec) - finishTime!: TimePointSec + declare finishTime: TimePointSec @Struct.field(TimePointSec) - lastPayout!: TimePointSec + declare lastPayout: TimePointSec @Struct.field(UInt32) - minClaimFrequencySec!: UInt32 + declare minClaimFrequencySec: UInt32 @Struct.field(Name) - receiverAccount!: Name + declare receiverAccount: Name @Struct.field(Name) - treasuryAccount!: Name + declare treasuryAccount: Name @Struct.field('bool') - paused!: boolean + declare paused: boolean @Struct.field(Bytes) - meta!: Bytes + declare meta: Bytes } @Struct.type('PayrollConfig') export class PayrollConfig extends Struct { @Struct.field(Asset) - total!: Asset + declare total: Asset @Struct.field(TimePointSec) - startTime!: TimePointSec + declare startTime: TimePointSec @Struct.field(TimePointSec) - finishTime!: TimePointSec + declare finishTime: TimePointSec @Struct.field(UInt32) - minClaimFrequencySec!: UInt32 + declare minClaimFrequencySec: UInt32 @Struct.field(Name) - receiverAccount!: Name + declare receiverAccount: Name @Struct.field(Name) - treasuryAccount!: Name + declare treasuryAccount: Name @Struct.field(Bytes) - meta!: Bytes + declare meta: Bytes @Struct.field('bool') - paused!: boolean + declare paused: boolean } @Struct.type('TokensWhitelist') export class TokensWhitelist extends Struct { @Struct.field(Asset.Symbol) - sym!: Asset.Symbol + declare sym: Asset.Symbol @Struct.field(Name) - contract!: Name + declare contract: Name } @Struct.type('payroll.add') export class payrolladd extends Struct { @Struct.field(PayrollConfig) - payrollConfig!: PayrollConfig + declare payrollConfig: PayrollConfig } @Struct.type('payroll.edit') export class payrolledit extends Struct { @Struct.field(UInt64) - payrollId!: UInt64 + declare payrollId: UInt64 @Struct.field('bool') - pause!: boolean + declare pause: boolean @Struct.field(UInt32) - minClaimFrequencySec!: UInt32 + declare minClaimFrequencySec: UInt32 @Struct.field(Name) - receiverAccount!: Name + declare receiverAccount: Name @Struct.field(Name) - treasuryAccount!: Name + declare treasuryAccount: Name @Struct.field(Bytes) - meta!: Bytes + declare meta: Bytes } @Struct.type('payroll.pay') export class payrollpay extends Struct { @Struct.field(UInt64) - payrollId!: UInt64 + declare payrollId: UInt64 } @Struct.type('payroll.rm') export class payrollrm extends Struct { @Struct.field(UInt64) - payrollId!: UInt64 + declare payrollId: UInt64 } @Struct.type('tokenwl.add') export class tokenwladd extends Struct { @Struct.field(Asset.Symbol) - sym!: Asset.Symbol + declare sym: Asset.Symbol @Struct.field(Name) - contract!: Name + declare contract: Name } @Struct.type('tokenwl.rm') export class tokenwlrm extends Struct { @Struct.field(Asset.SymbolCode) - sym!: Asset.SymbolCode + declare sym: Asset.SymbolCode } } export const TableMap = { diff --git a/test/data/contracts/mock-rewards.gm.ts b/test/data/contracts/mock-rewards.gm.ts index ec0414b..8c7a216 100644 --- a/test/data/contracts/mock-rewards.gm.ts +++ b/test/data/contracts/mock-rewards.gm.ts @@ -17,80 +17,80 @@ export namespace Types { @Struct.type('adduser') export class adduser extends Struct { @Struct.field(Name) - account!: Name + declare account: Name @Struct.field(UInt16) - weight!: UInt16 + declare weight: UInt16 } @Struct.type('claim') export class claim extends Struct { @Struct.field(Name) - account!: Name + declare account: Name @Struct.field(Asset, {optional: true}) - amount?: Asset + declare amount?: Asset } @Struct.type('oracle_pair') export class oracle_pair extends Struct { @Struct.field(Name) - name!: Name + declare name: Name @Struct.field(UInt16) - precision!: UInt16 + declare precision: UInt16 } @Struct.type('config') export class config extends Struct { @Struct.field(Asset.Symbol) - token_symbol!: Asset.Symbol + declare token_symbol: Asset.Symbol @Struct.field(Name) - oracle_account!: Name + declare oracle_account: Name @Struct.field(oracle_pair, {array: true}) - oracle_pairs!: oracle_pair[] + declare oracle_pairs: oracle_pair[] } @Struct.type('configure') export class configure extends Struct { @Struct.field(Asset.Symbol) - token_symbol!: Asset.Symbol + declare token_symbol: Asset.Symbol @Struct.field(Name) - oracle_account!: Name + declare oracle_account: Name @Struct.field(oracle_pair, {array: true}) - oracle_pairs!: oracle_pair[] + declare oracle_pairs: oracle_pair[] } @Struct.type('deluser') export class deluser extends Struct { @Struct.field(Name) - account!: Name + declare account: Name } @Struct.type('price_info') export class price_info extends Struct { @Struct.field('string') - pair!: string + declare pair: string @Struct.field(Float64) - price!: Float64 + declare price: Float64 @Struct.field(TimePoint) - timestamp!: TimePoint + declare timestamp: TimePoint } @Struct.type('receipt') export class receipt extends Struct { @Struct.field(Name) - account!: Name + declare account: Name @Struct.field(Asset) - amount!: Asset + declare amount: Asset @Struct.field(price_info, {array: true}) - ticker!: price_info[] + declare ticker: price_info[] } @Struct.type('updateuser') export class updateuser extends Struct { @Struct.field(Name) - account!: Name + declare account: Name @Struct.field(UInt16) - weight!: UInt16 + declare weight: UInt16 } @Struct.type('user_row') export class user_row extends Struct { @Struct.field(Name) - account!: Name + declare account: Name @Struct.field(UInt16) - weight!: UInt16 + declare weight: UInt16 @Struct.field(Asset) - balance!: Asset + declare balance: Asset } } export const TableMap = { diff --git a/test/data/contracts/mock-testing.gm.ts b/test/data/contracts/mock-testing.gm.ts index 685c3dd..2a976e1 100644 --- a/test/data/contracts/mock-testing.gm.ts +++ b/test/data/contracts/mock-testing.gm.ts @@ -21,106 +21,106 @@ export namespace Types { @Struct.type('api_response') export class api_response extends Struct { @Struct.field(UInt64) - foo!: UInt64 + declare foo: UInt64 } @Struct.type('callapi') export class callapi extends Struct {} @Struct.type('account_row') export class account_row extends Struct { @Struct.field(Name) - account!: Name + declare account: Name @Struct.field(UInt32) - seeds!: UInt32 + declare seeds: UInt32 } @Struct.type('addoracle') export class addoracle extends Struct { @Struct.field(Name) - oracle!: Name + declare oracle: Name } @Struct.type('advance') export class advance extends Struct {} @Struct.type('commit') export class commit extends Struct { @Struct.field(Name) - oracle!: Name + declare oracle: Name @Struct.field(UInt64) - epoch!: UInt64 + declare epoch: UInt64 @Struct.field(Checksum256) - commit!: Checksum256 + declare commit: Checksum256 } @Struct.type('commit_row') export class commit_row extends Struct { @Struct.field(UInt64) - id!: UInt64 + declare id: UInt64 @Struct.field(UInt64) - epoch!: UInt64 + declare epoch: UInt64 @Struct.field(Name) - oracle!: Name + declare oracle: Name @Struct.field(Checksum256) - commit!: Checksum256 + declare commit: Checksum256 } @Struct.type('compute') export class compute extends Struct { @Struct.field(UInt64) - epoch!: UInt64 + declare epoch: UInt64 @Struct.field(UInt64) - seed!: UInt64 + declare seed: UInt64 } @Struct.type('destroy') export class destroy extends Struct { @Struct.field(Name) - owner!: Name + declare owner: Name @Struct.field(UInt64, {array: true}) - to_destroy!: UInt64[] + declare to_destroy: UInt64[] } @Struct.type('destroy_return_value') export class destroy_return_value extends Struct { @Struct.field(UInt64) - ram_sold!: UInt64 + declare ram_sold: UInt64 @Struct.field(Asset) - redeemed!: Asset + declare redeemed: Asset } @Struct.type('destroyall') export class destroyall extends Struct {} @Struct.type('enable') export class enable extends Struct { @Struct.field('bool') - enabled!: boolean + declare enabled: boolean } @Struct.type('enroll') export class enroll extends Struct { @Struct.field(Name) - account!: Name + declare account: Name @Struct.field(UInt64) - epoch!: UInt64 + declare epoch: UInt64 } @Struct.type('epoch_row') export class epoch_row extends Struct { @Struct.field(UInt64) - epoch!: UInt64 + declare epoch: UInt64 @Struct.field(TimePoint) - start!: TimePoint + declare start: TimePoint @Struct.field(TimePoint) - end!: TimePoint + declare end: TimePoint @Struct.field(TimePoint) - reveal!: TimePoint + declare reveal: TimePoint @Struct.field(TimePoint) - complete!: TimePoint + declare complete: TimePoint } @Struct.type('generate_return_value') export class generate_return_value extends Struct { @Struct.field(UInt32) - seeds!: UInt32 + declare seeds: UInt32 @Struct.field(UInt64) - epoch!: UInt64 + declare epoch: UInt64 @Struct.field(Asset) - cost!: Asset + declare cost: Asset @Struct.field(Asset) - refund!: Asset + declare refund: Asset @Struct.field(UInt64) - total_seeds!: UInt64 + declare total_seeds: UInt64 @Struct.field(UInt64) - epoch_seeds!: UInt64 + declare epoch_seeds: UInt64 } @Struct.type('generatertrn') export class generatertrn extends Struct {} @@ -129,70 +129,70 @@ export namespace Types { @Struct.type('oracle_row') export class oracle_row extends Struct { @Struct.field(Name) - oracle!: Name + declare oracle: Name } @Struct.type('removeoracle') export class removeoracle extends Struct { @Struct.field(Name) - oracle!: Name + declare oracle: Name } @Struct.type('reveal') export class reveal extends Struct { @Struct.field(Name) - oracle!: Name + declare oracle: Name @Struct.field(UInt64) - epoch!: UInt64 + declare epoch: UInt64 @Struct.field('string') - reveal!: string + declare reveal: string } @Struct.type('reveal_row') export class reveal_row extends Struct { @Struct.field(UInt64) - id!: UInt64 + declare id: UInt64 @Struct.field(UInt64) - epoch!: UInt64 + declare epoch: UInt64 @Struct.field(Name) - oracle!: Name + declare oracle: Name @Struct.field('string') - reveal!: string + declare reveal: string } @Struct.type('seed_row') export class seed_row extends Struct { @Struct.field(UInt64) - seed!: UInt64 + declare seed: UInt64 @Struct.field(Name) - owner!: Name + declare owner: Name @Struct.field(UInt64) - epoch!: UInt64 + declare epoch: UInt64 } @Struct.type('stat_row') export class stat_row extends Struct { @Struct.field(UInt64) - id!: UInt64 + declare id: UInt64 @Struct.field(Name) - account!: Name + declare account: Name @Struct.field(UInt64) - epoch!: UInt64 + declare epoch: UInt64 @Struct.field(UInt32) - seeds!: UInt32 + declare seeds: UInt32 } @Struct.type('state_row') export class state_row extends Struct { @Struct.field(UInt16) - id!: UInt16 + declare id: UInt16 @Struct.field(UInt64) - epoch!: UInt64 + declare epoch: UInt64 @Struct.field('bool') - enabled!: boolean + declare enabled: boolean } @Struct.type('transfer') export class transfer extends Struct { @Struct.field(Name) - from!: Name + declare from: Name @Struct.field(Name) - to!: Name + declare to: Name @Struct.field(UInt64, {array: true}) - to_transfer!: UInt64[] + declare to_transfer: UInt64[] } @Struct.type('wipe') export class wipe extends Struct {}