Class DeterministicDeployer

wrapper class for Arachnid's deterministic deployer (deterministic deployer used by 'hardhat-deployer'. generates the same addresses as "hardhat-deploy")

Hierarchy

  • DeterministicDeployer

Index

Constructors

constructor

Properties

deploymentGasLimit

deploymentGasLimit: number = 100000

deploymentGasPrice

deploymentGasPrice: number = 100000000000

deploymentSignerAddress

deploymentSignerAddress: string = "0x3fab184622dc19b6109349b94811493bf2a45362"

deploymentTransaction

deploymentTransaction: string = "0xf8a58085174876e800830186a08080b853604580600e600039806000f350fe7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe03601600081602082378035828234f58015156039578182fd5b8082525050506014600cf31ba02222222222222222222222222222222222222222222222222222222222222222a02222222222222222222222222222222222222222222222222222222222222222"

Readonly provider

provider: JsonRpcProvider

proxyAddress

proxyAddress: string = "0x4e59b44847b379578588920ca78fbf26c0b4956c"

Accessors

Static instance

Methods

deployDeployer

  • deployDeployer(): Promise<void>
  • Returns Promise<void>

deterministicDeploy

  • deterministicDeploy(ctrCode: string, salt?: BigNumberish): Promise<string>
  • Parameters

    • ctrCode: string
    • Default value salt: BigNumberish = 0

    Returns Promise<string>

getDeployTransaction

  • getDeployTransaction(ctrCode: string, salt?: BigNumberish): Promise<TransactionRequest>
  • Parameters

    • ctrCode: string
    • Default value salt: BigNumberish = 0

    Returns Promise<TransactionRequest>

getDeterministicDeployAddress

  • getDeterministicDeployAddress(ctrCode: string, salt?: BigNumberish): Promise<string>
  • Parameters

    • ctrCode: string
    • Default value salt: BigNumberish = 0

    Returns Promise<string>

isContractDeployed

  • isContractDeployed(address: string): Promise<boolean>
  • Parameters

    • address: string

    Returns Promise<boolean>

isDeployerDeployed

  • isDeployerDeployed(): Promise<boolean>
  • Returns Promise<boolean>

Static deploy

  • deploy(ctrCode: string, salt?: BigNumberish): Promise<string>
  • deploy the contract, unless already deployed

    Parameters

    • ctrCode: string

      constructor code to pass to CREATE2

    • Default value salt: BigNumberish = 0

      optional salt. defaults to zero

    Returns Promise<string>

    the deployed address

Static getAddress

  • getAddress(ctrCode: string, salt?: BigNumberish): Promise<string>
  • return the address this code will get deployed to.

    Parameters

    • ctrCode: string

      constructor code to pass to CREATE2

    • Default value salt: BigNumberish = 0

      optional salt. defaults to zero

    Returns Promise<string>

Static init

  • init(provider: JsonRpcProvider): void
  • Parameters

    • provider: JsonRpcProvider

    Returns void