staker.gno

Delegates/Undeleates GNS for governance.

Delegate

func Delegate(
    to std.Address
    amount uint64
)

Delegates GNS to a delegate.

Parameters

Name
Type
Description

to

std.Address

The address to delegate.

amount

uint64

The amount of GNS.

Redelegate

func Relegate(
  from std.Address
  to std.Address
  amount uint64
) 

Redelegates xGNS from the existing delegate to another.

Parameters

Name
Type
Description

from

std.Address

The address to undelegate.

to

std.Address

The address to delegate.

amount

uint64

The amount of xGNS.

Undelegate

func Undelegate(
  from std.Address
  amount uint64
) 

Undelegates xGNS from the existing delegate.

Parameters

Name
Type
Description

from

std.Address

The address to undelegate.

amount

uint64

The amount of xGNS.

Return Values

Name
Type
Description

tokenId

uint64

The ID of the position.

CollectUndelegatedGns

func CollectUndelegatedGns() uint64

Collects the amount of the undelegated GNS.

Return Values

Name
Type
Description

amount

uint64

The amount of GNS token collected.

CollectReward

func CollectReward()

Collects the rewards from the protocol fee contract based on the holdings of xGNS.

CollectRewardFromLaunchPad

func CollectRewardFromLaunchPad(to std.Address)

Collects the rewards from the protocol fee contract based on the holdings of xGNS in the launchpad contract (only callable by the launchpad contract).

Parameters

Name
Type
Description

to

std.Address

The address to delegate.

Return Values

Name
Type
Description

tokenId

uint64

The ID of the position.

Last updated

Was this helpful?