types

package
v12.0.0-rc4 Latest Latest
Warning

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

Go to latest
Published: Mar 1, 2024 License: Apache-2.0 Imports: 30 Imported by: 0

Documentation

Overview

Package types is a reverse proxy.

It translates gRPC into RESTful JSON APIs.

Index

Constants

View Source
const (
	ModuleName = "plan"
)

Variables

View Source
var (
	ErrorInvalidMessage = sdkerrors.Register(ModuleName, 101, "invalid message")

	ErrorNodeNotFound     = sdkerrors.Register(ModuleName, 201, "node not found")
	ErrorPlanNotFound     = sdkerrors.Register(ModuleName, 202, "plan not found")
	ErrorProviderNotFound = sdkerrors.Register(ModuleName, 203, "provider not found")
	ErrorUnauthorized     = sdkerrors.Register(ModuleName, 204, "unauthorised")
)
View Source
var (
	ErrInvalidLengthEvents        = fmt.Errorf("proto: negative length found during unmarshaling")
	ErrIntOverflowEvents          = fmt.Errorf("proto: integer overflow")
	ErrUnexpectedEndOfGroupEvents = fmt.Errorf("proto: unexpected end of group")
)
View Source
var (
	ErrInvalidLengthGenesis        = fmt.Errorf("proto: negative length found during unmarshaling")
	ErrIntOverflowGenesis          = fmt.Errorf("proto: integer overflow")
	ErrUnexpectedEndOfGroupGenesis = fmt.Errorf("proto: unexpected end of group")
)
View Source
var (
	CountKey = []byte{0x00}

	PlanKeyPrefix            = []byte{0x10}
	ActivePlanKeyPrefix      = append(PlanKeyPrefix, 0x01)
	InactivePlanKeyPrefix    = append(PlanKeyPrefix, 0x02)
	PlanForProviderKeyPrefix = []byte{0x11}
)
View Source
var (
	ErrInvalidLengthMsg        = fmt.Errorf("proto: negative length found during unmarshaling")
	ErrIntOverflowMsg          = fmt.Errorf("proto: integer overflow")
	ErrUnexpectedEndOfGroupMsg = fmt.Errorf("proto: unexpected end of group")
)
View Source
var (
	ErrInvalidLengthPlan        = fmt.Errorf("proto: negative length found during unmarshaling")
	ErrIntOverflowPlan          = fmt.Errorf("proto: integer overflow")
	ErrUnexpectedEndOfGroupPlan = fmt.Errorf("proto: unexpected end of group")
)
View Source
var (
	ErrInvalidLengthQuerier        = fmt.Errorf("proto: negative length found during unmarshaling")
	ErrIntOverflowQuerier          = fmt.Errorf("proto: integer overflow")
	ErrUnexpectedEndOfGroupQuerier = fmt.Errorf("proto: unexpected end of group")
)

Functions

func ActivePlanKey

func ActivePlanKey(id uint64) []byte

func GetPlanForProviderKeyPrefix

func GetPlanForProviderKeyPrefix(addr hubtypes.ProvAddress) []byte

func IDFromPlanForProviderKey

func IDFromPlanForProviderKey(key []byte) uint64

func InactivePlanKey

func InactivePlanKey(id uint64) []byte

func NewErrorNodeNotFound

func NewErrorNodeNotFound(addr interface{}) error

func NewErrorPlanNotFound

func NewErrorPlanNotFound(id uint64) error

func NewErrorProviderNotFound

func NewErrorProviderNotFound(addr interface{}) error

func NewErrorUnauthorized

func NewErrorUnauthorized(addr interface{}) error

func PlanForProviderKey

func PlanForProviderKey(addr hubtypes.ProvAddress, id uint64) []byte

func RegisterInterfaces

func RegisterInterfaces(registry codectypes.InterfaceRegistry)

func RegisterMsgServiceServer

func RegisterMsgServiceServer(s grpc1.Server, srv MsgServiceServer)

func RegisterQueryServiceHandler

func RegisterQueryServiceHandler(ctx context.Context, mux *runtime.ServeMux, conn *grpc.ClientConn) error

RegisterQueryServiceHandler registers the http handlers for service QueryService to "mux". The handlers forward requests to the grpc endpoint over "conn".

func RegisterQueryServiceHandlerClient

func RegisterQueryServiceHandlerClient(ctx context.Context, mux *runtime.ServeMux, client QueryServiceClient) error

RegisterQueryServiceHandlerClient registers the http handlers for service QueryService to "mux". The handlers forward requests to the grpc endpoint over the given implementation of "QueryServiceClient". Note: the gRPC framework executes interceptors within the gRPC handler. If the passed in "QueryServiceClient" doesn't go through the normal gRPC flow (creating a gRPC client etc.) then it will be up to the passed in "QueryServiceClient" to call the correct interceptors.

func RegisterQueryServiceHandlerFromEndpoint

func RegisterQueryServiceHandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, opts []grpc.DialOption) (err error)

RegisterQueryServiceHandlerFromEndpoint is same as RegisterQueryServiceHandler but automatically dials to "endpoint" and closes the connection when "ctx" gets done.

func RegisterQueryServiceHandlerServer

func RegisterQueryServiceHandlerServer(ctx context.Context, mux *runtime.ServeMux, server QueryServiceServer) error

RegisterQueryServiceHandlerServer registers the http handlers for service QueryService to "mux". UnaryRPC :call QueryServiceServer directly. StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906. Note that using this registration option will cause many gRPC library features to stop working. Consider using RegisterQueryServiceHandlerFromEndpoint instead.

func RegisterQueryServiceServer

func RegisterQueryServiceServer(s grpc1.Server, srv QueryServiceServer)

func ValidateGenesis

func ValidateGenesis(state GenesisState) error

Types

type EventCreate

type EventCreate struct {
	// Field 1: Address associated with the event.
	Address string `protobuf:"bytes,1,opt,name=address,proto3" json:"address,omitempty" yaml:"address"`
	// Field 2: Identifier associated with the event.
	ID uint64 `protobuf:"varint,2,opt,name=id,proto3" json:"id,omitempty" yaml:"id"`
}

EventCreate represents an event for creating an entity.

func (*EventCreate) Descriptor

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

func (*EventCreate) Marshal

func (m *EventCreate) Marshal() (dAtA []byte, err error)

func (*EventCreate) MarshalTo

func (m *EventCreate) MarshalTo(dAtA []byte) (int, error)

func (*EventCreate) MarshalToSizedBuffer

func (m *EventCreate) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*EventCreate) ProtoMessage

func (*EventCreate) ProtoMessage()

func (*EventCreate) Reset

func (m *EventCreate) Reset()

func (*EventCreate) Size

func (m *EventCreate) Size() (n int)

func (*EventCreate) String

func (m *EventCreate) String() string

func (*EventCreate) Unmarshal

func (m *EventCreate) Unmarshal(dAtA []byte) error

func (*EventCreate) XXX_DiscardUnknown

func (m *EventCreate) XXX_DiscardUnknown()

func (*EventCreate) XXX_Marshal

func (m *EventCreate) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*EventCreate) XXX_Merge

func (m *EventCreate) XXX_Merge(src proto.Message)

func (*EventCreate) XXX_Size

func (m *EventCreate) XXX_Size() int

func (*EventCreate) XXX_Unmarshal

func (m *EventCreate) XXX_Unmarshal(b []byte) error

type EventCreateSubscription

type EventCreateSubscription struct {
	// Field 1: Address associated with the event.
	Address string `protobuf:"bytes,1,opt,name=address,proto3" json:"address,omitempty" yaml:"address"`
	// Field 2: Provider address associated with the event.
	ProviderAddress string `` /* 130-byte string literal not displayed */
	// Field 3: Identifier associated with the event.
	ID uint64 `protobuf:"varint,3,opt,name=id,proto3" json:"id,omitempty" yaml:"id"`
	// Field 4: Plan ID associated with the event.
	PlanID uint64 `protobuf:"varint,4,opt,name=plan_id,json=planId,proto3" json:"plan_id,omitempty" yaml:"plan_id"`
}

EventCreateSubscription represents an event for creating a subscription.

func (*EventCreateSubscription) Descriptor

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

func (*EventCreateSubscription) Marshal

func (m *EventCreateSubscription) Marshal() (dAtA []byte, err error)

func (*EventCreateSubscription) MarshalTo

func (m *EventCreateSubscription) MarshalTo(dAtA []byte) (int, error)

func (*EventCreateSubscription) MarshalToSizedBuffer

func (m *EventCreateSubscription) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*EventCreateSubscription) ProtoMessage

func (*EventCreateSubscription) ProtoMessage()

func (*EventCreateSubscription) Reset

func (m *EventCreateSubscription) Reset()

func (*EventCreateSubscription) Size

func (m *EventCreateSubscription) Size() (n int)

func (*EventCreateSubscription) String

func (m *EventCreateSubscription) String() string

func (*EventCreateSubscription) Unmarshal

func (m *EventCreateSubscription) Unmarshal(dAtA []byte) error

func (*EventCreateSubscription) XXX_DiscardUnknown

func (m *EventCreateSubscription) XXX_DiscardUnknown()

func (*EventCreateSubscription) XXX_Marshal

func (m *EventCreateSubscription) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*EventCreateSubscription) XXX_Merge

func (m *EventCreateSubscription) XXX_Merge(src proto.Message)

func (*EventCreateSubscription) XXX_Size

func (m *EventCreateSubscription) XXX_Size() int

func (*EventCreateSubscription) XXX_Unmarshal

func (m *EventCreateSubscription) XXX_Unmarshal(b []byte) error

type EventLinkNode

type EventLinkNode struct {
	// Field 1: Address associated with the event.
	Address string `protobuf:"bytes,1,opt,name=address,proto3" json:"address,omitempty" yaml:"address"`
	// Field 2: Node address associated with the event.
	NodeAddress string `protobuf:"bytes,2,opt,name=node_address,json=nodeAddress,proto3" json:"node_address,omitempty" yaml:"node_address"`
	// Field 3: Identifier associated with the event.
	ID uint64 `protobuf:"varint,3,opt,name=id,proto3" json:"id,omitempty" yaml:"id"`
}

EventLinkNode represents an event for linking a node to an entity.

func (*EventLinkNode) Descriptor

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

func (*EventLinkNode) Marshal

func (m *EventLinkNode) Marshal() (dAtA []byte, err error)

func (*EventLinkNode) MarshalTo

func (m *EventLinkNode) MarshalTo(dAtA []byte) (int, error)

func (*EventLinkNode) MarshalToSizedBuffer

func (m *EventLinkNode) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*EventLinkNode) ProtoMessage

func (*EventLinkNode) ProtoMessage()

func (*EventLinkNode) Reset

func (m *EventLinkNode) Reset()

func (*EventLinkNode) Size

func (m *EventLinkNode) Size() (n int)

func (*EventLinkNode) String

func (m *EventLinkNode) String() string

func (*EventLinkNode) Unmarshal

func (m *EventLinkNode) Unmarshal(dAtA []byte) error

func (*EventLinkNode) XXX_DiscardUnknown

func (m *EventLinkNode) XXX_DiscardUnknown()

func (*EventLinkNode) XXX_Marshal

func (m *EventLinkNode) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*EventLinkNode) XXX_Merge

func (m *EventLinkNode) XXX_Merge(src proto.Message)

func (*EventLinkNode) XXX_Size

func (m *EventLinkNode) XXX_Size() int

func (*EventLinkNode) XXX_Unmarshal

func (m *EventLinkNode) XXX_Unmarshal(b []byte) error

type EventUnlinkNode

type EventUnlinkNode struct {
	// Field 1: Address associated with the event.
	Address string `protobuf:"bytes,1,opt,name=address,proto3" json:"address,omitempty" yaml:"address"`
	// Field 2: Node address associated with the event.
	NodeAddress string `protobuf:"bytes,2,opt,name=node_address,json=nodeAddress,proto3" json:"node_address,omitempty" yaml:"node_address"`
	// Field 3: Identifier associated with the event.
	ID uint64 `protobuf:"varint,3,opt,name=id,proto3" json:"id,omitempty" yaml:"id"`
}

EventUnlinkNode represents an event for unlinking a node from an entity.

func (*EventUnlinkNode) Descriptor

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

func (*EventUnlinkNode) Marshal

func (m *EventUnlinkNode) Marshal() (dAtA []byte, err error)

func (*EventUnlinkNode) MarshalTo

func (m *EventUnlinkNode) MarshalTo(dAtA []byte) (int, error)

func (*EventUnlinkNode) MarshalToSizedBuffer

func (m *EventUnlinkNode) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*EventUnlinkNode) ProtoMessage

func (*EventUnlinkNode) ProtoMessage()

func (*EventUnlinkNode) Reset

func (m *EventUnlinkNode) Reset()

func (*EventUnlinkNode) Size

func (m *EventUnlinkNode) Size() (n int)

func (*EventUnlinkNode) String

func (m *EventUnlinkNode) String() string

func (*EventUnlinkNode) Unmarshal

func (m *EventUnlinkNode) Unmarshal(dAtA []byte) error

func (*EventUnlinkNode) XXX_DiscardUnknown

func (m *EventUnlinkNode) XXX_DiscardUnknown()

func (*EventUnlinkNode) XXX_Marshal

func (m *EventUnlinkNode) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*EventUnlinkNode) XXX_Merge

func (m *EventUnlinkNode) XXX_Merge(src proto.Message)

func (*EventUnlinkNode) XXX_Size

func (m *EventUnlinkNode) XXX_Size() int

func (*EventUnlinkNode) XXX_Unmarshal

func (m *EventUnlinkNode) XXX_Unmarshal(b []byte) error

type EventUpdateStatus

type EventUpdateStatus struct {
	// Field 1: Status associated with the event.
	Status types.Status `protobuf:"varint,1,opt,name=status,proto3,enum=sentinel.types.v1.Status" json:"status,omitempty" yaml:"status"`
	// Field 2: Address associated with the event.
	Address string `protobuf:"bytes,2,opt,name=address,proto3" json:"address,omitempty" yaml:"address"`
	// Field 3: Identifier associated with the event.
	ID uint64 `protobuf:"varint,3,opt,name=id,proto3" json:"id,omitempty" yaml:"id"`
}

EventUpdateStatus represents an event for updating the status of an entity.

func (*EventUpdateStatus) Descriptor

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

func (*EventUpdateStatus) Marshal

func (m *EventUpdateStatus) Marshal() (dAtA []byte, err error)

func (*EventUpdateStatus) MarshalTo

func (m *EventUpdateStatus) MarshalTo(dAtA []byte) (int, error)

func (*EventUpdateStatus) MarshalToSizedBuffer

func (m *EventUpdateStatus) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*EventUpdateStatus) ProtoMessage

func (*EventUpdateStatus) ProtoMessage()

func (*EventUpdateStatus) Reset

func (m *EventUpdateStatus) Reset()

func (*EventUpdateStatus) Size

func (m *EventUpdateStatus) Size() (n int)

func (*EventUpdateStatus) String

func (m *EventUpdateStatus) String() string

func (*EventUpdateStatus) Unmarshal

func (m *EventUpdateStatus) Unmarshal(dAtA []byte) error

func (*EventUpdateStatus) XXX_DiscardUnknown

func (m *EventUpdateStatus) XXX_DiscardUnknown()

func (*EventUpdateStatus) XXX_Marshal

func (m *EventUpdateStatus) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*EventUpdateStatus) XXX_Merge

func (m *EventUpdateStatus) XXX_Merge(src proto.Message)

func (*EventUpdateStatus) XXX_Size

func (m *EventUpdateStatus) XXX_Size() int

func (*EventUpdateStatus) XXX_Unmarshal

func (m *EventUpdateStatus) XXX_Unmarshal(b []byte) error

type GenesisPlan

type GenesisPlan struct {
	// Field 1: Plan information.
	// - (gogoproto.nullable) = false: Field is not nullable.
	Plan Plan `protobuf:"bytes,1,opt,name=plan,proto3" json:"plan"`
	// Field 2: List of node addresses associated with the plan.
	Nodes []string `protobuf:"bytes,2,rep,name=nodes,proto3" json:"nodes,omitempty"`
}

GenesisPlan represents the genesis state for a plan.

func (*GenesisPlan) Descriptor

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

func (*GenesisPlan) Marshal

func (m *GenesisPlan) Marshal() (dAtA []byte, err error)

func (*GenesisPlan) MarshalTo

func (m *GenesisPlan) MarshalTo(dAtA []byte) (int, error)

func (*GenesisPlan) MarshalToSizedBuffer

func (m *GenesisPlan) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*GenesisPlan) ProtoMessage

func (*GenesisPlan) ProtoMessage()

func (*GenesisPlan) Reset

func (m *GenesisPlan) Reset()

func (*GenesisPlan) Size

func (m *GenesisPlan) Size() (n int)

func (*GenesisPlan) String

func (m *GenesisPlan) String() string

func (*GenesisPlan) Unmarshal

func (m *GenesisPlan) Unmarshal(dAtA []byte) error

func (*GenesisPlan) XXX_DiscardUnknown

func (m *GenesisPlan) XXX_DiscardUnknown()

func (*GenesisPlan) XXX_Marshal

func (m *GenesisPlan) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*GenesisPlan) XXX_Merge

func (m *GenesisPlan) XXX_Merge(src proto.Message)

func (*GenesisPlan) XXX_Size

func (m *GenesisPlan) XXX_Size() int

func (*GenesisPlan) XXX_Unmarshal

func (m *GenesisPlan) XXX_Unmarshal(b []byte) error

type GenesisPlans

type GenesisPlans []GenesisPlan

type GenesisState

type GenesisState GenesisPlans

func DefaultGenesisState

func DefaultGenesisState() GenesisState

func NewGenesisState

func NewGenesisState(plans GenesisPlans) GenesisState

type MsgCreateRequest

type MsgCreateRequest struct {
	// Field 1: Sender's address.
	From string `protobuf:"bytes,1,opt,name=from,proto3" json:"from,omitempty"`
	// Field 2: Duration of the subscription plan.
	Duration time.Duration `protobuf:"bytes,2,opt,name=duration,proto3,stdduration" json:"duration"`
	// Field 3: Amount of gigabytes in the subscription plan.
	Gigabytes int64 `protobuf:"varint,3,opt,name=gigabytes,proto3" json:"gigabytes,omitempty"`
	// Field 4: Prices associated with the subscription plan.
	Prices github_com_cosmos_cosmos_sdk_types.Coins `protobuf:"bytes,4,rep,name=prices,proto3,castrepeated=github.com/cosmos/cosmos-sdk/types.Coins" json:"prices"`
}

MsgCreateRequest defines the SDK message for creating a subscription plan.

func NewMsgCreateRequest

func NewMsgCreateRequest(from hubtypes.ProvAddress, duration time.Duration, gigabytes int64, prices sdk.Coins) *MsgCreateRequest

NewMsgCreateRequest creates a new MsgCreateRequest instance with the given parameters.

func (*MsgCreateRequest) Descriptor

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

func (*MsgCreateRequest) GetSigners

func (m *MsgCreateRequest) GetSigners() []sdk.AccAddress

GetSigners returns an array containing the signer's account address extracted from the 'From' field of the MsgCreateRequest.

func (*MsgCreateRequest) Marshal

func (m *MsgCreateRequest) Marshal() (dAtA []byte, err error)

func (*MsgCreateRequest) MarshalTo

func (m *MsgCreateRequest) MarshalTo(dAtA []byte) (int, error)

func (*MsgCreateRequest) MarshalToSizedBuffer

func (m *MsgCreateRequest) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*MsgCreateRequest) ProtoMessage

func (*MsgCreateRequest) ProtoMessage()

func (*MsgCreateRequest) Reset

func (m *MsgCreateRequest) Reset()

func (*MsgCreateRequest) Size

func (m *MsgCreateRequest) Size() (n int)

func (*MsgCreateRequest) String

func (m *MsgCreateRequest) String() string

func (*MsgCreateRequest) Unmarshal

func (m *MsgCreateRequest) Unmarshal(dAtA []byte) error

func (*MsgCreateRequest) ValidateBasic

func (m *MsgCreateRequest) ValidateBasic() error

ValidateBasic performs basic validation checks on the MsgCreateRequest fields. It checks if the 'From' field is not empty and represents a valid provider address, if the 'Duration' field is not negative or zero, if the 'Gigabytes' field is not negative or zero, and if the 'Prices' field is valid (not empty, not containing nil coins, and having valid coin denominations).

func (*MsgCreateRequest) XXX_DiscardUnknown

func (m *MsgCreateRequest) XXX_DiscardUnknown()

func (*MsgCreateRequest) XXX_Marshal

func (m *MsgCreateRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*MsgCreateRequest) XXX_Merge

func (m *MsgCreateRequest) XXX_Merge(src proto.Message)

func (*MsgCreateRequest) XXX_Size

func (m *MsgCreateRequest) XXX_Size() int

func (*MsgCreateRequest) XXX_Unmarshal

func (m *MsgCreateRequest) XXX_Unmarshal(b []byte) error

type MsgCreateResponse

type MsgCreateResponse struct {
}

MsgCreateResponse defines the response of message MsgCreateRequest.

func (*MsgCreateResponse) Descriptor

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

func (*MsgCreateResponse) Marshal

func (m *MsgCreateResponse) Marshal() (dAtA []byte, err error)

func (*MsgCreateResponse) MarshalTo

func (m *MsgCreateResponse) MarshalTo(dAtA []byte) (int, error)

func (*MsgCreateResponse) MarshalToSizedBuffer

func (m *MsgCreateResponse) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*MsgCreateResponse) ProtoMessage

func (*MsgCreateResponse) ProtoMessage()

func (*MsgCreateResponse) Reset

func (m *MsgCreateResponse) Reset()

func (*MsgCreateResponse) Size

func (m *MsgCreateResponse) Size() (n int)

func (*MsgCreateResponse) String

func (m *MsgCreateResponse) String() string

func (*MsgCreateResponse) Unmarshal

func (m *MsgCreateResponse) Unmarshal(dAtA []byte) error

func (*MsgCreateResponse) XXX_DiscardUnknown

func (m *MsgCreateResponse) XXX_DiscardUnknown()

func (*MsgCreateResponse) XXX_Marshal

func (m *MsgCreateResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*MsgCreateResponse) XXX_Merge

func (m *MsgCreateResponse) XXX_Merge(src proto.Message)

func (*MsgCreateResponse) XXX_Size

func (m *MsgCreateResponse) XXX_Size() int

func (*MsgCreateResponse) XXX_Unmarshal

func (m *MsgCreateResponse) XXX_Unmarshal(b []byte) error

type MsgLinkNodeRequest

type MsgLinkNodeRequest struct {
	// Field 1: Sender's address.
	From string `protobuf:"bytes,1,opt,name=from,proto3" json:"from,omitempty"`
	// Field 2: Identifier of the subscription plan.
	ID uint64 `protobuf:"varint,2,opt,name=id,proto3" json:"id,omitempty"`
	// Field 3: Node address to be linked to the subscription plan.
	NodeAddress string `protobuf:"bytes,3,opt,name=node_address,json=nodeAddress,proto3" json:"node_address,omitempty"`
}

MsgLinkNodeRequest defines the SDK message for adding a node to a subscription plan.

func NewMsgLinkNodeRequest

func NewMsgLinkNodeRequest(from hubtypes.ProvAddress, id uint64, addr hubtypes.NodeAddress) *MsgLinkNodeRequest

NewMsgLinkNodeRequest creates a new MsgLinkNodeRequest instance with the given parameters.

func (*MsgLinkNodeRequest) Descriptor

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

func (*MsgLinkNodeRequest) GetSigners

func (m *MsgLinkNodeRequest) GetSigners() []sdk.AccAddress

GetSigners returns an array containing the signer's account address extracted from the 'From' field of the MsgLinkNodeRequest.

func (*MsgLinkNodeRequest) Marshal

func (m *MsgLinkNodeRequest) Marshal() (dAtA []byte, err error)

func (*MsgLinkNodeRequest) MarshalTo

func (m *MsgLinkNodeRequest) MarshalTo(dAtA []byte) (int, error)

func (*MsgLinkNodeRequest) MarshalToSizedBuffer

func (m *MsgLinkNodeRequest) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*MsgLinkNodeRequest) ProtoMessage

func (*MsgLinkNodeRequest) ProtoMessage()

func (*MsgLinkNodeRequest) Reset

func (m *MsgLinkNodeRequest) Reset()

func (*MsgLinkNodeRequest) Size

func (m *MsgLinkNodeRequest) Size() (n int)

func (*MsgLinkNodeRequest) String

func (m *MsgLinkNodeRequest) String() string

func (*MsgLinkNodeRequest) Unmarshal

func (m *MsgLinkNodeRequest) Unmarshal(dAtA []byte) error

func (*MsgLinkNodeRequest) ValidateBasic

func (m *MsgLinkNodeRequest) ValidateBasic() error

ValidateBasic performs basic validation checks on the MsgLinkNodeRequest fields. It checks if the 'From' field is not empty and represents a valid provider address, if the 'ID' field is not zero, and if the 'Address' field is not empty and represents a valid node address.

func (*MsgLinkNodeRequest) XXX_DiscardUnknown

func (m *MsgLinkNodeRequest) XXX_DiscardUnknown()

func (*MsgLinkNodeRequest) XXX_Marshal

func (m *MsgLinkNodeRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*MsgLinkNodeRequest) XXX_Merge

func (m *MsgLinkNodeRequest) XXX_Merge(src proto.Message)

func (*MsgLinkNodeRequest) XXX_Size

func (m *MsgLinkNodeRequest) XXX_Size() int

func (*MsgLinkNodeRequest) XXX_Unmarshal

func (m *MsgLinkNodeRequest) XXX_Unmarshal(b []byte) error

type MsgLinkNodeResponse

type MsgLinkNodeResponse struct {
}

MsgLinkNodeResponse defines the response of message MsgLinkNodeRequest.

func (*MsgLinkNodeResponse) Descriptor

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

func (*MsgLinkNodeResponse) Marshal

func (m *MsgLinkNodeResponse) Marshal() (dAtA []byte, err error)

func (*MsgLinkNodeResponse) MarshalTo

func (m *MsgLinkNodeResponse) MarshalTo(dAtA []byte) (int, error)

func (*MsgLinkNodeResponse) MarshalToSizedBuffer

func (m *MsgLinkNodeResponse) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*MsgLinkNodeResponse) ProtoMessage

func (*MsgLinkNodeResponse) ProtoMessage()

func (*MsgLinkNodeResponse) Reset

func (m *MsgLinkNodeResponse) Reset()

func (*MsgLinkNodeResponse) Size

func (m *MsgLinkNodeResponse) Size() (n int)

func (*MsgLinkNodeResponse) String

func (m *MsgLinkNodeResponse) String() string

func (*MsgLinkNodeResponse) Unmarshal

func (m *MsgLinkNodeResponse) Unmarshal(dAtA []byte) error

func (*MsgLinkNodeResponse) XXX_DiscardUnknown

func (m *MsgLinkNodeResponse) XXX_DiscardUnknown()

func (*MsgLinkNodeResponse) XXX_Marshal

func (m *MsgLinkNodeResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*MsgLinkNodeResponse) XXX_Merge

func (m *MsgLinkNodeResponse) XXX_Merge(src proto.Message)

func (*MsgLinkNodeResponse) XXX_Size

func (m *MsgLinkNodeResponse) XXX_Size() int

func (*MsgLinkNodeResponse) XXX_Unmarshal

func (m *MsgLinkNodeResponse) XXX_Unmarshal(b []byte) error

type MsgServiceClient

type MsgServiceClient interface {
	// RPC method for creating a subscription plan.
	MsgCreate(ctx context.Context, in *MsgCreateRequest, opts ...grpc.CallOption) (*MsgCreateResponse, error)
	// RPC method for modifying the status of a subscription plan.
	MsgUpdateStatus(ctx context.Context, in *MsgUpdateStatusRequest, opts ...grpc.CallOption) (*MsgUpdateStatusResponse, error)
	// RPC method for linking a node to a subscription plan.
	MsgLinkNode(ctx context.Context, in *MsgLinkNodeRequest, opts ...grpc.CallOption) (*MsgLinkNodeResponse, error)
	// RPC method for unlinking a node from a subscription plan.
	MsgUnlinkNode(ctx context.Context, in *MsgUnlinkNodeRequest, opts ...grpc.CallOption) (*MsgUnlinkNodeResponse, error)
	// RPC method for subscribing to a subscription plan.
	MsgSubscribe(ctx context.Context, in *MsgSubscribeRequest, opts ...grpc.CallOption) (*MsgSubscribeResponse, error)
}

MsgServiceClient is the client API for MsgService service.

For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.

func NewMsgServiceClient

func NewMsgServiceClient(cc grpc1.ClientConn) MsgServiceClient

type MsgServiceServer

type MsgServiceServer interface {
	// RPC method for creating a subscription plan.
	MsgCreate(context.Context, *MsgCreateRequest) (*MsgCreateResponse, error)
	// RPC method for modifying the status of a subscription plan.
	MsgUpdateStatus(context.Context, *MsgUpdateStatusRequest) (*MsgUpdateStatusResponse, error)
	// RPC method for linking a node to a subscription plan.
	MsgLinkNode(context.Context, *MsgLinkNodeRequest) (*MsgLinkNodeResponse, error)
	// RPC method for unlinking a node from a subscription plan.
	MsgUnlinkNode(context.Context, *MsgUnlinkNodeRequest) (*MsgUnlinkNodeResponse, error)
	// RPC method for subscribing to a subscription plan.
	MsgSubscribe(context.Context, *MsgSubscribeRequest) (*MsgSubscribeResponse, error)
}

MsgServiceServer is the server API for MsgService service.

type MsgSubscribeRequest

type MsgSubscribeRequest struct {
	// Field 1: Sender's address.
	From string `protobuf:"bytes,1,opt,name=from,proto3" json:"from,omitempty"`
	// Field 2: Identifier of the subscription plan.
	ID uint64 `protobuf:"varint,2,opt,name=id,proto3" json:"id,omitempty"`
	// Field 3: Denomination for the subscription.
	Denom string `protobuf:"bytes,3,opt,name=denom,proto3" json:"denom,omitempty"`
}

MsgSubscribeRequest defines the SDK message for subscribing to a subscription plan.

func NewMsgSubscribeRequest

func NewMsgSubscribeRequest(from sdk.AccAddress, id uint64, denom string) *MsgSubscribeRequest

NewMsgSubscribeRequest creates a new MsgSubscribeRequest instance with the given parameters.

func (*MsgSubscribeRequest) Descriptor

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

func (*MsgSubscribeRequest) GetSigners

func (m *MsgSubscribeRequest) GetSigners() []sdk.AccAddress

GetSigners returns an array containing the signer's account address extracted from the 'From' field of the MsgSubscribeRequest.

func (*MsgSubscribeRequest) Marshal

func (m *MsgSubscribeRequest) Marshal() (dAtA []byte, err error)

func (*MsgSubscribeRequest) MarshalTo

func (m *MsgSubscribeRequest) MarshalTo(dAtA []byte) (int, error)

func (*MsgSubscribeRequest) MarshalToSizedBuffer

func (m *MsgSubscribeRequest) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*MsgSubscribeRequest) ProtoMessage

func (*MsgSubscribeRequest) ProtoMessage()

func (*MsgSubscribeRequest) Reset

func (m *MsgSubscribeRequest) Reset()

func (*MsgSubscribeRequest) Size

func (m *MsgSubscribeRequest) Size() (n int)

func (*MsgSubscribeRequest) String

func (m *MsgSubscribeRequest) String() string

func (*MsgSubscribeRequest) Unmarshal

func (m *MsgSubscribeRequest) Unmarshal(dAtA []byte) error

func (*MsgSubscribeRequest) ValidateBasic

func (m *MsgSubscribeRequest) ValidateBasic() error

ValidateBasic performs basic validation checks on the MsgSubscribeRequest fields. It checks if the 'From' field is not empty and represents a valid account address, if the 'ID' field is not zero, and if the 'Denom' field is valid according to the Cosmos SDK's ValidateDenom function.

func (*MsgSubscribeRequest) XXX_DiscardUnknown

func (m *MsgSubscribeRequest) XXX_DiscardUnknown()

func (*MsgSubscribeRequest) XXX_Marshal

func (m *MsgSubscribeRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*MsgSubscribeRequest) XXX_Merge

func (m *MsgSubscribeRequest) XXX_Merge(src proto.Message)

func (*MsgSubscribeRequest) XXX_Size

func (m *MsgSubscribeRequest) XXX_Size() int

func (*MsgSubscribeRequest) XXX_Unmarshal

func (m *MsgSubscribeRequest) XXX_Unmarshal(b []byte) error

type MsgSubscribeResponse

type MsgSubscribeResponse struct {
}

MsgSubscribeResponse defines the response of message MsgSubscribeRequest.

func (*MsgSubscribeResponse) Descriptor

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

func (*MsgSubscribeResponse) Marshal

func (m *MsgSubscribeResponse) Marshal() (dAtA []byte, err error)

func (*MsgSubscribeResponse) MarshalTo

func (m *MsgSubscribeResponse) MarshalTo(dAtA []byte) (int, error)

func (*MsgSubscribeResponse) MarshalToSizedBuffer

func (m *MsgSubscribeResponse) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*MsgSubscribeResponse) ProtoMessage

func (*MsgSubscribeResponse) ProtoMessage()

func (*MsgSubscribeResponse) Reset

func (m *MsgSubscribeResponse) Reset()

func (*MsgSubscribeResponse) Size

func (m *MsgSubscribeResponse) Size() (n int)

func (*MsgSubscribeResponse) String

func (m *MsgSubscribeResponse) String() string

func (*MsgSubscribeResponse) Unmarshal

func (m *MsgSubscribeResponse) Unmarshal(dAtA []byte) error

func (*MsgSubscribeResponse) XXX_DiscardUnknown

func (m *MsgSubscribeResponse) XXX_DiscardUnknown()

func (*MsgSubscribeResponse) XXX_Marshal

func (m *MsgSubscribeResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*MsgSubscribeResponse) XXX_Merge

func (m *MsgSubscribeResponse) XXX_Merge(src proto.Message)

func (*MsgSubscribeResponse) XXX_Size

func (m *MsgSubscribeResponse) XXX_Size() int

func (*MsgSubscribeResponse) XXX_Unmarshal

func (m *MsgSubscribeResponse) XXX_Unmarshal(b []byte) error

type MsgUnlinkNodeRequest

type MsgUnlinkNodeRequest struct {
	// Field 1: Sender's address.
	From string `protobuf:"bytes,1,opt,name=from,proto3" json:"from,omitempty"`
	// Field 2: Identifier of the subscription plan.
	ID uint64 `protobuf:"varint,2,opt,name=id,proto3" json:"id,omitempty"`
	// Field 3: Node address to be unlinked from the subscription plan.
	NodeAddress string `protobuf:"bytes,3,opt,name=node_address,json=nodeAddress,proto3" json:"node_address,omitempty"`
}

MsgUnlinkNodeRequest defines the SDK message for removing a node from a subscription plan.

func NewMsgUnlinkNodeRequest

func NewMsgUnlinkNodeRequest(from hubtypes.ProvAddress, id uint64, addr hubtypes.NodeAddress) *MsgUnlinkNodeRequest

NewMsgUnlinkNodeRequest creates a new MsgUnlinkNodeRequest instance with the given parameters.

func (*MsgUnlinkNodeRequest) Descriptor

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

func (*MsgUnlinkNodeRequest) GetSigners

func (m *MsgUnlinkNodeRequest) GetSigners() []sdk.AccAddress

GetSigners returns an array containing the signer's account address extracted from the 'From' field of the MsgUnlinkNodeRequest.

func (*MsgUnlinkNodeRequest) Marshal

func (m *MsgUnlinkNodeRequest) Marshal() (dAtA []byte, err error)

func (*MsgUnlinkNodeRequest) MarshalTo

func (m *MsgUnlinkNodeRequest) MarshalTo(dAtA []byte) (int, error)

func (*MsgUnlinkNodeRequest) MarshalToSizedBuffer

func (m *MsgUnlinkNodeRequest) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*MsgUnlinkNodeRequest) ProtoMessage

func (*MsgUnlinkNodeRequest) ProtoMessage()

func (*MsgUnlinkNodeRequest) Reset

func (m *MsgUnlinkNodeRequest) Reset()

func (*MsgUnlinkNodeRequest) Size

func (m *MsgUnlinkNodeRequest) Size() (n int)

func (*MsgUnlinkNodeRequest) String

func (m *MsgUnlinkNodeRequest) String() string

func (*MsgUnlinkNodeRequest) Unmarshal

func (m *MsgUnlinkNodeRequest) Unmarshal(dAtA []byte) error

func (*MsgUnlinkNodeRequest) ValidateBasic

func (m *MsgUnlinkNodeRequest) ValidateBasic() error

ValidateBasic performs basic validation checks on the MsgUnlinkNodeRequest fields. It checks if the 'From' field is not empty and represents a valid provider address, if the 'ID' field is not zero, and if the 'Address' field is not empty and represents a valid node address.

func (*MsgUnlinkNodeRequest) XXX_DiscardUnknown

func (m *MsgUnlinkNodeRequest) XXX_DiscardUnknown()

func (*MsgUnlinkNodeRequest) XXX_Marshal

func (m *MsgUnlinkNodeRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*MsgUnlinkNodeRequest) XXX_Merge

func (m *MsgUnlinkNodeRequest) XXX_Merge(src proto.Message)

func (*MsgUnlinkNodeRequest) XXX_Size

func (m *MsgUnlinkNodeRequest) XXX_Size() int

func (*MsgUnlinkNodeRequest) XXX_Unmarshal

func (m *MsgUnlinkNodeRequest) XXX_Unmarshal(b []byte) error

type MsgUnlinkNodeResponse

type MsgUnlinkNodeResponse struct {
}

MsgUnlinkNodeResponse defines the response of message MsgUnlinkNodeRequest.

func (*MsgUnlinkNodeResponse) Descriptor

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

func (*MsgUnlinkNodeResponse) Marshal

func (m *MsgUnlinkNodeResponse) Marshal() (dAtA []byte, err error)

func (*MsgUnlinkNodeResponse) MarshalTo

func (m *MsgUnlinkNodeResponse) MarshalTo(dAtA []byte) (int, error)

func (*MsgUnlinkNodeResponse) MarshalToSizedBuffer

func (m *MsgUnlinkNodeResponse) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*MsgUnlinkNodeResponse) ProtoMessage

func (*MsgUnlinkNodeResponse) ProtoMessage()

func (*MsgUnlinkNodeResponse) Reset

func (m *MsgUnlinkNodeResponse) Reset()

func (*MsgUnlinkNodeResponse) Size

func (m *MsgUnlinkNodeResponse) Size() (n int)

func (*MsgUnlinkNodeResponse) String

func (m *MsgUnlinkNodeResponse) String() string

func (*MsgUnlinkNodeResponse) Unmarshal

func (m *MsgUnlinkNodeResponse) Unmarshal(dAtA []byte) error

func (*MsgUnlinkNodeResponse) XXX_DiscardUnknown

func (m *MsgUnlinkNodeResponse) XXX_DiscardUnknown()

func (*MsgUnlinkNodeResponse) XXX_Marshal

func (m *MsgUnlinkNodeResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*MsgUnlinkNodeResponse) XXX_Merge

func (m *MsgUnlinkNodeResponse) XXX_Merge(src proto.Message)

func (*MsgUnlinkNodeResponse) XXX_Size

func (m *MsgUnlinkNodeResponse) XXX_Size() int

func (*MsgUnlinkNodeResponse) XXX_Unmarshal

func (m *MsgUnlinkNodeResponse) XXX_Unmarshal(b []byte) error

type MsgUpdateStatusRequest

type MsgUpdateStatusRequest struct {
	// Field 1: Sender's address.
	From string `protobuf:"bytes,1,opt,name=from,proto3" json:"from,omitempty"`
	// Field 2: Identifier of the subscription plan.
	ID uint64 `protobuf:"varint,2,opt,name=id,proto3" json:"id,omitempty"`
	// Field 3: New status for the subscription plan.
	Status types1.Status `protobuf:"varint,3,opt,name=status,proto3,enum=sentinel.types.v1.Status" json:"status,omitempty"`
}

MsgUpdateStatusRequest defines the SDK message for modifying the status of a subscription plan.

func NewMsgUpdateStatusRequest

func NewMsgUpdateStatusRequest(from hubtypes.ProvAddress, id uint64, status hubtypes.Status) *MsgUpdateStatusRequest

NewMsgUpdateStatusRequest creates a new MsgUpdateStatusRequest instance with the given parameters.

func (*MsgUpdateStatusRequest) Descriptor

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

func (*MsgUpdateStatusRequest) GetSigners

func (m *MsgUpdateStatusRequest) GetSigners() []sdk.AccAddress

GetSigners returns an array containing the signer's account address extracted from the 'From' field of the MsgUpdateStatusRequest.

func (*MsgUpdateStatusRequest) Marshal

func (m *MsgUpdateStatusRequest) Marshal() (dAtA []byte, err error)

func (*MsgUpdateStatusRequest) MarshalTo

func (m *MsgUpdateStatusRequest) MarshalTo(dAtA []byte) (int, error)

func (*MsgUpdateStatusRequest) MarshalToSizedBuffer

func (m *MsgUpdateStatusRequest) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*MsgUpdateStatusRequest) ProtoMessage

func (*MsgUpdateStatusRequest) ProtoMessage()

func (*MsgUpdateStatusRequest) Reset

func (m *MsgUpdateStatusRequest) Reset()

func (*MsgUpdateStatusRequest) Size

func (m *MsgUpdateStatusRequest) Size() (n int)

func (*MsgUpdateStatusRequest) String

func (m *MsgUpdateStatusRequest) String() string

func (*MsgUpdateStatusRequest) Unmarshal

func (m *MsgUpdateStatusRequest) Unmarshal(dAtA []byte) error

func (*MsgUpdateStatusRequest) ValidateBasic

func (m *MsgUpdateStatusRequest) ValidateBasic() error

ValidateBasic performs basic validation checks on the MsgUpdateStatusRequest fields. It checks if the 'From' field is not empty and represents a valid provider address, if the 'ID' field is not zero, and if the 'Status' field is one of the allowed values [active, inactive].

func (*MsgUpdateStatusRequest) XXX_DiscardUnknown

func (m *MsgUpdateStatusRequest) XXX_DiscardUnknown()

func (*MsgUpdateStatusRequest) XXX_Marshal

func (m *MsgUpdateStatusRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*MsgUpdateStatusRequest) XXX_Merge

func (m *MsgUpdateStatusRequest) XXX_Merge(src proto.Message)

func (*MsgUpdateStatusRequest) XXX_Size

func (m *MsgUpdateStatusRequest) XXX_Size() int

func (*MsgUpdateStatusRequest) XXX_Unmarshal

func (m *MsgUpdateStatusRequest) XXX_Unmarshal(b []byte) error

type MsgUpdateStatusResponse

type MsgUpdateStatusResponse struct {
}

MsgUpdateStatusResponse defines the response of message MsgUpdateStatusRequest.

func (*MsgUpdateStatusResponse) Descriptor

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

func (*MsgUpdateStatusResponse) Marshal

func (m *MsgUpdateStatusResponse) Marshal() (dAtA []byte, err error)

func (*MsgUpdateStatusResponse) MarshalTo

func (m *MsgUpdateStatusResponse) MarshalTo(dAtA []byte) (int, error)

func (*MsgUpdateStatusResponse) MarshalToSizedBuffer

func (m *MsgUpdateStatusResponse) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*MsgUpdateStatusResponse) ProtoMessage

func (*MsgUpdateStatusResponse) ProtoMessage()

func (*MsgUpdateStatusResponse) Reset

func (m *MsgUpdateStatusResponse) Reset()

func (*MsgUpdateStatusResponse) Size

func (m *MsgUpdateStatusResponse) Size() (n int)

func (*MsgUpdateStatusResponse) String

func (m *MsgUpdateStatusResponse) String() string

func (*MsgUpdateStatusResponse) Unmarshal

func (m *MsgUpdateStatusResponse) Unmarshal(dAtA []byte) error

func (*MsgUpdateStatusResponse) XXX_DiscardUnknown

func (m *MsgUpdateStatusResponse) XXX_DiscardUnknown()

func (*MsgUpdateStatusResponse) XXX_Marshal

func (m *MsgUpdateStatusResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*MsgUpdateStatusResponse) XXX_Merge

func (m *MsgUpdateStatusResponse) XXX_Merge(src proto.Message)

func (*MsgUpdateStatusResponse) XXX_Size

func (m *MsgUpdateStatusResponse) XXX_Size() int

func (*MsgUpdateStatusResponse) XXX_Unmarshal

func (m *MsgUpdateStatusResponse) XXX_Unmarshal(b []byte) error

type Plan

type Plan struct {
	// Field 1: Identifier of the subscription plan.
	ID uint64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
	// Field 2: Provider's address associated with the plan.
	ProviderAddress string `protobuf:"bytes,2,opt,name=provider_address,json=providerAddress,proto3" json:"provider_address,omitempty"`
	// Field 3: Duration of the subscription plan.
	Duration time.Duration `protobuf:"bytes,3,opt,name=duration,proto3,stdduration" json:"duration"`
	// Field 4: Amount of gigabytes in the subscription plan.
	Gigabytes int64 `protobuf:"varint,4,opt,name=gigabytes,proto3" json:"gigabytes,omitempty"`
	// Field 5: Prices associated with the subscription plan.
	Prices github_com_cosmos_cosmos_sdk_types.Coins `protobuf:"bytes,5,rep,name=prices,proto3,castrepeated=github.com/cosmos/cosmos-sdk/types.Coins" json:"prices"`
	// Field 6: Status of the subscription plan.
	Status types1.Status `protobuf:"varint,6,opt,name=status,proto3,enum=sentinel.types.v1.Status" json:"status,omitempty"`
	// Field 7: Timestamp when the status was last updated.
	StatusAt time.Time `protobuf:"bytes,7,opt,name=status_at,json=statusAt,proto3,stdtime" json:"status_at"`
}

Plan represents a subscription plan.

func (*Plan) Descriptor

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

func (*Plan) GetProviderAddress

func (m *Plan) GetProviderAddress() hubtypes.ProvAddress

func (*Plan) Marshal

func (m *Plan) Marshal() (dAtA []byte, err error)

func (*Plan) MarshalTo

func (m *Plan) MarshalTo(dAtA []byte) (int, error)

func (*Plan) MarshalToSizedBuffer

func (m *Plan) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*Plan) Price

func (m *Plan) Price(denom string) (sdk.Coin, bool)

func (*Plan) ProtoMessage

func (*Plan) ProtoMessage()

func (*Plan) Reset

func (m *Plan) Reset()

func (*Plan) Size

func (m *Plan) Size() (n int)

func (*Plan) String

func (m *Plan) String() string

func (*Plan) Unmarshal

func (m *Plan) Unmarshal(dAtA []byte) error

func (*Plan) Validate

func (m *Plan) Validate() error

func (*Plan) XXX_DiscardUnknown

func (m *Plan) XXX_DiscardUnknown()

func (*Plan) XXX_Marshal

func (m *Plan) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*Plan) XXX_Merge

func (m *Plan) XXX_Merge(src proto.Message)

func (*Plan) XXX_Size

func (m *Plan) XXX_Size() int

func (*Plan) XXX_Unmarshal

func (m *Plan) XXX_Unmarshal(b []byte) error

type Plans

type Plans []Plan

type QueryPlanRequest

type QueryPlanRequest struct {
	// Field 1: Identifier of the subscription plan.
	Id uint64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
}

QueryPlanRequest defines the request for querying a specific subscription plan.

func NewQueryPlanRequest

func NewQueryPlanRequest(id uint64) *QueryPlanRequest

func (*QueryPlanRequest) Descriptor

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

func (*QueryPlanRequest) Marshal

func (m *QueryPlanRequest) Marshal() (dAtA []byte, err error)

func (*QueryPlanRequest) MarshalTo

func (m *QueryPlanRequest) MarshalTo(dAtA []byte) (int, error)

func (*QueryPlanRequest) MarshalToSizedBuffer

func (m *QueryPlanRequest) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*QueryPlanRequest) ProtoMessage

func (*QueryPlanRequest) ProtoMessage()

func (*QueryPlanRequest) Reset

func (m *QueryPlanRequest) Reset()

func (*QueryPlanRequest) Size

func (m *QueryPlanRequest) Size() (n int)

func (*QueryPlanRequest) String

func (m *QueryPlanRequest) String() string

func (*QueryPlanRequest) Unmarshal

func (m *QueryPlanRequest) Unmarshal(dAtA []byte) error

func (*QueryPlanRequest) XXX_DiscardUnknown

func (m *QueryPlanRequest) XXX_DiscardUnknown()

func (*QueryPlanRequest) XXX_Marshal

func (m *QueryPlanRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*QueryPlanRequest) XXX_Merge

func (m *QueryPlanRequest) XXX_Merge(src proto.Message)

func (*QueryPlanRequest) XXX_Size

func (m *QueryPlanRequest) XXX_Size() int

func (*QueryPlanRequest) XXX_Unmarshal

func (m *QueryPlanRequest) XXX_Unmarshal(b []byte) error

type QueryPlanResponse

type QueryPlanResponse struct {
	// Field 1: Subscription plan information.
	Plan Plan `protobuf:"bytes,1,opt,name=plan,proto3" json:"plan"`
}

QueryPlanResponse defines the response for querying a specific subscription plan.

func (*QueryPlanResponse) Descriptor

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

func (*QueryPlanResponse) Marshal

func (m *QueryPlanResponse) Marshal() (dAtA []byte, err error)

func (*QueryPlanResponse) MarshalTo

func (m *QueryPlanResponse) MarshalTo(dAtA []byte) (int, error)

func (*QueryPlanResponse) MarshalToSizedBuffer

func (m *QueryPlanResponse) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*QueryPlanResponse) ProtoMessage

func (*QueryPlanResponse) ProtoMessage()

func (*QueryPlanResponse) Reset

func (m *QueryPlanResponse) Reset()

func (*QueryPlanResponse) Size

func (m *QueryPlanResponse) Size() (n int)

func (*QueryPlanResponse) String

func (m *QueryPlanResponse) String() string

func (*QueryPlanResponse) Unmarshal

func (m *QueryPlanResponse) Unmarshal(dAtA []byte) error

func (*QueryPlanResponse) XXX_DiscardUnknown

func (m *QueryPlanResponse) XXX_DiscardUnknown()

func (*QueryPlanResponse) XXX_Marshal

func (m *QueryPlanResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*QueryPlanResponse) XXX_Merge

func (m *QueryPlanResponse) XXX_Merge(src proto.Message)

func (*QueryPlanResponse) XXX_Size

func (m *QueryPlanResponse) XXX_Size() int

func (*QueryPlanResponse) XXX_Unmarshal

func (m *QueryPlanResponse) XXX_Unmarshal(b []byte) error

type QueryPlansForProviderRequest

type QueryPlansForProviderRequest struct {
	// Field 1: Provider's address for filtering subscription plans.
	Address string `protobuf:"bytes,1,opt,name=address,proto3" json:"address,omitempty"`
	// Field 2: Status filter for subscription plans.
	Status types.Status `protobuf:"varint,2,opt,name=status,proto3,enum=sentinel.types.v1.Status" json:"status,omitempty"`
	// Field 3: Pagination information.
	Pagination *query.PageRequest `protobuf:"bytes,3,opt,name=pagination,proto3" json:"pagination,omitempty"`
}

QueryPlansForProviderRequest defines the request for querying subscription plans associated with a provider.

func NewQueryPlansForProviderRequest

func NewQueryPlansForProviderRequest(addr hubtypes.ProvAddress, status hubtypes.Status, pagination *query.PageRequest) *QueryPlansForProviderRequest

func (*QueryPlansForProviderRequest) Descriptor

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

func (*QueryPlansForProviderRequest) Marshal

func (m *QueryPlansForProviderRequest) Marshal() (dAtA []byte, err error)

func (*QueryPlansForProviderRequest) MarshalTo

func (m *QueryPlansForProviderRequest) MarshalTo(dAtA []byte) (int, error)

func (*QueryPlansForProviderRequest) MarshalToSizedBuffer

func (m *QueryPlansForProviderRequest) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*QueryPlansForProviderRequest) ProtoMessage

func (*QueryPlansForProviderRequest) ProtoMessage()

func (*QueryPlansForProviderRequest) Reset

func (m *QueryPlansForProviderRequest) Reset()

func (*QueryPlansForProviderRequest) Size

func (m *QueryPlansForProviderRequest) Size() (n int)

func (*QueryPlansForProviderRequest) String

func (*QueryPlansForProviderRequest) Unmarshal

func (m *QueryPlansForProviderRequest) Unmarshal(dAtA []byte) error

func (*QueryPlansForProviderRequest) XXX_DiscardUnknown

func (m *QueryPlansForProviderRequest) XXX_DiscardUnknown()

func (*QueryPlansForProviderRequest) XXX_Marshal

func (m *QueryPlansForProviderRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*QueryPlansForProviderRequest) XXX_Merge

func (m *QueryPlansForProviderRequest) XXX_Merge(src proto.Message)

func (*QueryPlansForProviderRequest) XXX_Size

func (m *QueryPlansForProviderRequest) XXX_Size() int

func (*QueryPlansForProviderRequest) XXX_Unmarshal

func (m *QueryPlansForProviderRequest) XXX_Unmarshal(b []byte) error

type QueryPlansForProviderResponse

type QueryPlansForProviderResponse struct {
	// Field 1: List of subscription plans.
	Plans []Plan `protobuf:"bytes,1,rep,name=plans,proto3" json:"plans"`
	// Field 2: Pagination information.
	Pagination *query.PageResponse `protobuf:"bytes,2,opt,name=pagination,proto3" json:"pagination,omitempty"`
}

QueryPlansForProviderResponse defines the response for querying subscription plans associated with a provider.

func (*QueryPlansForProviderResponse) Descriptor

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

func (*QueryPlansForProviderResponse) Marshal

func (m *QueryPlansForProviderResponse) Marshal() (dAtA []byte, err error)

func (*QueryPlansForProviderResponse) MarshalTo

func (m *QueryPlansForProviderResponse) MarshalTo(dAtA []byte) (int, error)

func (*QueryPlansForProviderResponse) MarshalToSizedBuffer

func (m *QueryPlansForProviderResponse) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*QueryPlansForProviderResponse) ProtoMessage

func (*QueryPlansForProviderResponse) ProtoMessage()

func (*QueryPlansForProviderResponse) Reset

func (m *QueryPlansForProviderResponse) Reset()

func (*QueryPlansForProviderResponse) Size

func (m *QueryPlansForProviderResponse) Size() (n int)

func (*QueryPlansForProviderResponse) String

func (*QueryPlansForProviderResponse) Unmarshal

func (m *QueryPlansForProviderResponse) Unmarshal(dAtA []byte) error

func (*QueryPlansForProviderResponse) XXX_DiscardUnknown

func (m *QueryPlansForProviderResponse) XXX_DiscardUnknown()

func (*QueryPlansForProviderResponse) XXX_Marshal

func (m *QueryPlansForProviderResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*QueryPlansForProviderResponse) XXX_Merge

func (m *QueryPlansForProviderResponse) XXX_Merge(src proto.Message)

func (*QueryPlansForProviderResponse) XXX_Size

func (m *QueryPlansForProviderResponse) XXX_Size() int

func (*QueryPlansForProviderResponse) XXX_Unmarshal

func (m *QueryPlansForProviderResponse) XXX_Unmarshal(b []byte) error

type QueryPlansRequest

type QueryPlansRequest struct {
	// Field 1: Status filter for subscription plans.
	Status types.Status `protobuf:"varint,1,opt,name=status,proto3,enum=sentinel.types.v1.Status" json:"status,omitempty"`
	// Field 2: Pagination information.
	Pagination *query.PageRequest `protobuf:"bytes,2,opt,name=pagination,proto3" json:"pagination,omitempty"`
}

QueryPlansRequest defines the request for querying subscription plans.

func NewQueryPlansRequest

func NewQueryPlansRequest(status hubtypes.Status, pagination *query.PageRequest) *QueryPlansRequest

func (*QueryPlansRequest) Descriptor

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

func (*QueryPlansRequest) Marshal

func (m *QueryPlansRequest) Marshal() (dAtA []byte, err error)

func (*QueryPlansRequest) MarshalTo

func (m *QueryPlansRequest) MarshalTo(dAtA []byte) (int, error)

func (*QueryPlansRequest) MarshalToSizedBuffer

func (m *QueryPlansRequest) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*QueryPlansRequest) ProtoMessage

func (*QueryPlansRequest) ProtoMessage()

func (*QueryPlansRequest) Reset

func (m *QueryPlansRequest) Reset()

func (*QueryPlansRequest) Size

func (m *QueryPlansRequest) Size() (n int)

func (*QueryPlansRequest) String

func (m *QueryPlansRequest) String() string

func (*QueryPlansRequest) Unmarshal

func (m *QueryPlansRequest) Unmarshal(dAtA []byte) error

func (*QueryPlansRequest) XXX_DiscardUnknown

func (m *QueryPlansRequest) XXX_DiscardUnknown()

func (*QueryPlansRequest) XXX_Marshal

func (m *QueryPlansRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*QueryPlansRequest) XXX_Merge

func (m *QueryPlansRequest) XXX_Merge(src proto.Message)

func (*QueryPlansRequest) XXX_Size

func (m *QueryPlansRequest) XXX_Size() int

func (*QueryPlansRequest) XXX_Unmarshal

func (m *QueryPlansRequest) XXX_Unmarshal(b []byte) error

type QueryPlansResponse

type QueryPlansResponse struct {
	// Field 1: List of subscription plans.
	Plans []Plan `protobuf:"bytes,1,rep,name=plans,proto3" json:"plans"`
	// Field 2: Pagination information.
	Pagination *query.PageResponse `protobuf:"bytes,2,opt,name=pagination,proto3" json:"pagination,omitempty"`
}

QueryPlansResponse defines the response for querying subscription plans.

func (*QueryPlansResponse) Descriptor

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

func (*QueryPlansResponse) Marshal

func (m *QueryPlansResponse) Marshal() (dAtA []byte, err error)

func (*QueryPlansResponse) MarshalTo

func (m *QueryPlansResponse) MarshalTo(dAtA []byte) (int, error)

func (*QueryPlansResponse) MarshalToSizedBuffer

func (m *QueryPlansResponse) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*QueryPlansResponse) ProtoMessage

func (*QueryPlansResponse) ProtoMessage()

func (*QueryPlansResponse) Reset

func (m *QueryPlansResponse) Reset()

func (*QueryPlansResponse) Size

func (m *QueryPlansResponse) Size() (n int)

func (*QueryPlansResponse) String

func (m *QueryPlansResponse) String() string

func (*QueryPlansResponse) Unmarshal

func (m *QueryPlansResponse) Unmarshal(dAtA []byte) error

func (*QueryPlansResponse) XXX_DiscardUnknown

func (m *QueryPlansResponse) XXX_DiscardUnknown()

func (*QueryPlansResponse) XXX_Marshal

func (m *QueryPlansResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*QueryPlansResponse) XXX_Merge

func (m *QueryPlansResponse) XXX_Merge(src proto.Message)

func (*QueryPlansResponse) XXX_Size

func (m *QueryPlansResponse) XXX_Size() int

func (*QueryPlansResponse) XXX_Unmarshal

func (m *QueryPlansResponse) XXX_Unmarshal(b []byte) error

type QueryServiceClient

type QueryServiceClient interface {
	// RPC method for querying all subscription plans.
	QueryPlans(ctx context.Context, in *QueryPlansRequest, opts ...grpc.CallOption) (*QueryPlansResponse, error)
	// RPC method for querying subscription plans associated with a provider.
	QueryPlansForProvider(ctx context.Context, in *QueryPlansForProviderRequest, opts ...grpc.CallOption) (*QueryPlansForProviderResponse, error)
	// RPC method for querying a specific subscription plan.
	QueryPlan(ctx context.Context, in *QueryPlanRequest, opts ...grpc.CallOption) (*QueryPlanResponse, error)
}

QueryServiceClient is the client API for QueryService service.

For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.

func NewQueryServiceClient

func NewQueryServiceClient(cc grpc1.ClientConn) QueryServiceClient

type QueryServiceServer

type QueryServiceServer interface {
	// RPC method for querying all subscription plans.
	QueryPlans(context.Context, *QueryPlansRequest) (*QueryPlansResponse, error)
	// RPC method for querying subscription plans associated with a provider.
	QueryPlansForProvider(context.Context, *QueryPlansForProviderRequest) (*QueryPlansForProviderResponse, error)
	// RPC method for querying a specific subscription plan.
	QueryPlan(context.Context, *QueryPlanRequest) (*QueryPlanResponse, error)
}

QueryServiceServer is the server API for QueryService service.

type UnimplementedMsgServiceServer

type UnimplementedMsgServiceServer struct {
}

UnimplementedMsgServiceServer can be embedded to have forward compatible implementations.

func (*UnimplementedMsgServiceServer) MsgCreate

func (*UnimplementedMsgServiceServer) MsgLinkNode

func (*UnimplementedMsgServiceServer) MsgSubscribe

func (*UnimplementedMsgServiceServer) MsgUnlinkNode

func (*UnimplementedMsgServiceServer) MsgUpdateStatus

type UnimplementedQueryServiceServer

type UnimplementedQueryServiceServer struct {
}

UnimplementedQueryServiceServer can be embedded to have forward compatible implementations.

func (*UnimplementedQueryServiceServer) QueryPlan

func (*UnimplementedQueryServiceServer) QueryPlans

func (*UnimplementedQueryServiceServer) QueryPlansForProvider

Jump to

Keyboard shortcuts

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