Documentation
¶
Index ¶
- Constants
- func BytesEqual(a []byte, b []byte) bool
- func GetList(ctx storage.Context, key interface{}) [][]byte
- func HasUpdateAccess(ctx storage.Context) bool
- func InitVote(ctx storage.Context)
- func InnerRingInvoker(ir []IRNode) []byte
- func InvokeID(args []interface{}, prefix []byte) []byte
- func RemoveVotes(ctx storage.Context, id []byte)
- func SetSerialized(ctx storage.Context, key interface{}, value interface{})
- func Vote(ctx storage.Context, id, from []byte) int
- type Ballot
- type IRNode
Constants ¶
const OwnerKey = "contractOwner"
Variables ¶
This section is empty.
Functions ¶
func BytesEqual ¶
BytesEqual compares two slice of bytes by wrapping them into strings, which is necessary with new util.Equal interop behaviour, see neo-go#1176.
func HasUpdateAccess ¶
HasUpdateAccess returns true if contract can be initialized, re-initialized or migrated.
func InnerRingInvoker ¶
InnerRingInvoker returns public key of inner ring node that invoked contract.
func RemoveVotes ¶
RemoveVotes clears ballots of the decision that has been accepted by inner ring nodes.
func SetSerialized ¶
SetSerialized serializes data and puts it into contract storage.
Types ¶
type IRNode ¶
type IRNode struct {
PublicKey []byte
}
func InnerRingList ¶
InnerRingList gets list of inner ring through calling "innerRingList" method of smart contract.
func InnerRingListViaStorage ¶
InnerRingList returns list of inner ring nodes through calling "innerRingList" method of smart contract.
Address of smart contract is received from storage by key.