voucherv1

package
v0.0.0-...-dd98aab Latest Latest
Warning

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

Go to latest
Published: May 28, 2024 License: Apache-2.0 Imports: 21 Imported by: 0

Documentation

Overview

Code generated by protoc-gen-go-pulsar. DO NOT EDIT.

Code generated by protoc-gen-go-pulsar. DO NOT EDIT.

Code generated by protoc-gen-go-pulsar. DO NOT EDIT.

Code generated by protoc-gen-go-pulsar. DO NOT EDIT.

Code generated by protoc-gen-go-pulsar. DO NOT EDIT.

Index

Constants

View Source
const (
	Msg_Create_FullMethodName         = "/chora.voucher.v1.Msg/Create"
	Msg_Issue_FullMethodName          = "/chora.voucher.v1.Msg/Issue"
	Msg_UpdateIssuer_FullMethodName   = "/chora.voucher.v1.Msg/UpdateIssuer"
	Msg_UpdateMetadata_FullMethodName = "/chora.voucher.v1.Msg/UpdateMetadata"
)
View Source
const (
	Query_Voucher_FullMethodName           = "/chora.voucher.v1.Query/Voucher"
	Query_Vouchers_FullMethodName          = "/chora.voucher.v1.Query/Vouchers"
	Query_VouchersByIssuer_FullMethodName  = "/chora.voucher.v1.Query/VouchersByIssuer"
	Query_Balance_FullMethodName           = "/chora.voucher.v1.Query/Balance"
	Query_BalancesByAddress_FullMethodName = "/chora.voucher.v1.Query/BalancesByAddress"
	Query_BalancesByVoucher_FullMethodName = "/chora.voucher.v1.Query/BalancesByVoucher"
)

Variables

View Source
var File_chora_voucher_v1_doc_proto protoreflect.FileDescriptor
View Source
var File_chora_voucher_v1_events_proto protoreflect.FileDescriptor
View Source
var File_chora_voucher_v1_msg_proto protoreflect.FileDescriptor
View Source
var File_chora_voucher_v1_query_proto protoreflect.FileDescriptor
View Source
var File_chora_voucher_v1_state_proto protoreflect.FileDescriptor
View Source
var Msg_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "chora.voucher.v1.Msg",
	HandlerType: (*MsgServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "Create",
			Handler:    _Msg_Create_Handler,
		},
		{
			MethodName: "Issue",
			Handler:    _Msg_Issue_Handler,
		},
		{
			MethodName: "UpdateIssuer",
			Handler:    _Msg_UpdateIssuer_Handler,
		},
		{
			MethodName: "UpdateMetadata",
			Handler:    _Msg_UpdateMetadata_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "chora/voucher/v1/msg.proto",
}

Msg_ServiceDesc is the grpc.ServiceDesc for Msg service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)

View Source
var Query_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "chora.voucher.v1.Query",
	HandlerType: (*QueryServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "Voucher",
			Handler:    _Query_Voucher_Handler,
		},
		{
			MethodName: "Vouchers",
			Handler:    _Query_Vouchers_Handler,
		},
		{
			MethodName: "VouchersByIssuer",
			Handler:    _Query_VouchersByIssuer_Handler,
		},
		{
			MethodName: "Balance",
			Handler:    _Query_Balance_Handler,
		},
		{
			MethodName: "BalancesByAddress",
			Handler:    _Query_BalancesByAddress_Handler,
		},
		{
			MethodName: "BalancesByVoucher",
			Handler:    _Query_BalancesByVoucher_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "chora/voucher/v1/query.proto",
}

Query_ServiceDesc is the grpc.ServiceDesc for Query service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)

Functions

func RegisterMsgServer

func RegisterMsgServer(s grpc.ServiceRegistrar, srv MsgServer)

func RegisterQueryServer

func RegisterQueryServer(s grpc.ServiceRegistrar, srv QueryServer)

Types

type Balance

type Balance struct {

	// id is the unique identifier of the voucher.
	Id uint64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
	// address is the address of the voucher owner.
	Address []byte `protobuf:"bytes,2,opt,name=address,proto3" json:"address,omitempty"`
	// amount is the amount of vouchers the address owns.
	Amount string `protobuf:"bytes,3,opt,name=amount,proto3" json:"amount,omitempty"`
	// expiration is the expiration of the vouchers.
	Expiration *timestamppb.Timestamp `protobuf:"bytes,4,opt,name=expiration,proto3" json:"expiration,omitempty"`
	// contains filtered or unexported fields
}

Balance defines the table and properties of a voucher balance.

func (*Balance) Descriptor deprecated

func (*Balance) Descriptor() ([]byte, []int)

Deprecated: Use Balance.ProtoReflect.Descriptor instead.

func (*Balance) GetAddress

func (x *Balance) GetAddress() []byte

func (*Balance) GetAmount

func (x *Balance) GetAmount() string

func (*Balance) GetExpiration

func (x *Balance) GetExpiration() *timestamppb.Timestamp

func (*Balance) GetId

func (x *Balance) GetId() uint64

func (*Balance) ProtoMessage

func (*Balance) ProtoMessage()

func (*Balance) ProtoReflect

func (x *Balance) ProtoReflect() protoreflect.Message

func (*Balance) Reset

func (x *Balance) Reset()

func (*Balance) String

func (x *Balance) String() string

type BalanceAddressIndexKey

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

func (BalanceAddressIndexKey) WithAddress

func (this BalanceAddressIndexKey) WithAddress(address []byte) BalanceAddressIndexKey

type BalanceExpirationIndexKey

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

func (BalanceExpirationIndexKey) WithExpiration

type BalanceIdAddressExpirationIndexKey

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

func (BalanceIdAddressExpirationIndexKey) WithId

func (BalanceIdAddressExpirationIndexKey) WithIdAddress

func (BalanceIdAddressExpirationIndexKey) WithIdAddressExpiration

func (this BalanceIdAddressExpirationIndexKey) WithIdAddressExpiration(id uint64, address []byte, expiration *timestamppb.Timestamp) BalanceIdAddressExpirationIndexKey

type BalanceIndexKey

type BalanceIndexKey interface {
	// contains filtered or unexported methods
}

type BalanceIterator

type BalanceIterator struct {
	ormtable.Iterator
}

func (BalanceIterator) Value

func (i BalanceIterator) Value() (*Balance, error)

type BalancePrimaryKey

type BalancePrimaryKey = BalanceIdAddressExpirationIndexKey

primary key starting index..

type BalanceTable

type BalanceTable interface {
	Insert(ctx context.Context, balance *Balance) error
	Update(ctx context.Context, balance *Balance) error
	Save(ctx context.Context, balance *Balance) error
	Delete(ctx context.Context, balance *Balance) error
	Has(ctx context.Context, id uint64, address []byte, expiration *timestamppb.Timestamp) (found bool, err error)
	// Get returns nil and an error which responds true to ormerrors.IsNotFound() if the record was not found.
	Get(ctx context.Context, id uint64, address []byte, expiration *timestamppb.Timestamp) (*Balance, error)
	List(ctx context.Context, prefixKey BalanceIndexKey, opts ...ormlist.Option) (BalanceIterator, error)
	ListRange(ctx context.Context, from, to BalanceIndexKey, opts ...ormlist.Option) (BalanceIterator, error)
	DeleteBy(ctx context.Context, prefixKey BalanceIndexKey) error
	DeleteRange(ctx context.Context, from, to BalanceIndexKey) error
	// contains filtered or unexported methods
}

func NewBalanceTable

func NewBalanceTable(db ormtable.Schema) (BalanceTable, error)

type EventCreate

type EventCreate struct {

	// id is the unique identifier of the voucher.
	Id uint64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
	// contains filtered or unexported fields
}

EventCreate is an event emitted when a voucher is created.

func (*EventCreate) Descriptor deprecated

func (*EventCreate) Descriptor() ([]byte, []int)

Deprecated: Use EventCreate.ProtoReflect.Descriptor instead.

func (*EventCreate) GetId

func (x *EventCreate) GetId() uint64

func (*EventCreate) ProtoMessage

func (*EventCreate) ProtoMessage()

func (*EventCreate) ProtoReflect

func (x *EventCreate) ProtoReflect() protoreflect.Message

func (*EventCreate) Reset

func (x *EventCreate) Reset()

func (*EventCreate) String

func (x *EventCreate) String() string

type EventIssue

type EventIssue struct {

	// id is the unique identifier of the voucher.
	Id uint64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
	// metadata is the metadata of the issuance.
	Metadata string `protobuf:"bytes,2,opt,name=metadata,proto3" json:"metadata,omitempty"`
	// contains filtered or unexported fields
}

EventIssue is an event emitted when vouchers are issued.

func (*EventIssue) Descriptor deprecated

func (*EventIssue) Descriptor() ([]byte, []int)

Deprecated: Use EventIssue.ProtoReflect.Descriptor instead.

func (*EventIssue) GetId

func (x *EventIssue) GetId() uint64

func (*EventIssue) GetMetadata

func (x *EventIssue) GetMetadata() string

func (*EventIssue) ProtoMessage

func (*EventIssue) ProtoMessage()

func (*EventIssue) ProtoReflect

func (x *EventIssue) ProtoReflect() protoreflect.Message

func (*EventIssue) Reset

func (x *EventIssue) Reset()

func (*EventIssue) String

func (x *EventIssue) String() string

type EventUpdateIssuer

type EventUpdateIssuer struct {

	// id is the unique identifier of the voucher.
	Id uint64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
	// contains filtered or unexported fields
}

EventUpdateIssuer is an event emitted when voucher issuer is updated.

func (*EventUpdateIssuer) Descriptor deprecated

func (*EventUpdateIssuer) Descriptor() ([]byte, []int)

Deprecated: Use EventUpdateIssuer.ProtoReflect.Descriptor instead.

func (*EventUpdateIssuer) GetId

func (x *EventUpdateIssuer) GetId() uint64

func (*EventUpdateIssuer) ProtoMessage

func (*EventUpdateIssuer) ProtoMessage()

func (*EventUpdateIssuer) ProtoReflect

func (x *EventUpdateIssuer) ProtoReflect() protoreflect.Message

func (*EventUpdateIssuer) Reset

func (x *EventUpdateIssuer) Reset()

func (*EventUpdateIssuer) String

func (x *EventUpdateIssuer) String() string

type EventUpdateMetadata

type EventUpdateMetadata struct {

	// id is the unique identifier of the voucher.
	Id uint64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
	// contains filtered or unexported fields
}

EventUpdateMetadata is an event emitted when voucher metadata is updated.

func (*EventUpdateMetadata) Descriptor deprecated

func (*EventUpdateMetadata) Descriptor() ([]byte, []int)

Deprecated: Use EventUpdateMetadata.ProtoReflect.Descriptor instead.

func (*EventUpdateMetadata) GetId

func (x *EventUpdateMetadata) GetId() uint64

func (*EventUpdateMetadata) ProtoMessage

func (*EventUpdateMetadata) ProtoMessage()

func (*EventUpdateMetadata) ProtoReflect

func (x *EventUpdateMetadata) ProtoReflect() protoreflect.Message

func (*EventUpdateMetadata) Reset

func (x *EventUpdateMetadata) Reset()

func (*EventUpdateMetadata) String

func (x *EventUpdateMetadata) String() string

type MsgClient

type MsgClient interface {
	// Create creates a voucher.
	Create(ctx context.Context, in *MsgCreate, opts ...grpc.CallOption) (*MsgCreateResponse, error)
	// Issue issues vouchers to a recipient.
	Issue(ctx context.Context, in *MsgIssue, opts ...grpc.CallOption) (*MsgIssueResponse, error)
	// UpdateIssuer updates the issuer of a voucher.
	UpdateIssuer(ctx context.Context, in *MsgUpdateIssuer, opts ...grpc.CallOption) (*MsgUpdateIssuerResponse, error)
	// UpdateMetadata updates the metadata of a voucher.
	UpdateMetadata(ctx context.Context, in *MsgUpdateMetadata, opts ...grpc.CallOption) (*MsgUpdateMetadataResponse, error)
}

MsgClient is the client API for Msg service.

For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.

func NewMsgClient

func NewMsgClient(cc grpc.ClientConnInterface) MsgClient

type MsgCreate

type MsgCreate struct {

	// issuer is the address of the voucher issuer.
	Issuer string `protobuf:"bytes,1,opt,name=issuer,proto3" json:"issuer,omitempty"`
	// metadata is the metadata of the voucher.
	Metadata string `protobuf:"bytes,2,opt,name=metadata,proto3" json:"metadata,omitempty"`
	// contains filtered or unexported fields
}

MsgCreate is the Msg/Create request type.

func (*MsgCreate) Descriptor deprecated

func (*MsgCreate) Descriptor() ([]byte, []int)

Deprecated: Use MsgCreate.ProtoReflect.Descriptor instead.

func (*MsgCreate) GetIssuer

func (x *MsgCreate) GetIssuer() string

func (*MsgCreate) GetMetadata

func (x *MsgCreate) GetMetadata() string

func (*MsgCreate) ProtoMessage

func (*MsgCreate) ProtoMessage()

func (*MsgCreate) ProtoReflect

func (x *MsgCreate) ProtoReflect() protoreflect.Message

func (*MsgCreate) Reset

func (x *MsgCreate) Reset()

func (*MsgCreate) String

func (x *MsgCreate) String() string

type MsgCreateResponse

type MsgCreateResponse struct {

	// id is the unique identifier of the voucher.
	Id uint64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
	// contains filtered or unexported fields
}

MsgCreateResponse is the Msg/Create response type.

func (*MsgCreateResponse) Descriptor deprecated

func (*MsgCreateResponse) Descriptor() ([]byte, []int)

Deprecated: Use MsgCreateResponse.ProtoReflect.Descriptor instead.

func (*MsgCreateResponse) GetId

func (x *MsgCreateResponse) GetId() uint64

func (*MsgCreateResponse) ProtoMessage

func (*MsgCreateResponse) ProtoMessage()

func (*MsgCreateResponse) ProtoReflect

func (x *MsgCreateResponse) ProtoReflect() protoreflect.Message

func (*MsgCreateResponse) Reset

func (x *MsgCreateResponse) Reset()

func (*MsgCreateResponse) String

func (x *MsgCreateResponse) String() string

type MsgIssue

type MsgIssue struct {

	// id is the unique identifier of the voucher.
	Id uint64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
	// issuer is the address of the voucher issuer.
	Issuer string `protobuf:"bytes,2,opt,name=issuer,proto3" json:"issuer,omitempty"`
	// recipient is the address of the recipient.
	Recipient string `protobuf:"bytes,3,opt,name=recipient,proto3" json:"recipient,omitempty"`
	// amount is the amount of vouchers to issue.
	Amount string `protobuf:"bytes,4,opt,name=amount,proto3" json:"amount,omitempty"`
	// expiration is the expiration of the vouchers.
	Expiration *timestamppb.Timestamp `protobuf:"bytes,5,opt,name=expiration,proto3" json:"expiration,omitempty"`
	// metadata is the metadata of the issuance.
	Metadata string `protobuf:"bytes,6,opt,name=metadata,proto3" json:"metadata,omitempty"`
	// contains filtered or unexported fields
}

MsgIssue is the Msg/Issue request type.

func (*MsgIssue) Descriptor deprecated

func (*MsgIssue) Descriptor() ([]byte, []int)

Deprecated: Use MsgIssue.ProtoReflect.Descriptor instead.

func (*MsgIssue) GetAmount

func (x *MsgIssue) GetAmount() string

func (*MsgIssue) GetExpiration

func (x *MsgIssue) GetExpiration() *timestamppb.Timestamp

func (*MsgIssue) GetId

func (x *MsgIssue) GetId() uint64

func (*MsgIssue) GetIssuer

func (x *MsgIssue) GetIssuer() string

func (*MsgIssue) GetMetadata

func (x *MsgIssue) GetMetadata() string

func (*MsgIssue) GetRecipient

func (x *MsgIssue) GetRecipient() string

func (*MsgIssue) ProtoMessage

func (*MsgIssue) ProtoMessage()

func (*MsgIssue) ProtoReflect

func (x *MsgIssue) ProtoReflect() protoreflect.Message

func (*MsgIssue) Reset

func (x *MsgIssue) Reset()

func (*MsgIssue) String

func (x *MsgIssue) String() string

type MsgIssueResponse

type MsgIssueResponse struct {

	// id is the unique identifier of the voucher.
	Id uint64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
	// contains filtered or unexported fields
}

MsgIssueResponse is the Msg/Issue response type.

func (*MsgIssueResponse) Descriptor deprecated

func (*MsgIssueResponse) Descriptor() ([]byte, []int)

Deprecated: Use MsgIssueResponse.ProtoReflect.Descriptor instead.

func (*MsgIssueResponse) GetId

func (x *MsgIssueResponse) GetId() uint64

func (*MsgIssueResponse) ProtoMessage

func (*MsgIssueResponse) ProtoMessage()

func (*MsgIssueResponse) ProtoReflect

func (x *MsgIssueResponse) ProtoReflect() protoreflect.Message

func (*MsgIssueResponse) Reset

func (x *MsgIssueResponse) Reset()

func (*MsgIssueResponse) String

func (x *MsgIssueResponse) String() string

type MsgServer

type MsgServer interface {
	// Create creates a voucher.
	Create(context.Context, *MsgCreate) (*MsgCreateResponse, error)
	// Issue issues vouchers to a recipient.
	Issue(context.Context, *MsgIssue) (*MsgIssueResponse, error)
	// UpdateIssuer updates the issuer of a voucher.
	UpdateIssuer(context.Context, *MsgUpdateIssuer) (*MsgUpdateIssuerResponse, error)
	// UpdateMetadata updates the metadata of a voucher.
	UpdateMetadata(context.Context, *MsgUpdateMetadata) (*MsgUpdateMetadataResponse, error)
	// contains filtered or unexported methods
}

MsgServer is the server API for Msg service. All implementations must embed UnimplementedMsgServer for forward compatibility

type MsgUpdateIssuer

type MsgUpdateIssuer struct {

	// id is the unique identifier of the voucher.
	Id uint64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
	// issuer is the address of the voucher issuer.
	Issuer string `protobuf:"bytes,2,opt,name=issuer,proto3" json:"issuer,omitempty"`
	// new_issuer is the address of the new issuer.
	NewIssuer string `protobuf:"bytes,3,opt,name=new_issuer,json=newIssuer,proto3" json:"new_issuer,omitempty"`
	// contains filtered or unexported fields
}

MsgUpdateIssuer is the Msg/UpdateIssuer request type.

func (*MsgUpdateIssuer) Descriptor deprecated

func (*MsgUpdateIssuer) Descriptor() ([]byte, []int)

Deprecated: Use MsgUpdateIssuer.ProtoReflect.Descriptor instead.

func (*MsgUpdateIssuer) GetId

func (x *MsgUpdateIssuer) GetId() uint64

func (*MsgUpdateIssuer) GetIssuer

func (x *MsgUpdateIssuer) GetIssuer() string

func (*MsgUpdateIssuer) GetNewIssuer

func (x *MsgUpdateIssuer) GetNewIssuer() string

func (*MsgUpdateIssuer) ProtoMessage

func (*MsgUpdateIssuer) ProtoMessage()

func (*MsgUpdateIssuer) ProtoReflect

func (x *MsgUpdateIssuer) ProtoReflect() protoreflect.Message

func (*MsgUpdateIssuer) Reset

func (x *MsgUpdateIssuer) Reset()

func (*MsgUpdateIssuer) String

func (x *MsgUpdateIssuer) String() string

type MsgUpdateIssuerResponse

type MsgUpdateIssuerResponse struct {

	// id is the unique identifier of the voucher.
	Id uint64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
	// contains filtered or unexported fields
}

MsgUpdateIssuerResponse is the Msg/UpdateIssuer response type.

func (*MsgUpdateIssuerResponse) Descriptor deprecated

func (*MsgUpdateIssuerResponse) Descriptor() ([]byte, []int)

Deprecated: Use MsgUpdateIssuerResponse.ProtoReflect.Descriptor instead.

func (*MsgUpdateIssuerResponse) GetId

func (x *MsgUpdateIssuerResponse) GetId() uint64

func (*MsgUpdateIssuerResponse) ProtoMessage

func (*MsgUpdateIssuerResponse) ProtoMessage()

func (*MsgUpdateIssuerResponse) ProtoReflect

func (x *MsgUpdateIssuerResponse) ProtoReflect() protoreflect.Message

func (*MsgUpdateIssuerResponse) Reset

func (x *MsgUpdateIssuerResponse) Reset()

func (*MsgUpdateIssuerResponse) String

func (x *MsgUpdateIssuerResponse) String() string

type MsgUpdateMetadata

type MsgUpdateMetadata struct {

	// id is the unique identifier of the voucher.
	Id uint64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
	// issuer is the address of the voucher issuer.
	Issuer string `protobuf:"bytes,2,opt,name=issuer,proto3" json:"issuer,omitempty"`
	// new_metadata is the new metadata of the voucher.
	NewMetadata string `protobuf:"bytes,3,opt,name=new_metadata,json=newMetadata,proto3" json:"new_metadata,omitempty"`
	// contains filtered or unexported fields
}

MsgUpdateMetadata is the Msg/UpdateMetadata request type.

func (*MsgUpdateMetadata) Descriptor deprecated

func (*MsgUpdateMetadata) Descriptor() ([]byte, []int)

Deprecated: Use MsgUpdateMetadata.ProtoReflect.Descriptor instead.

func (*MsgUpdateMetadata) GetId

func (x *MsgUpdateMetadata) GetId() uint64

func (*MsgUpdateMetadata) GetIssuer

func (x *MsgUpdateMetadata) GetIssuer() string

func (*MsgUpdateMetadata) GetNewMetadata

func (x *MsgUpdateMetadata) GetNewMetadata() string

func (*MsgUpdateMetadata) ProtoMessage

func (*MsgUpdateMetadata) ProtoMessage()

func (*MsgUpdateMetadata) ProtoReflect

func (x *MsgUpdateMetadata) ProtoReflect() protoreflect.Message

func (*MsgUpdateMetadata) Reset

func (x *MsgUpdateMetadata) Reset()

func (*MsgUpdateMetadata) String

func (x *MsgUpdateMetadata) String() string

type MsgUpdateMetadataResponse

type MsgUpdateMetadataResponse struct {

	// id is the unique identifier of the voucher.
	Id uint64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
	// contains filtered or unexported fields
}

MsgUpdateMetadataResponse is the Msg/UpdateMetadata response type.

func (*MsgUpdateMetadataResponse) Descriptor deprecated

func (*MsgUpdateMetadataResponse) Descriptor() ([]byte, []int)

Deprecated: Use MsgUpdateMetadataResponse.ProtoReflect.Descriptor instead.

func (*MsgUpdateMetadataResponse) GetId

func (x *MsgUpdateMetadataResponse) GetId() uint64

func (*MsgUpdateMetadataResponse) ProtoMessage

func (*MsgUpdateMetadataResponse) ProtoMessage()

func (*MsgUpdateMetadataResponse) ProtoReflect

func (*MsgUpdateMetadataResponse) Reset

func (x *MsgUpdateMetadataResponse) Reset()

func (*MsgUpdateMetadataResponse) String

func (x *MsgUpdateMetadataResponse) String() string

type QueryBalanceRequest

type QueryBalanceRequest struct {

	// id is the unique identifier of the voucher.
	Id uint64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
	// address is the address of the voucher owner.
	Address string `protobuf:"bytes,2,opt,name=address,proto3" json:"address,omitempty"`
	// contains filtered or unexported fields
}

QueryBalanceRequest is the Query/Balance request type.

func (*QueryBalanceRequest) Descriptor deprecated

func (*QueryBalanceRequest) Descriptor() ([]byte, []int)

Deprecated: Use QueryBalanceRequest.ProtoReflect.Descriptor instead.

func (*QueryBalanceRequest) GetAddress

func (x *QueryBalanceRequest) GetAddress() string

func (*QueryBalanceRequest) GetId

func (x *QueryBalanceRequest) GetId() uint64

func (*QueryBalanceRequest) ProtoMessage

func (*QueryBalanceRequest) ProtoMessage()

func (*QueryBalanceRequest) ProtoReflect

func (x *QueryBalanceRequest) ProtoReflect() protoreflect.Message

func (*QueryBalanceRequest) Reset

func (x *QueryBalanceRequest) Reset()

func (*QueryBalanceRequest) String

func (x *QueryBalanceRequest) String() string

type QueryBalanceResponse

type QueryBalanceResponse struct {

	// id is the unique identifier of the voucher.
	Id uint64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
	// address is the address of the voucher owner.
	Address string `protobuf:"bytes,2,opt,name=address,proto3" json:"address,omitempty"`
	// total_amount is the total amount the address owns.
	TotalAmount string `protobuf:"bytes,3,opt,name=total_amount,json=totalAmount,proto3" json:"total_amount,omitempty"`
	// amounts is the list of amounts with expiration.
	Amounts []*QueryBalanceResponse_Amount `protobuf:"bytes,4,rep,name=amounts,proto3" json:"amounts,omitempty"`
	// contains filtered or unexported fields
}

QueryBalanceResponse is the Query/Balance response type.

func (*QueryBalanceResponse) Descriptor deprecated

func (*QueryBalanceResponse) Descriptor() ([]byte, []int)

Deprecated: Use QueryBalanceResponse.ProtoReflect.Descriptor instead.

func (*QueryBalanceResponse) GetAddress

func (x *QueryBalanceResponse) GetAddress() string

func (*QueryBalanceResponse) GetAmounts

func (*QueryBalanceResponse) GetId

func (x *QueryBalanceResponse) GetId() uint64

func (*QueryBalanceResponse) GetTotalAmount

func (x *QueryBalanceResponse) GetTotalAmount() string

func (*QueryBalanceResponse) ProtoMessage

func (*QueryBalanceResponse) ProtoMessage()

func (*QueryBalanceResponse) ProtoReflect

func (x *QueryBalanceResponse) ProtoReflect() protoreflect.Message

func (*QueryBalanceResponse) Reset

func (x *QueryBalanceResponse) Reset()

func (*QueryBalanceResponse) String

func (x *QueryBalanceResponse) String() string

type QueryBalanceResponse_Amount

type QueryBalanceResponse_Amount struct {

	// amount is the amount of vouchers.
	Amount string `protobuf:"bytes,1,opt,name=amount,proto3" json:"amount,omitempty"`
	// expiration is the expiration of the voucher.
	Expiration *timestamppb.Timestamp `protobuf:"bytes,2,opt,name=expiration,proto3" json:"expiration,omitempty"`
	// contains filtered or unexported fields
}

Amount is the amount with expiration.

func (*QueryBalanceResponse_Amount) Descriptor deprecated

func (*QueryBalanceResponse_Amount) Descriptor() ([]byte, []int)

Deprecated: Use QueryBalanceResponse_Amount.ProtoReflect.Descriptor instead.

func (*QueryBalanceResponse_Amount) GetAmount

func (x *QueryBalanceResponse_Amount) GetAmount() string

func (*QueryBalanceResponse_Amount) GetExpiration

func (*QueryBalanceResponse_Amount) ProtoMessage

func (*QueryBalanceResponse_Amount) ProtoMessage()

func (*QueryBalanceResponse_Amount) ProtoReflect

func (*QueryBalanceResponse_Amount) Reset

func (x *QueryBalanceResponse_Amount) Reset()

func (*QueryBalanceResponse_Amount) String

func (x *QueryBalanceResponse_Amount) String() string

type QueryBalancesByAddressRequest

type QueryBalancesByAddressRequest struct {

	// address is the address of the voucher owner.
	Address string `protobuf:"bytes,1,opt,name=address,proto3" json:"address,omitempty"`
	// pagination is the optional pagination of the request.
	Pagination *v1beta1.PageRequest `protobuf:"bytes,2,opt,name=pagination,proto3" json:"pagination,omitempty"`
	// contains filtered or unexported fields
}

QueryBalancesByAddressRequest is the Query/BalancesByAddress request type.

func (*QueryBalancesByAddressRequest) Descriptor deprecated

func (*QueryBalancesByAddressRequest) Descriptor() ([]byte, []int)

Deprecated: Use QueryBalancesByAddressRequest.ProtoReflect.Descriptor instead.

func (*QueryBalancesByAddressRequest) GetAddress

func (x *QueryBalancesByAddressRequest) GetAddress() string

func (*QueryBalancesByAddressRequest) GetPagination

func (*QueryBalancesByAddressRequest) ProtoMessage

func (*QueryBalancesByAddressRequest) ProtoMessage()

func (*QueryBalancesByAddressRequest) ProtoReflect

func (*QueryBalancesByAddressRequest) Reset

func (x *QueryBalancesByAddressRequest) Reset()

func (*QueryBalancesByAddressRequest) String

type QueryBalancesByAddressResponse

type QueryBalancesByAddressResponse struct {

	// address is the address of the voucher owner.
	Address string `protobuf:"bytes,1,opt,name=address,proto3" json:"address,omitempty"`
	// total_amounts is the list of total amounts.
	TotalAmounts []*QueryBalancesByAddressResponse_TotalAmount `protobuf:"bytes,2,rep,name=total_amounts,json=totalAmounts,proto3" json:"total_amounts,omitempty"`
	// pagination is the pagination of the response.
	Pagination *v1beta1.PageResponse `protobuf:"bytes,3,opt,name=pagination,proto3" json:"pagination,omitempty"`
	// contains filtered or unexported fields
}

QueryBalancesByAddressResponse is the Query/BalancesByAddress response type.

func (*QueryBalancesByAddressResponse) Descriptor deprecated

func (*QueryBalancesByAddressResponse) Descriptor() ([]byte, []int)

Deprecated: Use QueryBalancesByAddressResponse.ProtoReflect.Descriptor instead.

func (*QueryBalancesByAddressResponse) GetAddress

func (x *QueryBalancesByAddressResponse) GetAddress() string

func (*QueryBalancesByAddressResponse) GetPagination

func (*QueryBalancesByAddressResponse) GetTotalAmounts

func (*QueryBalancesByAddressResponse) ProtoMessage

func (*QueryBalancesByAddressResponse) ProtoMessage()

func (*QueryBalancesByAddressResponse) ProtoReflect

func (*QueryBalancesByAddressResponse) Reset

func (x *QueryBalancesByAddressResponse) Reset()

func (*QueryBalancesByAddressResponse) String

type QueryBalancesByAddressResponse_TotalAmount

type QueryBalancesByAddressResponse_TotalAmount struct {

	// id is the unique identifier of the voucher.
	Id uint64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
	// total_amount is the total amount the address owns.
	TotalAmount string `protobuf:"bytes,2,opt,name=total_amount,json=totalAmount,proto3" json:"total_amount,omitempty"`
	// contains filtered or unexported fields
}

TotalAmount is the total amount.

func (*QueryBalancesByAddressResponse_TotalAmount) Descriptor deprecated

Deprecated: Use QueryBalancesByAddressResponse_TotalAmount.ProtoReflect.Descriptor instead.

func (*QueryBalancesByAddressResponse_TotalAmount) GetId

func (*QueryBalancesByAddressResponse_TotalAmount) GetTotalAmount

func (*QueryBalancesByAddressResponse_TotalAmount) ProtoMessage

func (*QueryBalancesByAddressResponse_TotalAmount) ProtoReflect

func (*QueryBalancesByAddressResponse_TotalAmount) Reset

func (*QueryBalancesByAddressResponse_TotalAmount) String

type QueryBalancesByVoucherRequest

type QueryBalancesByVoucherRequest struct {

	// id is the unique identifier of the voucher.
	Id uint64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
	// pagination is the optional pagination of the request.
	Pagination *v1beta1.PageRequest `protobuf:"bytes,2,opt,name=pagination,proto3" json:"pagination,omitempty"`
	// contains filtered or unexported fields
}

QueryBalancesByVoucherRequest is the Query/BalancesByVoucher request type.

func (*QueryBalancesByVoucherRequest) Descriptor deprecated

func (*QueryBalancesByVoucherRequest) Descriptor() ([]byte, []int)

Deprecated: Use QueryBalancesByVoucherRequest.ProtoReflect.Descriptor instead.

func (*QueryBalancesByVoucherRequest) GetId

func (*QueryBalancesByVoucherRequest) GetPagination

func (*QueryBalancesByVoucherRequest) ProtoMessage

func (*QueryBalancesByVoucherRequest) ProtoMessage()

func (*QueryBalancesByVoucherRequest) ProtoReflect

func (*QueryBalancesByVoucherRequest) Reset

func (x *QueryBalancesByVoucherRequest) Reset()

func (*QueryBalancesByVoucherRequest) String

type QueryBalancesByVoucherResponse

type QueryBalancesByVoucherResponse struct {

	// id is the unique identifier of the voucher.
	Id uint64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
	// total_amounts is the list of total amounts.
	TotalAmounts []*QueryBalancesByVoucherResponse_TotalAmount `protobuf:"bytes,2,rep,name=total_amounts,json=totalAmounts,proto3" json:"total_amounts,omitempty"`
	// pagination is the pagination of the response.
	Pagination *v1beta1.PageResponse `protobuf:"bytes,3,opt,name=pagination,proto3" json:"pagination,omitempty"`
	// contains filtered or unexported fields
}

QueryBalancesByVoucherResponse is the Query/BalancesByVoucher response type.

func (*QueryBalancesByVoucherResponse) Descriptor deprecated

func (*QueryBalancesByVoucherResponse) Descriptor() ([]byte, []int)

Deprecated: Use QueryBalancesByVoucherResponse.ProtoReflect.Descriptor instead.

func (*QueryBalancesByVoucherResponse) GetId

func (*QueryBalancesByVoucherResponse) GetPagination

func (*QueryBalancesByVoucherResponse) GetTotalAmounts

func (*QueryBalancesByVoucherResponse) ProtoMessage

func (*QueryBalancesByVoucherResponse) ProtoMessage()

func (*QueryBalancesByVoucherResponse) ProtoReflect

func (*QueryBalancesByVoucherResponse) Reset

func (x *QueryBalancesByVoucherResponse) Reset()

func (*QueryBalancesByVoucherResponse) String

type QueryBalancesByVoucherResponse_TotalAmount

type QueryBalancesByVoucherResponse_TotalAmount struct {

	// address is the address of the voucher owner.
	Address string `protobuf:"bytes,1,opt,name=address,proto3" json:"address,omitempty"`
	// total_amount is the total amount the address owns.
	TotalAmount string `protobuf:"bytes,2,opt,name=total_amount,json=totalAmount,proto3" json:"total_amount,omitempty"`
	// contains filtered or unexported fields
}

TotalAmount is the total amount.

func (*QueryBalancesByVoucherResponse_TotalAmount) Descriptor deprecated

Deprecated: Use QueryBalancesByVoucherResponse_TotalAmount.ProtoReflect.Descriptor instead.

func (*QueryBalancesByVoucherResponse_TotalAmount) GetAddress

func (*QueryBalancesByVoucherResponse_TotalAmount) GetTotalAmount

func (*QueryBalancesByVoucherResponse_TotalAmount) ProtoMessage

func (*QueryBalancesByVoucherResponse_TotalAmount) ProtoReflect

func (*QueryBalancesByVoucherResponse_TotalAmount) Reset

func (*QueryBalancesByVoucherResponse_TotalAmount) String

type QueryClient

type QueryClient interface {
	// Voucher queries a voucher by id.
	Voucher(ctx context.Context, in *QueryVoucherRequest, opts ...grpc.CallOption) (*QueryVoucherResponse, error)
	// Vouchers queries all vouchers.
	Vouchers(ctx context.Context, in *QueryVouchersRequest, opts ...grpc.CallOption) (*QueryVouchersResponse, error)
	// VouchersByIssuer queries vouchers by issuer.
	VouchersByIssuer(ctx context.Context, in *QueryVouchersByIssuerRequest, opts ...grpc.CallOption) (*QueryVouchersByIssuerResponse, error)
	// Balance queries the balance of a voucher and address.
	Balance(ctx context.Context, in *QueryBalanceRequest, opts ...grpc.CallOption) (*QueryBalanceResponse, error)
	// BalancesByAddress queries all balances of an address.
	BalancesByAddress(ctx context.Context, in *QueryBalancesByAddressRequest, opts ...grpc.CallOption) (*QueryBalancesByAddressResponse, error)
	// BalancesByVoucher queries all balances of a voucher.
	BalancesByVoucher(ctx context.Context, in *QueryBalancesByVoucherRequest, opts ...grpc.CallOption) (*QueryBalancesByVoucherResponse, error)
}

QueryClient is the client API for Query service.

For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.

func NewQueryClient

func NewQueryClient(cc grpc.ClientConnInterface) QueryClient

type QueryServer

type QueryServer interface {
	// Voucher queries a voucher by id.
	Voucher(context.Context, *QueryVoucherRequest) (*QueryVoucherResponse, error)
	// Vouchers queries all vouchers.
	Vouchers(context.Context, *QueryVouchersRequest) (*QueryVouchersResponse, error)
	// VouchersByIssuer queries vouchers by issuer.
	VouchersByIssuer(context.Context, *QueryVouchersByIssuerRequest) (*QueryVouchersByIssuerResponse, error)
	// Balance queries the balance of a voucher and address.
	Balance(context.Context, *QueryBalanceRequest) (*QueryBalanceResponse, error)
	// BalancesByAddress queries all balances of an address.
	BalancesByAddress(context.Context, *QueryBalancesByAddressRequest) (*QueryBalancesByAddressResponse, error)
	// BalancesByVoucher queries all balances of a voucher.
	BalancesByVoucher(context.Context, *QueryBalancesByVoucherRequest) (*QueryBalancesByVoucherResponse, error)
	// contains filtered or unexported methods
}

QueryServer is the server API for Query service. All implementations must embed UnimplementedQueryServer for forward compatibility

type QueryVoucherRequest

type QueryVoucherRequest struct {

	// id is the unique identifier of the voucher.
	Id uint64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
	// contains filtered or unexported fields
}

QueryVoucherRequest is the Query/Voucher request type.

func (*QueryVoucherRequest) Descriptor deprecated

func (*QueryVoucherRequest) Descriptor() ([]byte, []int)

Deprecated: Use QueryVoucherRequest.ProtoReflect.Descriptor instead.

func (*QueryVoucherRequest) GetId

func (x *QueryVoucherRequest) GetId() uint64

func (*QueryVoucherRequest) ProtoMessage

func (*QueryVoucherRequest) ProtoMessage()

func (*QueryVoucherRequest) ProtoReflect

func (x *QueryVoucherRequest) ProtoReflect() protoreflect.Message

func (*QueryVoucherRequest) Reset

func (x *QueryVoucherRequest) Reset()

func (*QueryVoucherRequest) String

func (x *QueryVoucherRequest) String() string

type QueryVoucherResponse

type QueryVoucherResponse struct {

	// id is the unique identifier of the voucher.
	Id uint64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
	// issuer is the address of the voucher issuer.
	Issuer string `protobuf:"bytes,2,opt,name=issuer,proto3" json:"issuer,omitempty"`
	// metadata is the metadata of the voucher.
	Metadata string `protobuf:"bytes,3,opt,name=metadata,proto3" json:"metadata,omitempty"`
	// contains filtered or unexported fields
}

QueryVoucherResponse is the Query/Voucher response type.

func (*QueryVoucherResponse) Descriptor deprecated

func (*QueryVoucherResponse) Descriptor() ([]byte, []int)

Deprecated: Use QueryVoucherResponse.ProtoReflect.Descriptor instead.

func (*QueryVoucherResponse) GetId

func (x *QueryVoucherResponse) GetId() uint64

func (*QueryVoucherResponse) GetIssuer

func (x *QueryVoucherResponse) GetIssuer() string

func (*QueryVoucherResponse) GetMetadata

func (x *QueryVoucherResponse) GetMetadata() string

func (*QueryVoucherResponse) ProtoMessage

func (*QueryVoucherResponse) ProtoMessage()

func (*QueryVoucherResponse) ProtoReflect

func (x *QueryVoucherResponse) ProtoReflect() protoreflect.Message

func (*QueryVoucherResponse) Reset

func (x *QueryVoucherResponse) Reset()

func (*QueryVoucherResponse) String

func (x *QueryVoucherResponse) String() string

type QueryVouchersByIssuerRequest

type QueryVouchersByIssuerRequest struct {

	// issuer is the address of the voucher issuer.
	Issuer string `protobuf:"bytes,1,opt,name=issuer,proto3" json:"issuer,omitempty"`
	// pagination is the optional pagination of the request.
	Pagination *v1beta1.PageRequest `protobuf:"bytes,2,opt,name=pagination,proto3" json:"pagination,omitempty"`
	// contains filtered or unexported fields
}

QueryVouchersByIssuerRequest is the Query/VouchersByIssuer request type.

func (*QueryVouchersByIssuerRequest) Descriptor deprecated

func (*QueryVouchersByIssuerRequest) Descriptor() ([]byte, []int)

Deprecated: Use QueryVouchersByIssuerRequest.ProtoReflect.Descriptor instead.

func (*QueryVouchersByIssuerRequest) GetIssuer

func (x *QueryVouchersByIssuerRequest) GetIssuer() string

func (*QueryVouchersByIssuerRequest) GetPagination

func (x *QueryVouchersByIssuerRequest) GetPagination() *v1beta1.PageRequest

func (*QueryVouchersByIssuerRequest) ProtoMessage

func (*QueryVouchersByIssuerRequest) ProtoMessage()

func (*QueryVouchersByIssuerRequest) ProtoReflect

func (*QueryVouchersByIssuerRequest) Reset

func (x *QueryVouchersByIssuerRequest) Reset()

func (*QueryVouchersByIssuerRequest) String

type QueryVouchersByIssuerResponse

type QueryVouchersByIssuerResponse struct {

	// issuer is the address of the voucher issuer.
	Issuer string `protobuf:"bytes,1,opt,name=issuer,proto3" json:"issuer,omitempty"`
	// vouchers is the list of vouchers managed by the issuer.
	Vouchers []*QueryVouchersByIssuerResponse_Voucher `protobuf:"bytes,2,rep,name=vouchers,proto3" json:"vouchers,omitempty"`
	// pagination is the pagination of the response.
	Pagination *v1beta1.PageResponse `protobuf:"bytes,3,opt,name=pagination,proto3" json:"pagination,omitempty"`
	// contains filtered or unexported fields
}

QueryVouchersByIssuerResponse is the Query/VouchersByIssuer response type.

func (*QueryVouchersByIssuerResponse) Descriptor deprecated

func (*QueryVouchersByIssuerResponse) Descriptor() ([]byte, []int)

Deprecated: Use QueryVouchersByIssuerResponse.ProtoReflect.Descriptor instead.

func (*QueryVouchersByIssuerResponse) GetIssuer

func (x *QueryVouchersByIssuerResponse) GetIssuer() string

func (*QueryVouchersByIssuerResponse) GetPagination

func (*QueryVouchersByIssuerResponse) GetVouchers

func (*QueryVouchersByIssuerResponse) ProtoMessage

func (*QueryVouchersByIssuerResponse) ProtoMessage()

func (*QueryVouchersByIssuerResponse) ProtoReflect

func (*QueryVouchersByIssuerResponse) Reset

func (x *QueryVouchersByIssuerResponse) Reset()

func (*QueryVouchersByIssuerResponse) String

type QueryVouchersByIssuerResponse_Voucher

type QueryVouchersByIssuerResponse_Voucher struct {

	// id is the unique identifier of the voucher.
	Id uint64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
	// metadata is the metadata of the voucher.
	Metadata string `protobuf:"bytes,2,opt,name=metadata,proto3" json:"metadata,omitempty"`
	// contains filtered or unexported fields
}

Voucher is the voucher properties.

func (*QueryVouchersByIssuerResponse_Voucher) Descriptor deprecated

func (*QueryVouchersByIssuerResponse_Voucher) Descriptor() ([]byte, []int)

Deprecated: Use QueryVouchersByIssuerResponse_Voucher.ProtoReflect.Descriptor instead.

func (*QueryVouchersByIssuerResponse_Voucher) GetId

func (*QueryVouchersByIssuerResponse_Voucher) GetMetadata

func (*QueryVouchersByIssuerResponse_Voucher) ProtoMessage

func (*QueryVouchersByIssuerResponse_Voucher) ProtoMessage()

func (*QueryVouchersByIssuerResponse_Voucher) ProtoReflect

func (*QueryVouchersByIssuerResponse_Voucher) Reset

func (*QueryVouchersByIssuerResponse_Voucher) String

type QueryVouchersRequest

type QueryVouchersRequest struct {

	// pagination is the optional pagination of the request.
	Pagination *v1beta1.PageRequest `protobuf:"bytes,1,opt,name=pagination,proto3" json:"pagination,omitempty"`
	// contains filtered or unexported fields
}

QueryVouchersRequest is the Query/Vouchers request type.

func (*QueryVouchersRequest) Descriptor deprecated

func (*QueryVouchersRequest) Descriptor() ([]byte, []int)

Deprecated: Use QueryVouchersRequest.ProtoReflect.Descriptor instead.

func (*QueryVouchersRequest) GetPagination

func (x *QueryVouchersRequest) GetPagination() *v1beta1.PageRequest

func (*QueryVouchersRequest) ProtoMessage

func (*QueryVouchersRequest) ProtoMessage()

func (*QueryVouchersRequest) ProtoReflect

func (x *QueryVouchersRequest) ProtoReflect() protoreflect.Message

func (*QueryVouchersRequest) Reset

func (x *QueryVouchersRequest) Reset()

func (*QueryVouchersRequest) String

func (x *QueryVouchersRequest) String() string

type QueryVouchersResponse

type QueryVouchersResponse struct {

	// vouchers is the list of vouchers.
	Vouchers []*QueryVouchersResponse_Voucher `protobuf:"bytes,1,rep,name=vouchers,proto3" json:"vouchers,omitempty"`
	// pagination is the pagination of the response.
	Pagination *v1beta1.PageResponse `protobuf:"bytes,2,opt,name=pagination,proto3" json:"pagination,omitempty"`
	// contains filtered or unexported fields
}

QueryVouchersResponse is the Query/Vouchers response type.

func (*QueryVouchersResponse) Descriptor deprecated

func (*QueryVouchersResponse) Descriptor() ([]byte, []int)

Deprecated: Use QueryVouchersResponse.ProtoReflect.Descriptor instead.

func (*QueryVouchersResponse) GetPagination

func (x *QueryVouchersResponse) GetPagination() *v1beta1.PageResponse

func (*QueryVouchersResponse) GetVouchers

func (*QueryVouchersResponse) ProtoMessage

func (*QueryVouchersResponse) ProtoMessage()

func (*QueryVouchersResponse) ProtoReflect

func (x *QueryVouchersResponse) ProtoReflect() protoreflect.Message

func (*QueryVouchersResponse) Reset

func (x *QueryVouchersResponse) Reset()

func (*QueryVouchersResponse) String

func (x *QueryVouchersResponse) String() string

type QueryVouchersResponse_Voucher

type QueryVouchersResponse_Voucher struct {

	// id is the unique identifier of the voucher.
	Id uint64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
	// issuer is the address of the voucher issuer.
	Issuer string `protobuf:"bytes,2,opt,name=issuer,proto3" json:"issuer,omitempty"`
	// metadata is the metadata of the voucher.
	Metadata string `protobuf:"bytes,3,opt,name=metadata,proto3" json:"metadata,omitempty"`
	// contains filtered or unexported fields
}

Voucher is the voucher properties.

func (*QueryVouchersResponse_Voucher) Descriptor deprecated

func (*QueryVouchersResponse_Voucher) Descriptor() ([]byte, []int)

Deprecated: Use QueryVouchersResponse_Voucher.ProtoReflect.Descriptor instead.

func (*QueryVouchersResponse_Voucher) GetId

func (*QueryVouchersResponse_Voucher) GetIssuer

func (x *QueryVouchersResponse_Voucher) GetIssuer() string

func (*QueryVouchersResponse_Voucher) GetMetadata

func (x *QueryVouchersResponse_Voucher) GetMetadata() string

func (*QueryVouchersResponse_Voucher) ProtoMessage

func (*QueryVouchersResponse_Voucher) ProtoMessage()

func (*QueryVouchersResponse_Voucher) ProtoReflect

func (*QueryVouchersResponse_Voucher) Reset

func (x *QueryVouchersResponse_Voucher) Reset()

func (*QueryVouchersResponse_Voucher) String

type StateStore

type StateStore interface {
	VoucherTable() VoucherTable
	BalanceTable() BalanceTable
	// contains filtered or unexported methods
}

func NewStateStore

func NewStateStore(db ormtable.Schema) (StateStore, error)

type UnimplementedMsgServer

type UnimplementedMsgServer struct {
}

UnimplementedMsgServer must be embedded to have forward compatible implementations.

func (UnimplementedMsgServer) Create

func (UnimplementedMsgServer) Issue

func (UnimplementedMsgServer) UpdateIssuer

func (UnimplementedMsgServer) UpdateMetadata

type UnimplementedQueryServer

type UnimplementedQueryServer struct {
}

UnimplementedQueryServer must be embedded to have forward compatible implementations.

func (UnimplementedQueryServer) Balance

func (UnimplementedQueryServer) Voucher

func (UnimplementedQueryServer) Vouchers

type UnsafeMsgServer

type UnsafeMsgServer interface {
	// contains filtered or unexported methods
}

UnsafeMsgServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to MsgServer will result in compilation errors.

type UnsafeQueryServer

type UnsafeQueryServer interface {
	// contains filtered or unexported methods
}

UnsafeQueryServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to QueryServer will result in compilation errors.

type Voucher

type Voucher struct {

	// id is the unique identifier of the voucher.
	Id uint64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
	// issuer is the address of the voucher issuer.
	Issuer []byte `protobuf:"bytes,2,opt,name=issuer,proto3" json:"issuer,omitempty"`
	// metadata is the metadata of the voucher.
	Metadata string `protobuf:"bytes,3,opt,name=metadata,proto3" json:"metadata,omitempty"`
	// contains filtered or unexported fields
}

Voucher defines the table and properties of a voucher.

func (*Voucher) Descriptor deprecated

func (*Voucher) Descriptor() ([]byte, []int)

Deprecated: Use Voucher.ProtoReflect.Descriptor instead.

func (*Voucher) GetId

func (x *Voucher) GetId() uint64

func (*Voucher) GetIssuer

func (x *Voucher) GetIssuer() []byte

func (*Voucher) GetMetadata

func (x *Voucher) GetMetadata() string

func (*Voucher) ProtoMessage

func (*Voucher) ProtoMessage()

func (*Voucher) ProtoReflect

func (x *Voucher) ProtoReflect() protoreflect.Message

func (*Voucher) Reset

func (x *Voucher) Reset()

func (*Voucher) String

func (x *Voucher) String() string

type VoucherIdIndexKey

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

func (VoucherIdIndexKey) WithId

func (this VoucherIdIndexKey) WithId(id uint64) VoucherIdIndexKey

type VoucherIndexKey

type VoucherIndexKey interface {
	// contains filtered or unexported methods
}

type VoucherIssuerIndexKey

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

func (VoucherIssuerIndexKey) WithIssuer

func (this VoucherIssuerIndexKey) WithIssuer(issuer []byte) VoucherIssuerIndexKey

type VoucherIterator

type VoucherIterator struct {
	ormtable.Iterator
}

func (VoucherIterator) Value

func (i VoucherIterator) Value() (*Voucher, error)

type VoucherPrimaryKey

type VoucherPrimaryKey = VoucherIdIndexKey

primary key starting index..

type VoucherTable

type VoucherTable interface {
	Insert(ctx context.Context, voucher *Voucher) error
	InsertReturningId(ctx context.Context, voucher *Voucher) (uint64, error)
	LastInsertedSequence(ctx context.Context) (uint64, error)
	Update(ctx context.Context, voucher *Voucher) error
	Save(ctx context.Context, voucher *Voucher) error
	Delete(ctx context.Context, voucher *Voucher) error
	Has(ctx context.Context, id uint64) (found bool, err error)
	// Get returns nil and an error which responds true to ormerrors.IsNotFound() if the record was not found.
	Get(ctx context.Context, id uint64) (*Voucher, error)
	List(ctx context.Context, prefixKey VoucherIndexKey, opts ...ormlist.Option) (VoucherIterator, error)
	ListRange(ctx context.Context, from, to VoucherIndexKey, opts ...ormlist.Option) (VoucherIterator, error)
	DeleteBy(ctx context.Context, prefixKey VoucherIndexKey) error
	DeleteRange(ctx context.Context, from, to VoucherIndexKey) error
	// contains filtered or unexported methods
}

func NewVoucherTable

func NewVoucherTable(db ormtable.Schema) (VoucherTable, error)

Jump to

Keyboard shortcuts

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