"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.Address = void 0;
class Address {
    id;
    address;
    type;
    walletId;
    isPrimary;
    createdAt;
    updatedAt;
    constructor(id, address, type, walletId, isPrimary, createdAt, updatedAt) {
        this.id = id;
        this.address = address;
        this.type = type;
        this.walletId = walletId;
        this.isPrimary = isPrimary;
        this.createdAt = createdAt;
        this.updatedAt = updatedAt;
    }
    static create(id, address, type, walletId, isPrimary = false) {
        const now = new Date();
        return new Address(id, address, type, walletId, isPrimary, now, now);
    }
    setPrimary(isPrimary) {
        return new Address(this.id, this.address, this.type, this.walletId, isPrimary, this.createdAt, new Date());
    }
}
exports.Address = Address;
//# sourceMappingURL=address.js.map