• Sets a key-value pair in the datastore of the given address. Existing entries are overwritten and missing ones are created.

    Remarks

    Can only be called at smart contract generation time by the parent smart contract to the child's address.

    Throws

    • if the given address is not a valid address.
    • [compilation only] if the key and value type are neither string, StaticArray<u8>, or Args.

    Type Parameters

    • T

      Can be either string, Args, or StaticArray.

    Parameters

    • address: Address

      The child smart contract address.

    • key: T

      The key to set in the datastore.

    • value: T

      The value to associate with the key in the datastore.

    Returns void

Generated using TypeDoc