Skip to content Search Apps Documentation Source Content File Folder Download Copy Actions State String Boolean Number Struct Map Slice Pointer Function Closure Reference Nil Package Type Interface Unknown

Community realm. Read the code first. Community realm, deployed by its author. Read the code before you interact or send coins.

v0 state

Back to all declarations

test1

.uverse.address

test1 receives the initial mint at construction.

Value

<gnolang.StringValue>

lockDuration

int64

lockDuration is the number of blocks that must pass between Unvault and Redeem.

Value

100

Token

*v0.Token

Token and FooVault-equivalent state are exported for reading; privateLedger stays unexported (unrestricted mint/burn/transfer).

Open
OID
02d51b…7afb:22
Token details

Inspect pointer

privateLedger

*v0.PrivateLedger

Token and FooVault-equivalent state are exported for reading; privateLedger stays unexported (unrestricted mint/burn/transfer).

Open
OID
02d51b…7afb:24
privateLedger details

Inspect pointer

vaultAddr

.uverse.address

// address holding all deposited tokens

Value

<gnolang.StringValue>

vaulted

map[.uverse.address]uint

// still-locked deposits per owner

Open
OID
02d51b…7afb:8
vaulted details

Inspect map

pending

map[.uverse.address]uint

// amount marked for withdrawal

Open
OID
02d51b…7afb:10
pending details

Inspect map

unlockAt

map[.uverse.address]int64

// block height at which pending unlocks

Open
OID
02d51b…7afb:12
unlockAt details

Inspect map

recoverOf

map[.uverse.address].uverse.address

// recovery address per depositor

Open
OID
02d51b…7afb:14
recoverOf details

Inspect map

Deposit

func(amount uint, recoverAddress .uverse.address)

Deposit moves amount tokens from the caller into the vault, recording a recovery address for later use.

Open
OID
02d51b…7afb:18
Deposit details

Inspect func

Recover

func(target .uverse.address)

Recover sends target's still-locked deposit to its recorded recovery address.

Open
OID
02d51b…7afb:19
Recover details

Inspect func

Unvault

func(amount uint)

Unvault marks amount of the caller's deposit for withdrawal and starts the lock timer.

Open
OID
02d51b…7afb:20
Unvault details

Inspect func

Redeem

func(amount uint)

Redeem transfers amount of the caller's matured pending withdrawal back to the caller.

Open
OID
02d51b…7afb:21
Redeem details

Inspect func
test1 : .uverse.address =<gnolang.StringValue>
lockDuration : int64 =100
Token : *v0.Token Inspect
privateLedger : *v0.PrivateLedger Inspect
vaultAddr : .uverse.address =<gnolang.StringValue>
vaulted : map[.uverse.address]uint Inspect
pending : map[.uverse.address]uint Inspect
unlockAt : map[.uverse.address]int64 Inspect
recoverOf : map[.uverse.address].uverse.address Inspect
init.9 : func() Inspect
MyBalance : func() int64 Inspect
Deposit : func(amount uint, recoverAddress .uverse.address) Inspect
Recover : func(target .uverse.address) Inspect
Unvault : func(amount uint) Inspect
Redeem : func(amount uint) Inspect