@hashgraph/sdk
    Preparing search index...

    Class ContractCreateFlow

    A convenience flow that handles the creation of a smart contract on the Hedera network. This flow abstracts away the complexity of the contract creation process by:

    1. Creating a file to store the contract bytecode
    2. Uploading the contract bytecode in chunks if necessary
    3. Creating the contract instance using the uploaded bytecode
    4. Cleaning up by deleting the bytecode file (if operator key is available)

    This flow is particularly useful when deploying large contracts that exceed the 2048 byte limit of a single transaction.

    Index

    Constructors

    Properties

    _bytecode: null | Uint8Array<ArrayBufferLike>
    _contractCreate: ContractCreateTransaction
    _maxChunks: null | number

    Accessors

    Methods

    • Sign the transaction with the public key and signer function

      If sign on demand is enabled no signing will be done immediately, instead the private key signing function and public key are saved to be used when a user calls an exit condition method (not sure what a better name for this is) such as toBytes[Async](), getTransactionHash[PerNode]() or execute().

      Parameters

      • publicKey: PublicKey
      • transactionSigner: (message: Uint8Array) => Promise<Uint8Array<ArrayBufferLike>>

      Returns ContractCreateFlow