Options
All
  • Public
  • Public/Protected
  • All
Menu

Class Core

Hierarchy

  • Core

Index

Constructors

constructor

  • new Core(params: object): Core

Properties

classes

classes: object = Core.classes

Type declaration

Methods

createAssetMintTransaction

createAssetOutPoint

createAssetScheme

  • Creates asset's scheme.

    throws

    Given string for registrar is invalid for converting it to paltform account

    Parameters

    • params: object
      • amount: number

        Total amount of this asset

      • metadata: string

        Any string that describing the asset. For example, stringified JSON containing properties.

      • Optional registrar?: PlatformAddress | string

        Platform account or null. If account is present, the parcel that includes AssetTransferTransaction of this asset must be signed by the registrar account.

      • shardId: number
      • worldId: number

    Returns AssetScheme

createAssetTransferInput

createAssetTransferOutput

createAssetTransferTransaction

createChangeShardStateParcel

  • createChangeShardStateParcel(params: object): Parcel
  • Creates ChangeShardState action which can mint or transfer assets through AssetMintTransaction or AssetTransferTransaction.

    Parameters

    • params: object

    Returns Parcel

createCreateShardParcel

  • createCreateShardParcel(): Parcel

createCreateWorldTransaction

createPaymentParcel

  • createPaymentParcel(params: object): Parcel
  • Creates Payment action which pays the value amount of CCC(CodeChain Coin) from the parcel signer to the recipient. Who is signing the parcel will pay.

    throws

    Given string for recipient is invalid for converting it to PlatformAddress

    throws

    Given number or string for amount is invalid for converting it to U256

    Parameters

    • params: object
      • amount: U256 | number | string

        Amount of CCC to pay

      • recipient: PlatformAddress | string

        The platform account who receives CCC

    Returns Parcel

createSetRegularKeyParcel

  • createSetRegularKeyParcel(params: object): Parcel
  • Creates SetRegularKey action which sets the regular key of the parcel signer.

    throws

    Given string for key is invalid for converting it to H512

    Parameters

    • params: object
      • key: H512 | string

        The public key of a regular key

    Returns Parcel

createSetShardOwnersParcel

  • createSetShardOwnersParcel(params: object): Parcel

createSetShardUsersParcel

  • createSetShardUsersParcel(params: object): Parcel

createSetWorldOwnersTransaction

createSetWorldUsersTransaction

getTransactionFromJSON

Object literals

Static classes

classes: object

Asset

Asset: Asset

AssetMintTransaction

AssetMintTransaction: AssetMintTransaction

AssetOutPoint

AssetOutPoint: AssetOutPoint

AssetScheme

AssetScheme: AssetScheme

AssetTransferInput

AssetTransferInput: AssetTransferInput

AssetTransferOutput

AssetTransferOutput: AssetTransferOutput

AssetTransferTransaction

AssetTransferTransaction: AssetTransferTransaction

Block

Block: Block

ChangeShardState

ChangeShardState: ChangeShardState

CreateShard

CreateShard: CreateShard

CreateWorldTransaction

CreateWorldTransaction: CreateWorldTransaction

H160

H160: H160

H256

H256: H256

H512

H512: H512

Invoice

Invoice: Invoice

Parcel

Parcel: Parcel

Payment

Payment: Payment

Script

Script: Script

SetRegularKey

SetRegularKey: SetRegularKey

SetShardOwners

SetShardOwners: SetShardOwners

SetShardUsers

SetShardUsers: SetShardUsers

SetWorldOwnersTransaction

SetWorldOwnersTransaction: SetWorldOwnersTransaction

SetWorldUsersTransaction

SetWorldUsersTransaction: SetWorldUsersTransaction

SignedParcel

SignedParcel: SignedParcel

U256

U256: U256

Generated using TypeDoc