Documentation ¶
Overview ¶
Package nft provides a core of a Non-fungible token implementation (NFT). Specialized implementations are located in submodules.
This package is a data container. Think of it as an implementation of a document store with permission (approval) control and possibility to create more than one index for each document. It does not provide a standalone implementation. This is a framework for building custom NFT implementations.
Index ¶
- Constants
- Variables
- func FindActor(auth x.Authenticator, ctx weave.Context, t BaseNFT, action Action) weave.Address
- func PrintableID(id []byte) string
- func RegisterAction(actions ...Action)
- func WithOwnerIndex(bucket orm.Bucket) orm.Bucket
- type Action
- type ActionApprovals
- func (m ActionApprovals) Clone() ActionApprovals
- func (*ActionApprovals) Descriptor() ([]byte, []int)
- func (m *ActionApprovals) GetApprovals() []Approval
- func (m *ActionApprovals) Marshal() (dAtA []byte, err error)
- func (m *ActionApprovals) MarshalTo(dAtA []byte) (int, error)
- func (*ActionApprovals) ProtoMessage()
- func (m *ActionApprovals) Reset()
- func (m *ActionApprovals) Size() (n int)
- func (m *ActionApprovals) String() string
- func (m *ActionApprovals) Unmarshal(dAtA []byte) error
- func (m *ActionApprovals) XXX_DiscardUnknown()
- func (m *ActionApprovals) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *ActionApprovals) XXX_Merge(src proto.Message)
- func (m *ActionApprovals) XXX_Size() int
- func (m *ActionApprovals) XXX_Unmarshal(b []byte) error
- type AddApprovalMsg
- func (*AddApprovalMsg) Descriptor() ([]byte, []int)
- func (m *AddApprovalMsg) GetAddress() github_com_iov_one_weave.Address
- func (m *AddApprovalMsg) GetID() []byte
- func (m *AddApprovalMsg) GetMetadata() *weave.Metadata
- func (m *AddApprovalMsg) GetOptions() ApprovalOptions
- func (m *AddApprovalMsg) GetT() string
- func (m *AddApprovalMsg) Marshal() (dAtA []byte, err error)
- func (m *AddApprovalMsg) MarshalTo(dAtA []byte) (int, error)
- func (*AddApprovalMsg) Path() string
- func (*AddApprovalMsg) ProtoMessage()
- func (m *AddApprovalMsg) Reset()
- func (m *AddApprovalMsg) Size() (n int)
- func (m *AddApprovalMsg) String() string
- func (m *AddApprovalMsg) Unmarshal(dAtA []byte) error
- func (m AddApprovalMsg) Validate() error
- func (m *AddApprovalMsg) XXX_DiscardUnknown()
- func (m *AddApprovalMsg) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *AddApprovalMsg) XXX_Merge(src proto.Message)
- func (m *AddApprovalMsg) XXX_Size() int
- func (m *AddApprovalMsg) XXX_Unmarshal(b []byte) error
- type Approval
- func (a Approval) AsAddress() weave.Address
- func (m Approval) Clone() Approval
- func (*Approval) Descriptor() ([]byte, []int)
- func (a Approval) Equals(o Approval) bool
- func (m *Approval) GetAddress() []byte
- func (m *Approval) GetOptions() ApprovalOptions
- func (m *Approval) Marshal() (dAtA []byte, err error)
- func (m *Approval) MarshalTo(dAtA []byte) (int, error)
- func (*Approval) ProtoMessage()
- func (m *Approval) Reset()
- func (m *Approval) Size() (n int)
- func (m *Approval) String() string
- func (m *Approval) Unmarshal(dAtA []byte) error
- func (m Approval) Validate() error
- func (m *Approval) XXX_DiscardUnknown()
- func (m *Approval) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *Approval) XXX_Merge(src proto.Message)
- func (m *Approval) XXX_Size() int
- func (m *Approval) XXX_Unmarshal(b []byte) error
- type ApprovalMeta
- type ApprovalMsg
- type ApprovalOps
- type ApprovalOptions
- func (*ApprovalOptions) Descriptor() ([]byte, []int)
- func (a ApprovalOptions) Equals(o ApprovalOptions) bool
- func (a ApprovalOptions) EqualsAfterUse(used ApprovalOptions) bool
- func (m *ApprovalOptions) GetCount() int64
- func (m *ApprovalOptions) GetImmutable() bool
- func (m *ApprovalOptions) GetUntilBlockHeight() int64
- func (m *ApprovalOptions) Marshal() (dAtA []byte, err error)
- func (m *ApprovalOptions) MarshalTo(dAtA []byte) (int, error)
- func (*ApprovalOptions) ProtoMessage()
- func (m *ApprovalOptions) Reset()
- func (m *ApprovalOptions) Size() (n int)
- func (m *ApprovalOptions) String() string
- func (m *ApprovalOptions) Unmarshal(dAtA []byte) error
- func (a ApprovalOptions) Validate() error
- func (m *ApprovalOptions) XXX_DiscardUnknown()
- func (m *ApprovalOptions) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *ApprovalOptions) XXX_Merge(src proto.Message)
- func (m *ApprovalOptions) XXX_Size() int
- func (m *ApprovalOptions) XXX_Unmarshal(b []byte) error
- type Approvals
- func (m Approvals) Add(action Action, approval Approval) Approvals
- func (m Approvals) AsPersistable() []ActionApprovals
- func (m Approvals) Filter(obsolete Approvals) Approvals
- func (m Approvals) FilterExpired(blockHeight int64) Approvals
- func (m Approvals) ForAction(action Action) Approvals
- func (m Approvals) ForAddress(addr weave.Address) Approvals
- func (m Approvals) Intersect(others Approvals) Approvals
- func (m Approvals) IsEmpty() bool
- func (m Approvals) MergeUsed(used Approvals) Approvals
- func (m Approvals) MetaByAction(action Action) ApprovalMeta
- func (m Approvals) UseCount() Approvals
- func (m Approvals) Validate(actionMaps ...map[Action]int32) error
- type BaseNFT
- type Identified
- type NonFungibleToken
- func (m *NonFungibleToken) Approvals() *ApprovalOps
- func (m *NonFungibleToken) Clone() *NonFungibleToken
- func (m *NonFungibleToken) Copy() orm.CloneableData
- func (*NonFungibleToken) Descriptor() ([]byte, []int)
- func (m *NonFungibleToken) GetActionApprovals() []ActionApprovals
- func (m *NonFungibleToken) GetID() []byte
- func (m *NonFungibleToken) GetMetadata() *weave.Metadata
- func (m *NonFungibleToken) GetOwner() github_com_iov_one_weave.Address
- func (m *NonFungibleToken) HasApproval(actor weave.Address, action Action) bool
- func (m *NonFungibleToken) Marshal() (dAtA []byte, err error)
- func (m *NonFungibleToken) MarshalTo(dAtA []byte) (int, error)
- func (u *NonFungibleToken) OwnerAddress() weave.Address
- func (*NonFungibleToken) ProtoMessage()
- func (m *NonFungibleToken) Reset()
- func (m *NonFungibleToken) SetApprovals(a Approvals)
- func (m *NonFungibleToken) Size() (n int)
- func (m *NonFungibleToken) String() string
- func (m *NonFungibleToken) Unmarshal(dAtA []byte) error
- func (m *NonFungibleToken) Validate() error
- func (m *NonFungibleToken) XXX_DiscardUnknown()
- func (m *NonFungibleToken) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *NonFungibleToken) XXX_Merge(src proto.Message)
- func (m *NonFungibleToken) XXX_Size() int
- func (m *NonFungibleToken) XXX_Unmarshal(b []byte) error
- type Owned
- type RemoveApprovalMsg
- func (*RemoveApprovalMsg) Descriptor() ([]byte, []int)
- func (m *RemoveApprovalMsg) GetAddress() github_com_iov_one_weave.Address
- func (m *RemoveApprovalMsg) GetID() []byte
- func (m *RemoveApprovalMsg) GetMetadata() *weave.Metadata
- func (m *RemoveApprovalMsg) GetT() string
- func (m *RemoveApprovalMsg) Marshal() (dAtA []byte, err error)
- func (m *RemoveApprovalMsg) MarshalTo(dAtA []byte) (int, error)
- func (*RemoveApprovalMsg) Path() string
- func (*RemoveApprovalMsg) ProtoMessage()
- func (m *RemoveApprovalMsg) Reset()
- func (m *RemoveApprovalMsg) Size() (n int)
- func (m *RemoveApprovalMsg) String() string
- func (m *RemoveApprovalMsg) Unmarshal(dAtA []byte) error
- func (m RemoveApprovalMsg) Validate() error
- func (m *RemoveApprovalMsg) XXX_DiscardUnknown()
- func (m *RemoveApprovalMsg) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *RemoveApprovalMsg) XXX_Merge(src proto.Message)
- func (m *RemoveApprovalMsg) XXX_Size() int
- func (m *RemoveApprovalMsg) XXX_Unmarshal(b []byte) error
Constants ¶
const ( PathAddApprovalMsg = "nft/approval/add" PathRemoveApprovalMsg = "nft/approval/remove" )
const OwnerIndexName = "owner"
OwnerIndexName is the index to query nft by owner
const UnlimitedCount = -1
const (
UnsupportedTokenType = "unsupported token type"
)
Variables ¶
var ( ErrInvalidLengthCodec = fmt.Errorf("proto: negative length found during unmarshaling") ErrIntOverflowCodec = fmt.Errorf("proto: integer overflow") )
var DefaultActions = []Action{ UpdateApprovals, UpdateDetails, Transfer, }
DefaultActions lists all the actions that need to be registered for nft to work
Functions ¶
func PrintableID ¶ added in v0.12.0
id's are stored as bytes, but most are ascii text if in ascii, just convert to string if not, hex-encode it and prefix with 0x
func RegisterAction ¶ added in v0.10.1
func RegisterAction(actions ...Action)
RegisterAction introduce an Action to the extension.
Every action must be registered before being used. This is a mandatory step so that the validation process can recognise known actions. Registration is global. Registration should be done during the program initialization phase. Failed registration result in panic.
Types ¶
type Action ¶
type Action string
Action represents available and supported by the implementation actions. This is just a string type alias, but using it increase the clarity of the API.
type ActionApprovals ¶
type ActionApprovals struct { Action Action `protobuf:"bytes,1,opt,name=action,proto3,customtype=Action" json:"action"` Approvals []Approval `protobuf:"bytes,2,rep,name=approvals,proto3" json:"approvals"` }
ActionApprovals are used to control permissions and validate that a user can execute given operation.
func (ActionApprovals) Clone ¶
func (m ActionApprovals) Clone() ActionApprovals
func (*ActionApprovals) Descriptor ¶
func (*ActionApprovals) Descriptor() ([]byte, []int)
func (*ActionApprovals) GetApprovals ¶
func (m *ActionApprovals) GetApprovals() []Approval
func (*ActionApprovals) Marshal ¶
func (m *ActionApprovals) Marshal() (dAtA []byte, err error)
func (*ActionApprovals) ProtoMessage ¶
func (*ActionApprovals) ProtoMessage()
func (*ActionApprovals) Reset ¶
func (m *ActionApprovals) Reset()
func (*ActionApprovals) Size ¶
func (m *ActionApprovals) Size() (n int)
func (*ActionApprovals) String ¶
func (m *ActionApprovals) String() string
func (*ActionApprovals) Unmarshal ¶
func (m *ActionApprovals) Unmarshal(dAtA []byte) error
func (*ActionApprovals) XXX_DiscardUnknown ¶ added in v0.12.0
func (m *ActionApprovals) XXX_DiscardUnknown()
func (*ActionApprovals) XXX_Marshal ¶ added in v0.12.0
func (m *ActionApprovals) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*ActionApprovals) XXX_Merge ¶ added in v0.12.0
func (m *ActionApprovals) XXX_Merge(src proto.Message)
func (*ActionApprovals) XXX_Size ¶ added in v0.12.0
func (m *ActionApprovals) XXX_Size() int
func (*ActionApprovals) XXX_Unmarshal ¶ added in v0.12.0
func (m *ActionApprovals) XXX_Unmarshal(b []byte) error
type AddApprovalMsg ¶
type AddApprovalMsg struct { Metadata *weave.Metadata `protobuf:"bytes,1,opt,name=metadata,proto3" json:"metadata,omitempty"` ID []byte `protobuf:"bytes,2,opt,name=id,proto3" json:"id,omitempty"` Address github_com_iov_one_weave.Address `protobuf:"bytes,3,opt,name=address,proto3,casttype=github.com/iov-one/weave.Address" json:"address,omitempty"` Action Action `protobuf:"bytes,4,opt,name=action,proto3,customtype=Action" json:"action"` Options ApprovalOptions `protobuf:"bytes,5,opt,name=options,proto3" json:"options"` T string `protobuf:"bytes,6,opt,name=t,proto3" json:"t,omitempty"` }
func (*AddApprovalMsg) Descriptor ¶
func (*AddApprovalMsg) Descriptor() ([]byte, []int)
func (*AddApprovalMsg) GetAddress ¶
func (m *AddApprovalMsg) GetAddress() github_com_iov_one_weave.Address
func (*AddApprovalMsg) GetID ¶ added in v0.10.0
func (m *AddApprovalMsg) GetID() []byte
func (*AddApprovalMsg) GetMetadata ¶ added in v0.15.0
func (m *AddApprovalMsg) GetMetadata() *weave.Metadata
func (*AddApprovalMsg) GetOptions ¶
func (m *AddApprovalMsg) GetOptions() ApprovalOptions
func (*AddApprovalMsg) GetT ¶
func (m *AddApprovalMsg) GetT() string
func (*AddApprovalMsg) Marshal ¶
func (m *AddApprovalMsg) Marshal() (dAtA []byte, err error)
func (*AddApprovalMsg) Path ¶
func (*AddApprovalMsg) Path() string
func (*AddApprovalMsg) ProtoMessage ¶
func (*AddApprovalMsg) ProtoMessage()
func (*AddApprovalMsg) Reset ¶
func (m *AddApprovalMsg) Reset()
func (*AddApprovalMsg) Size ¶
func (m *AddApprovalMsg) Size() (n int)
func (*AddApprovalMsg) String ¶
func (m *AddApprovalMsg) String() string
func (*AddApprovalMsg) Unmarshal ¶
func (m *AddApprovalMsg) Unmarshal(dAtA []byte) error
func (AddApprovalMsg) Validate ¶
func (m AddApprovalMsg) Validate() error
func (*AddApprovalMsg) XXX_DiscardUnknown ¶ added in v0.12.0
func (m *AddApprovalMsg) XXX_DiscardUnknown()
func (*AddApprovalMsg) XXX_Marshal ¶ added in v0.12.0
func (m *AddApprovalMsg) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*AddApprovalMsg) XXX_Merge ¶ added in v0.12.0
func (m *AddApprovalMsg) XXX_Merge(src proto.Message)
func (*AddApprovalMsg) XXX_Size ¶ added in v0.12.0
func (m *AddApprovalMsg) XXX_Size() int
func (*AddApprovalMsg) XXX_Unmarshal ¶ added in v0.12.0
func (m *AddApprovalMsg) XXX_Unmarshal(b []byte) error
type Approval ¶
type Approval struct { Address []byte `protobuf:"bytes,1,opt,name=address,proto3" json:"address,omitempty"` Options ApprovalOptions `protobuf:"bytes,2,opt,name=options,proto3" json:"options"` }
func (*Approval) Descriptor ¶
func (*Approval) GetAddress ¶
func (*Approval) GetOptions ¶
func (m *Approval) GetOptions() ApprovalOptions
func (*Approval) ProtoMessage ¶
func (*Approval) ProtoMessage()
func (*Approval) XXX_DiscardUnknown ¶ added in v0.12.0
func (m *Approval) XXX_DiscardUnknown()
func (*Approval) XXX_Marshal ¶ added in v0.12.0
func (*Approval) XXX_Unmarshal ¶ added in v0.12.0
type ApprovalMeta ¶
type ApprovalMeta []Approval
func (ApprovalMeta) Clone ¶
func (m ApprovalMeta) Clone() ApprovalMeta
func (ApprovalMeta) Validate ¶
func (m ApprovalMeta) Validate() error
type ApprovalMsg ¶
type ApprovalMsg interface { GetT() string Identified }
type ApprovalOps ¶
type ApprovalOps struct {
// contains filtered or unexported fields
}
func NewApprovalOps ¶
func NewApprovalOps(owner weave.Address, approvals *[]ActionApprovals) *ApprovalOps
TODO: Sort errors and their codes TODO: Figure out what we need to do with counts for the next iteration
func (*ApprovalOps) Grant ¶
func (o *ApprovalOps) Grant(action Action, to weave.Address, op ApprovalOptions, blockHeight int64, actionMaps ...map[Action]int32) error
TODO: Figure out whether we need wildcard approvals, might be wise to add an ApprovalOptions flag
func (*ApprovalOps) List ¶
func (o *ApprovalOps) List() Approvals
type ApprovalOptions ¶
type ApprovalOptions struct { // Until block height is used to mark blochain height until which an // approval is valid. This can be used to define an approval expiration. UntilBlockHeight int64 `protobuf:"varint,1,opt,name=until_block_height,json=untilBlockHeight,proto3" json:"until_block_height,omitempty"` // Count is defining how many times an approval can be used. Each approval // test decrese the counter. Once the counter reaches value 0, an approval // is considered expired and can no longer be used. // Use -1 to bypass count expiration. Count int64 `protobuf:"varint,2,opt,name=count,proto3" json:"count,omitempty"` // Immutable is a flag that prevents an option to be modified. Once // created, cannot be altered. For example, counter state cannot be // changed. Immutable bool `protobuf:"varint,3,opt,name=immutable,proto3" json:"immutable,omitempty"` }
func (*ApprovalOptions) Descriptor ¶
func (*ApprovalOptions) Descriptor() ([]byte, []int)
func (ApprovalOptions) Equals ¶
func (a ApprovalOptions) Equals(o ApprovalOptions) bool
func (ApprovalOptions) EqualsAfterUse ¶ added in v0.9.1
func (a ApprovalOptions) EqualsAfterUse(used ApprovalOptions) bool
func (*ApprovalOptions) GetCount ¶
func (m *ApprovalOptions) GetCount() int64
func (*ApprovalOptions) GetImmutable ¶
func (m *ApprovalOptions) GetImmutable() bool
func (*ApprovalOptions) GetUntilBlockHeight ¶
func (m *ApprovalOptions) GetUntilBlockHeight() int64
func (*ApprovalOptions) Marshal ¶
func (m *ApprovalOptions) Marshal() (dAtA []byte, err error)
func (*ApprovalOptions) ProtoMessage ¶
func (*ApprovalOptions) ProtoMessage()
func (*ApprovalOptions) Reset ¶
func (m *ApprovalOptions) Reset()
func (*ApprovalOptions) Size ¶
func (m *ApprovalOptions) Size() (n int)
func (*ApprovalOptions) String ¶
func (m *ApprovalOptions) String() string
func (*ApprovalOptions) Unmarshal ¶
func (m *ApprovalOptions) Unmarshal(dAtA []byte) error
func (ApprovalOptions) Validate ¶
func (a ApprovalOptions) Validate() error
func (*ApprovalOptions) XXX_DiscardUnknown ¶ added in v0.12.0
func (m *ApprovalOptions) XXX_DiscardUnknown()
func (*ApprovalOptions) XXX_Marshal ¶ added in v0.12.0
func (m *ApprovalOptions) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*ApprovalOptions) XXX_Merge ¶ added in v0.12.0
func (m *ApprovalOptions) XXX_Merge(src proto.Message)
func (*ApprovalOptions) XXX_Size ¶ added in v0.12.0
func (m *ApprovalOptions) XXX_Size() int
func (*ApprovalOptions) XXX_Unmarshal ¶ added in v0.12.0
func (m *ApprovalOptions) XXX_Unmarshal(b []byte) error
type Approvals ¶
type Approvals map[Action]ApprovalMeta
func (Approvals) AsPersistable ¶
func (m Approvals) AsPersistable() []ActionApprovals
func (Approvals) FilterExpired ¶
func (Approvals) MetaByAction ¶
func (m Approvals) MetaByAction(action Action) ApprovalMeta
type BaseNFT ¶
type BaseNFT interface { Owned //GetId() []byte Approvals() *ApprovalOps //Set new approvals SetApprovals(Approvals) }
type NonFungibleToken ¶
type NonFungibleToken struct { Metadata *weave.Metadata `protobuf:"bytes,1,opt,name=metadata,proto3" json:"metadata,omitempty"` // ID is the address of this token. ID []byte `protobuf:"bytes,2,opt,name=id,proto3" json:"id,omitempty"` // Owner is the address of the token owner. Owner github_com_iov_one_weave.Address `protobuf:"bytes,3,opt,name=owner,proto3,casttype=github.com/iov-one/weave.Address" json:"owner,omitempty"` // Action approvals is a list of permissions. In order for operation to // succeed, all action approvals validation must pass. ActionApprovals []ActionApprovals `protobuf:"bytes,4,rep,name=action_approvals,json=actionApprovals,proto3" json:"action_approvals"` }
NonFungibleToken is a message that must be incuded by any concrete NFT implementation. Usually it is the first attirbute called `base`.
func NewNonFungibleToken ¶
func NewNonFungibleToken(key []byte, owner weave.Address, approvals []ActionApprovals) *NonFungibleToken
func (*NonFungibleToken) Approvals ¶
func (m *NonFungibleToken) Approvals() *ApprovalOps
func (*NonFungibleToken) Clone ¶
func (m *NonFungibleToken) Clone() *NonFungibleToken
func (*NonFungibleToken) Copy ¶
func (m *NonFungibleToken) Copy() orm.CloneableData
func (*NonFungibleToken) Descriptor ¶
func (*NonFungibleToken) Descriptor() ([]byte, []int)
func (*NonFungibleToken) GetActionApprovals ¶
func (m *NonFungibleToken) GetActionApprovals() []ActionApprovals
func (*NonFungibleToken) GetID ¶ added in v0.10.0
func (m *NonFungibleToken) GetID() []byte
func (*NonFungibleToken) GetMetadata ¶ added in v0.15.0
func (m *NonFungibleToken) GetMetadata() *weave.Metadata
func (*NonFungibleToken) GetOwner ¶
func (m *NonFungibleToken) GetOwner() github_com_iov_one_weave.Address
func (*NonFungibleToken) HasApproval ¶
func (m *NonFungibleToken) HasApproval(actor weave.Address, action Action) bool
func (*NonFungibleToken) Marshal ¶
func (m *NonFungibleToken) Marshal() (dAtA []byte, err error)
func (*NonFungibleToken) OwnerAddress ¶
func (u *NonFungibleToken) OwnerAddress() weave.Address
func (*NonFungibleToken) ProtoMessage ¶
func (*NonFungibleToken) ProtoMessage()
func (*NonFungibleToken) Reset ¶
func (m *NonFungibleToken) Reset()
func (*NonFungibleToken) SetApprovals ¶ added in v0.9.1
func (m *NonFungibleToken) SetApprovals(a Approvals)
func (*NonFungibleToken) Size ¶
func (m *NonFungibleToken) Size() (n int)
func (*NonFungibleToken) String ¶
func (m *NonFungibleToken) String() string
func (*NonFungibleToken) Unmarshal ¶
func (m *NonFungibleToken) Unmarshal(dAtA []byte) error
func (*NonFungibleToken) Validate ¶
func (m *NonFungibleToken) Validate() error
func (*NonFungibleToken) XXX_DiscardUnknown ¶ added in v0.12.0
func (m *NonFungibleToken) XXX_DiscardUnknown()
func (*NonFungibleToken) XXX_Marshal ¶ added in v0.12.0
func (m *NonFungibleToken) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*NonFungibleToken) XXX_Merge ¶ added in v0.12.0
func (m *NonFungibleToken) XXX_Merge(src proto.Message)
func (*NonFungibleToken) XXX_Size ¶ added in v0.12.0
func (m *NonFungibleToken) XXX_Size() int
func (*NonFungibleToken) XXX_Unmarshal ¶ added in v0.12.0
func (m *NonFungibleToken) XXX_Unmarshal(b []byte) error
type RemoveApprovalMsg ¶
type RemoveApprovalMsg struct { Metadata *weave.Metadata `protobuf:"bytes,1,opt,name=metadata,proto3" json:"metadata,omitempty"` ID []byte `protobuf:"bytes,2,opt,name=id,proto3" json:"id,omitempty"` Address github_com_iov_one_weave.Address `protobuf:"bytes,3,opt,name=address,proto3,casttype=github.com/iov-one/weave.Address" json:"address,omitempty"` Action Action `protobuf:"bytes,4,opt,name=action,proto3,customtype=Action" json:"action"` T string `protobuf:"bytes,5,opt,name=t,proto3" json:"t,omitempty"` }
func (*RemoveApprovalMsg) Descriptor ¶
func (*RemoveApprovalMsg) Descriptor() ([]byte, []int)
func (*RemoveApprovalMsg) GetAddress ¶
func (m *RemoveApprovalMsg) GetAddress() github_com_iov_one_weave.Address
func (*RemoveApprovalMsg) GetID ¶ added in v0.10.0
func (m *RemoveApprovalMsg) GetID() []byte
func (*RemoveApprovalMsg) GetMetadata ¶ added in v0.15.0
func (m *RemoveApprovalMsg) GetMetadata() *weave.Metadata
func (*RemoveApprovalMsg) GetT ¶
func (m *RemoveApprovalMsg) GetT() string
func (*RemoveApprovalMsg) Marshal ¶
func (m *RemoveApprovalMsg) Marshal() (dAtA []byte, err error)
func (*RemoveApprovalMsg) MarshalTo ¶
func (m *RemoveApprovalMsg) MarshalTo(dAtA []byte) (int, error)
func (*RemoveApprovalMsg) Path ¶
func (*RemoveApprovalMsg) Path() string
func (*RemoveApprovalMsg) ProtoMessage ¶
func (*RemoveApprovalMsg) ProtoMessage()
func (*RemoveApprovalMsg) Reset ¶
func (m *RemoveApprovalMsg) Reset()
func (*RemoveApprovalMsg) Size ¶
func (m *RemoveApprovalMsg) Size() (n int)
func (*RemoveApprovalMsg) String ¶
func (m *RemoveApprovalMsg) String() string
func (*RemoveApprovalMsg) Unmarshal ¶
func (m *RemoveApprovalMsg) Unmarshal(dAtA []byte) error
func (RemoveApprovalMsg) Validate ¶
func (m RemoveApprovalMsg) Validate() error
func (*RemoveApprovalMsg) XXX_DiscardUnknown ¶ added in v0.12.0
func (m *RemoveApprovalMsg) XXX_DiscardUnknown()
func (*RemoveApprovalMsg) XXX_Marshal ¶ added in v0.12.0
func (m *RemoveApprovalMsg) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*RemoveApprovalMsg) XXX_Merge ¶ added in v0.12.0
func (m *RemoveApprovalMsg) XXX_Merge(src proto.Message)
func (*RemoveApprovalMsg) XXX_Size ¶ added in v0.12.0
func (m *RemoveApprovalMsg) XXX_Size() int
func (*RemoveApprovalMsg) XXX_Unmarshal ¶ added in v0.12.0
func (m *RemoveApprovalMsg) XXX_Unmarshal(b []byte) error