"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.DashTransaction = exports.ZcashTransaction = exports.Transaction = void 0;
const wasm_utxo_js_1 = require("./wasm/wasm_utxo.js");
/**
 * Transaction wrapper (Bitcoin-like networks)
 *
 * Provides a camelCase, strongly-typed API over the snake_case WASM bindings.
 */
class Transaction {
    _wasm;
    constructor(_wasm) {
        this._wasm = _wasm;
    }
    static fromBytes(bytes) {
        return new Transaction(wasm_utxo_js_1.WasmTransaction.from_bytes(bytes));
    }
    toBytes() {
        return this._wasm.to_bytes();
    }
    /**
     * @internal
     */
    get wasm() {
        return this._wasm;
    }
}
exports.Transaction = Transaction;
/**
 * Zcash Transaction wrapper
 *
 * Provides a camelCase, strongly-typed API over the snake_case WASM bindings.
 */
class ZcashTransaction {
    _wasm;
    constructor(_wasm) {
        this._wasm = _wasm;
    }
    static fromBytes(bytes) {
        return new ZcashTransaction(wasm_utxo_js_1.WasmZcashTransaction.from_bytes(bytes));
    }
    toBytes() {
        return this._wasm.to_bytes();
    }
    /**
     * @internal
     */
    get wasm() {
        return this._wasm;
    }
}
exports.ZcashTransaction = ZcashTransaction;
/**
 * Dash Transaction wrapper (supports EVO special transactions)
 *
 * Round-trip only: bytes -> parse -> bytes.
 */
class DashTransaction {
    _wasm;
    constructor(_wasm) {
        this._wasm = _wasm;
    }
    static fromBytes(bytes) {
        return new DashTransaction(wasm_utxo_js_1.WasmDashTransaction.from_bytes(bytes));
    }
    toBytes() {
        return this._wasm.to_bytes();
    }
    /**
     * @internal
     */
    get wasm() {
        return this._wasm;
    }
}
exports.DashTransaction = DashTransaction;
