Skip to main content

Debt

Dev

Structure to store the debts of users

Param

The tokenX's debt

Param

The tokenY's debt

Implements

  • Serializable

Table of contents

Constructors

Properties

Methods

Constructors

constructor

new Debt(debtX?, debtY?): Debt

Parameters

NameTypeDefault value
debtXu256u256.Zero
debtYu256u256.Zero

Returns

Debt

Defined in

assembly/structs/Debt.ts:10

Properties

debtX

debtX: u256 = u256.Zero

Defined in

assembly/structs/Debt.ts:11


debtY

debtY: u256 = u256.Zero

Defined in

assembly/structs/Debt.ts:12

Methods

deserialize

deserialize(data, offset): Result<i32>

Parameters

NameType
dataStaticArray<u8>
offseti32

Returns

Result<i32>

Implementation of

Serializable.deserialize

Defined in

assembly/structs/Debt.ts:19


serialize

serialize(): StaticArray<u8>

Returns

StaticArray<u8>

Implementation of

Serializable.serialize

Defined in

assembly/structs/Debt.ts:15