#i?: number\r
#f?: string\r
#b?: bigint\r
- #p?: bigint\r
- #r?: Account\r
+ #r?: bigint\r
+ #rep?: Account\r
#w?: bigint\r
#s: Safe\r
\r
get index () { return this.#i }\r
get frontier () { return this.#f }\r
get balance () { return this.#b?.toString() }\r
- get pending () { return this.#p?.toString() }\r
- get representative () { return this.#r }\r
+ get receivable () { return this.#r?.toString() }\r
+ get representative () { return this.#rep }\r
get weight () { return this.#w?.toString() }\r
\r
set frontier (v) { this.#f = v }\r
set balance (v) { this.#b = v ? BigInt(v) : undefined }\r
- set pending (v) { this.#p = v ? BigInt(v) : undefined }\r
+ set receivable (v) { this.#r = v ? BigInt(v) : undefined }\r
set representative (v) {\r
if (v?.constructor === Account) {\r
- this.#r = v\r
+ this.#rep = v\r
} else if (typeof v === 'string') {\r
- this.#r = new Account(v)\r
+ this.#rep = new Account(v)\r
} else {\r
throw new TypeError(`Invalid argument for account representative: ${v}`)\r
}\r
}\r
this.#b = BigInt(balance)\r
this.#f = frontier\r
- this.#p = BigInt(pending)\r
- this.#r = new Account(representative)\r
+ this.#r = BigInt(pending)\r
+ this.#rep = new Account(representative)\r
this.#w = BigInt(weight)\r
}\r
\r