/* Autogenerated file, do not edit! */
import { EventSelector, loadContractArtifact, loadContractArtifactForPublic } from '@aztec/aztec.js/abi';
import { Contract, ContractBase, DeployMethod } from '@aztec/aztec.js/contracts';
import { Fr } from '@aztec/aztec.js/fields';
import TestLogicContractArtifactJson from '../../target/test_logic_contract-TestLogic.json' with { type: 'json' };
export const TestLogicContractArtifact = loadContractArtifact(TestLogicContractArtifactJson);
/**
 * Type-safe interface for contract TestLogic;
 */
export class TestLogicContract extends ContractBase {
    constructor(address, wallet) {
        super(address, TestLogicContractArtifact, wallet);
    }
    /**
     * Creates a contract instance.
     * @param address - The deployed contract's address.
     * @param wallet - The wallet to use when interacting with the contract.
     * @returns A new Contract instance.
     */
    static at(address, wallet) {
        return Contract.at(address, TestLogicContract.artifact, wallet);
    }
    /**
     * Creates a tx to deploy a new instance of this contract.
     * @param instantiation - Optional address-affecting parameters (salt, deployer / universalDeploy, publicKeys).
     *                       Salt defaults to a random value; the deployer is locked lazily from the first send-time `from`.
     */
    static deploy(wallet, escrow_class_id, instantiation) {
        return DeployMethod.create(wallet, {
            artifact: TestLogicContractArtifact,
            postDeployCtor: (instance, wallet) => TestLogicContract.at(instance.address, wallet),
            args: [escrow_class_id],
        }, instantiation);
    }
    /**
     * Creates a tx to deploy a new instance of this contract using the specified constructor method.
     */
    static deployWithOpts(opts, ...args) {
        return DeployMethod.create(opts.wallet, {
            artifact: TestLogicContractArtifact,
            postDeployCtor: (instance, wallet) => TestLogicContract.at(instance.address, wallet),
            args,
            constructorNameOrArtifact: opts.method ?? 'constructor',
        }, opts.instantiation);
    }
    /**
     * Returns this contract's artifact.
     */
    static get artifact() {
        return TestLogicContractArtifact;
    }
    /**
     * Returns this contract's artifact with public bytecode.
     */
    static get artifactForPublic() {
        return loadContractArtifactForPublic(TestLogicContractArtifactJson);
    }
    static get storage() {
        return {
            escrow_class_id: {
                slot: new Fr(1n),
            }
        };
    }
    static get events() {
        return {
            EscrowDetailsLogContent: {
                abiType: {
                    "kind": "struct",
                    "fields": [
                        {
                            "name": "escrow",
                            "type": {
                                "kind": "struct",
                                "fields": [
                                    {
                                        "name": "inner",
                                        "type": {
                                            "kind": "field"
                                        }
                                    }
                                ],
                                "path": "aztec::protocol_types::address::aztec_address::AztecAddress"
                            }
                        },
                        {
                            "name": "secret_key",
                            "type": {
                                "kind": "field"
                            }
                        }
                    ],
                    "path": "TestLogic::EscrowDetailsLogContent"
                },
                eventSelector: EventSelector.fromString("0xcdaba585"),
                fieldNames: ["escrow", "secret_key"],
            }
        };
    }
}
