Documentation ¶
Overview ¶
Package genserve provides a simple gRPC server that allows querying the consensus and execution genesis files.
Index ¶
- Variables
- func Register(s grpc1.Server, execution, consensus []byte)
- func RegisterQueryServer(s grpc1.Server, srv QueryServer)
- type GenesisRequest
- func (*GenesisRequest) Descriptor() ([]byte, []int)
- func (m *GenesisRequest) Marshal() (dAtA []byte, err error)
- func (m *GenesisRequest) MarshalTo(dAtA []byte) (int, error)
- func (m *GenesisRequest) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*GenesisRequest) ProtoMessage()
- func (m *GenesisRequest) Reset()
- func (m *GenesisRequest) Size() (n int)
- func (m *GenesisRequest) String() string
- func (m *GenesisRequest) Unmarshal(dAtA []byte) error
- func (m *GenesisRequest) XXX_DiscardUnknown()
- func (m *GenesisRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *GenesisRequest) XXX_Merge(src proto.Message)
- func (m *GenesisRequest) XXX_Size() int
- func (m *GenesisRequest) XXX_Unmarshal(b []byte) error
- type GenesisResponse
- func (*GenesisResponse) Descriptor() ([]byte, []int)
- func (m *GenesisResponse) GetConsensusGenesisJson() []byte
- func (m *GenesisResponse) GetExecutionGenesisJson() []byte
- func (m *GenesisResponse) Marshal() (dAtA []byte, err error)
- func (m *GenesisResponse) MarshalTo(dAtA []byte) (int, error)
- func (m *GenesisResponse) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*GenesisResponse) ProtoMessage()
- func (m *GenesisResponse) Reset()
- func (m *GenesisResponse) Size() (n int)
- func (m *GenesisResponse) String() string
- func (m *GenesisResponse) Unmarshal(dAtA []byte) error
- func (m *GenesisResponse) XXX_DiscardUnknown()
- func (m *GenesisResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *GenesisResponse) XXX_Merge(src proto.Message)
- func (m *GenesisResponse) XXX_Size() int
- func (m *GenesisResponse) XXX_Unmarshal(b []byte) error
- type QueryClient
- type QueryServer
- type UnimplementedQueryServer
Constants ¶
This section is empty.
Variables ¶
View Source
var ( ErrInvalidLengthQuery = fmt.Errorf("proto: negative length found during unmarshaling") ErrIntOverflowQuery = fmt.Errorf("proto: integer overflow") ErrUnexpectedEndOfGroupQuery = fmt.Errorf("proto: unexpected end of group") )
View Source
var Query_serviceDesc = _Query_serviceDesc
Functions ¶
func Register ¶
Register constructs a new genesis query server instance and registers it with the provided gRPC server.
func RegisterQueryServer ¶
func RegisterQueryServer(s grpc1.Server, srv QueryServer)
Types ¶
type GenesisRequest ¶
type GenesisRequest struct { }
func (*GenesisRequest) Descriptor ¶
func (*GenesisRequest) Descriptor() ([]byte, []int)
func (*GenesisRequest) Marshal ¶
func (m *GenesisRequest) Marshal() (dAtA []byte, err error)
func (*GenesisRequest) MarshalToSizedBuffer ¶
func (m *GenesisRequest) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*GenesisRequest) ProtoMessage ¶
func (*GenesisRequest) ProtoMessage()
func (*GenesisRequest) Reset ¶
func (m *GenesisRequest) Reset()
func (*GenesisRequest) Size ¶
func (m *GenesisRequest) Size() (n int)
func (*GenesisRequest) String ¶
func (m *GenesisRequest) String() string
func (*GenesisRequest) Unmarshal ¶
func (m *GenesisRequest) Unmarshal(dAtA []byte) error
func (*GenesisRequest) XXX_DiscardUnknown ¶
func (m *GenesisRequest) XXX_DiscardUnknown()
func (*GenesisRequest) XXX_Marshal ¶
func (m *GenesisRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*GenesisRequest) XXX_Merge ¶
func (m *GenesisRequest) XXX_Merge(src proto.Message)
func (*GenesisRequest) XXX_Size ¶
func (m *GenesisRequest) XXX_Size() int
func (*GenesisRequest) XXX_Unmarshal ¶
func (m *GenesisRequest) XXX_Unmarshal(b []byte) error
type GenesisResponse ¶
type GenesisResponse struct { ConsensusGenesisJson []byte `protobuf:"bytes,1,opt,name=consensus_genesis_json,json=consensusGenesisJson,proto3" json:"consensus_genesis_json,omitempty"` ExecutionGenesisJson []byte `protobuf:"bytes,2,opt,name=execution_genesis_json,json=executionGenesisJson,proto3" json:"execution_genesis_json,omitempty"` }
func (*GenesisResponse) Descriptor ¶
func (*GenesisResponse) Descriptor() ([]byte, []int)
func (*GenesisResponse) GetConsensusGenesisJson ¶
func (m *GenesisResponse) GetConsensusGenesisJson() []byte
func (*GenesisResponse) GetExecutionGenesisJson ¶
func (m *GenesisResponse) GetExecutionGenesisJson() []byte
func (*GenesisResponse) Marshal ¶
func (m *GenesisResponse) Marshal() (dAtA []byte, err error)
func (*GenesisResponse) MarshalToSizedBuffer ¶
func (m *GenesisResponse) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*GenesisResponse) ProtoMessage ¶
func (*GenesisResponse) ProtoMessage()
func (*GenesisResponse) Reset ¶
func (m *GenesisResponse) Reset()
func (*GenesisResponse) Size ¶
func (m *GenesisResponse) Size() (n int)
func (*GenesisResponse) String ¶
func (m *GenesisResponse) String() string
func (*GenesisResponse) Unmarshal ¶
func (m *GenesisResponse) Unmarshal(dAtA []byte) error
func (*GenesisResponse) XXX_DiscardUnknown ¶
func (m *GenesisResponse) XXX_DiscardUnknown()
func (*GenesisResponse) XXX_Marshal ¶
func (m *GenesisResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*GenesisResponse) XXX_Merge ¶
func (m *GenesisResponse) XXX_Merge(src proto.Message)
func (*GenesisResponse) XXX_Size ¶
func (m *GenesisResponse) XXX_Size() int
func (*GenesisResponse) XXX_Unmarshal ¶
func (m *GenesisResponse) XXX_Unmarshal(b []byte) error
type QueryClient ¶
type QueryClient interface {
Genesis(ctx context.Context, in *GenesisRequest, opts ...grpc.CallOption) (*GenesisResponse, error)
}
QueryClient is the client API for Query service.
For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.
func NewQueryClient ¶
func NewQueryClient(cc grpc1.ClientConn) QueryClient
type QueryServer ¶
type QueryServer interface {
Genesis(context.Context, *GenesisRequest) (*GenesisResponse, error)
}
QueryServer is the server API for Query service.
type UnimplementedQueryServer ¶
type UnimplementedQueryServer struct { }
UnimplementedQueryServer can be embedded to have forward compatible implementations.
func (*UnimplementedQueryServer) Genesis ¶
func (*UnimplementedQueryServer) Genesis(ctx context.Context, req *GenesisRequest) (*GenesisResponse, error)
Click to show internal directories.
Click to hide internal directories.