subnetevents

package
v0.27.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 28, 2021 License: GPL-3.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ParseDelete

func ParseDelete(e *subscriptions.NotificationEvent) (event.Event, error)

ParseDelete parses the notification about the removal of a subnet which has been thrown by the appropriate method of the Subnet contract.

Resulting event is of Delete type.

func ParseNotaryPut

func ParseNotaryPut(e event.NotaryEvent) (event.Event, error)

ParseNotaryPut parses the notary notification about the creation of a subnet which has been thrown by the appropriate method of the subnet contract.

Resulting event is of Put type.

func ParsePut

ParsePut parses the notification about the creation of a subnet which has been thrown by the appropriate method of the subnet contract.

Resulting event is of Put type.

func ParseRemoveNode

func ParseRemoveNode(e *subscriptions.NotificationEvent) (event.Event, error)

ParseRemoveNode parses notification into subnet event structure.

Expects 2 stack items.

Types

type Delete

type Delete struct {
	// contains filtered or unexported fields
}

Delete structures information about the notification generated by Delete method of Subnet contract.

func (Delete) ID

func (x Delete) ID() []byte

ID returns identifier of the removed subnet in a binary format of NeoFS API protocol.

func (Delete) MorphEvent

func (Delete) MorphEvent()

MorphEvent implements Neo:Morph Event interface.

func (Delete) TxHash

func (x Delete) TxHash() util.Uint256

TxHash returns hash of the transaction which thrown the notification event. Makes sense only in notary environments.

type Put

type Put struct {
	// contains filtered or unexported fields
}

Put structures information about the notification generated by Put method of Subnet contract.

func (Put) ID

func (x Put) ID() []byte

ID returns identifier of the creating subnet in a binary format of NeoFS API protocol.

func (Put) Info

func (x Put) Info() []byte

Info returns information about the subnet in a binary format of NeoFS API protocol.

func (Put) MorphEvent

func (Put) MorphEvent()

MorphEvent implements Neo:Morph Event interface.

func (Put) NotaryMainTx

func (x Put) NotaryMainTx() *transaction.Transaction

NotaryMainTx returns main transaction of the request in the Notary service. Returns nil in non-notary environments.

func (Put) Owner

func (x Put) Owner() []byte

Owner returns subnet owner's public key in a binary format.

func (Put) TxHash

func (x Put) TxHash() util.Uint256

TxHash returns hash of the transaction which thrown the notification event. Makes sense only in notary environments.

type RemoveNode

type RemoveNode struct {
	// contains filtered or unexported fields
}

RemoveNode structure of subnet.RemoveNode notification from morph chain.

func (RemoveNode) MorphEvent

func (RemoveNode) MorphEvent()

MorphEvent implements Neo:Morph Event interface.

func (RemoveNode) Node

func (rn RemoveNode) Node() []byte

Node is public key of the nodeKey that is being deleted.

func (RemoveNode) SubnetworkID

func (rn RemoveNode) SubnetworkID() []byte

SubnetworkID returns a marshalled subnetID structure, defined in API.

func (RemoveNode) TxHash

func (rn RemoveNode) TxHash() util.Uint256

TxHash returns hash of the TX with RemoveNode notification.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL