Options
All
  • Public
  • Public/Protected
  • All
Menu

Hierarchy

  • Adapter
    • WarperPresetFactoryAdapter

Index

Constructors

Properties

addressTranslator: AddressTranslator
contractResolver: ContractResolver

Methods

  • accountIdToAddress(accountId: AccountId): string
  • Parameters

    • accountId: AccountId

    Returns string

  • addPreset(presetId: BytesLike, implementation: AccountId): Promise<ContractTransaction>
  • Stores the association between presetId and implementation address. Warper implementation must be deployed beforehand.

    Parameters

    • presetId: BytesLike

      Warper preset ID.

    • implementation: AccountId

      Warper implementation account ID.

    Returns Promise<ContractTransaction>

  • addressToAccountId(address: string): AccountId
  • Parameters

    • address: string

    Returns AccountId

  • addressToAssetType(address: string, namespace: string): AssetType
  • Parameters

    • address: string
    • namespace: string

    Returns AssetType

  • assetIdToAddress(assetId: AssetId): string
  • Parameters

    • assetId: AssetId

    Returns string

  • assetTypeToAddress(assetType: AssetType): string
  • Parameters

    • assetType: AssetType

    Returns string

  • decodeAgreementTerms(params: AgreementTermsStruct): AgreementTerms
  • Parameters

    • params: AgreementTermsStruct

    Returns AgreementTerms

  • decodeAsset(asset: AssetStructOutput): Asset
  • Parameters

    • asset: AssetStructOutput

    Returns Asset

  • deployPreset(presetId: BytesLike, initData: BytesLike): Promise<ContractTransaction>
  • Deploys new instance of warper from preset.

    Parameters

    • presetId: BytesLike

      Warper preset ID.

    • initData: BytesLike

      Preset initialization data.

    Returns Promise<ContractTransaction>

  • disablePreset(presetId: BytesLike): Promise<ContractTransaction>
  • Disable warper preset, which makes non-deployable.

    Parameters

    • presetId: BytesLike

      Warper preset ID.

    Returns Promise<ContractTransaction>

  • enablePreset(presetId: BytesLike): Promise<ContractTransaction>
  • Enables warper preset, which makes it deployable.

    Parameters

    • presetId: BytesLike

      Warper preset ID.

    Returns Promise<ContractTransaction>

  • encodeAsset(asset: Asset): AssetStruct
  • Parameters

    Returns AssetStruct

  • erc20AssetMetadata(assetType: AssetType): Promise<{ decimals: number; name: string; symbol: string }>
  • Parameters

    • assetType: AssetType

    Returns Promise<{ decimals: number; name: string; symbol: string }>

  • findWarperByDeploymentTransaction(transactionHash: string): Promise<undefined | AssetType>
  • Retrieves the warper reference from deployment transaction.

    Parameters

    • transactionHash: string

    Returns Promise<undefined | AssetType>

  • getChainId(): Promise<ChainId>
  • Returns Promise<ChainId>

  • optionalAccountIdToAddress(accountId?: AccountId): undefined | string
  • Parameters

    • Optional accountId: AccountId

    Returns undefined | string

  • presetEnabled(presetId: BytesLike): Promise<boolean>
  • Checks whether warper preset is enabled and available for deployment.

    Parameters

    • presetId: BytesLike

      Warper preset ID.

    Returns Promise<boolean>

  • removePreset(presetId: BytesLike): Promise<ContractTransaction>
  • Removes the association between presetId and its implementation.

    Parameters

    • presetId: BytesLike

      Warper preset ID.

    Returns Promise<ContractTransaction>

Generated using TypeDoc