Documentation ¶
Index ¶
- Variables
- func RegisterIndexerRpcServiceServer(s grpc.ServiceRegistrar, srv IndexerRpcServiceServer)
- type IndexerRpcServiceClient
- type IndexerRpcServiceServer
- type LatestBlock
- type LatestBlockRep
- func (*LatestBlockRep) Descriptor() ([]byte, []int)deprecated
- func (x *LatestBlockRep) GetBlockNumber() uint64
- func (x *LatestBlockRep) GetCode() ReturnCode
- func (x *LatestBlockRep) GetMsg() string
- func (*LatestBlockRep) ProtoMessage()
- func (x *LatestBlockRep) ProtoReflect() protoreflect.Message
- func (x *LatestBlockRep) Reset()
- func (x *LatestBlockRep) String() string
- type ReturnCode
- type UnimplementedIndexerRpcServiceServer
- type UnsafeIndexerRpcServiceServer
Constants ¶
This section is empty.
Variables ¶
var ( ReturnCode_name = map[int32]string{ 0: "SUCCESS", 1: "ERROR", } ReturnCode_value = map[string]int32{ "SUCCESS": 0, "ERROR": 1, } )
Enum value maps for ReturnCode.
var File_indexer_proto protoreflect.FileDescriptor
var IndexerRpcService_ServiceDesc = grpc.ServiceDesc{ ServiceName: "indexer.protobuf.IndexerRpcService", HandlerType: (*IndexerRpcServiceServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "GetLatestBlock", Handler: _IndexerRpcService_GetLatestBlock_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "indexer.proto", }
IndexerRpcService_ServiceDesc is the grpc.ServiceDesc for IndexerRpcService service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)
Functions ¶
func RegisterIndexerRpcServiceServer ¶
func RegisterIndexerRpcServiceServer(s grpc.ServiceRegistrar, srv IndexerRpcServiceServer)
Types ¶
type IndexerRpcServiceClient ¶
type IndexerRpcServiceClient interface {
GetLatestBlock(ctx context.Context, in *LatestBlock, opts ...grpc.CallOption) (*LatestBlockRep, error)
}
IndexerRpcServiceClient is the client API for IndexerRpcService 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 NewIndexerRpcServiceClient ¶
func NewIndexerRpcServiceClient(cc grpc.ClientConnInterface) IndexerRpcServiceClient
type IndexerRpcServiceServer ¶
type IndexerRpcServiceServer interface {
GetLatestBlock(context.Context, *LatestBlock) (*LatestBlockRep, error)
}
IndexerRpcServiceServer is the server API for IndexerRpcService service. All implementations must embed UnimplementedIndexerRpcServiceServer for forward compatibility
type LatestBlock ¶
type LatestBlock struct { ConsumerToken string `protobuf:"bytes,1,opt,name=consumer_token,json=consumerToken,proto3" json:"consumer_token,omitempty"` // contains filtered or unexported fields }
func (*LatestBlock) Descriptor
deprecated
func (*LatestBlock) Descriptor() ([]byte, []int)
Deprecated: Use LatestBlock.ProtoReflect.Descriptor instead.
func (*LatestBlock) GetConsumerToken ¶
func (x *LatestBlock) GetConsumerToken() string
func (*LatestBlock) ProtoMessage ¶
func (*LatestBlock) ProtoMessage()
func (*LatestBlock) ProtoReflect ¶
func (x *LatestBlock) ProtoReflect() protoreflect.Message
func (*LatestBlock) Reset ¶
func (x *LatestBlock) Reset()
func (*LatestBlock) String ¶
func (x *LatestBlock) String() string
type LatestBlockRep ¶
type LatestBlockRep struct { Code ReturnCode `protobuf:"varint,1,opt,name=code,proto3,enum=indexer.protobuf.ReturnCode" json:"code,omitempty"` Msg string `protobuf:"bytes,2,opt,name=msg,proto3" json:"msg,omitempty"` BlockNumber uint64 `protobuf:"varint,3,opt,name=block_number,json=blockNumber,proto3" json:"block_number,omitempty"` // contains filtered or unexported fields }
func (*LatestBlockRep) Descriptor
deprecated
func (*LatestBlockRep) Descriptor() ([]byte, []int)
Deprecated: Use LatestBlockRep.ProtoReflect.Descriptor instead.
func (*LatestBlockRep) GetBlockNumber ¶
func (x *LatestBlockRep) GetBlockNumber() uint64
func (*LatestBlockRep) GetCode ¶
func (x *LatestBlockRep) GetCode() ReturnCode
func (*LatestBlockRep) GetMsg ¶
func (x *LatestBlockRep) GetMsg() string
func (*LatestBlockRep) ProtoMessage ¶
func (*LatestBlockRep) ProtoMessage()
func (*LatestBlockRep) ProtoReflect ¶
func (x *LatestBlockRep) ProtoReflect() protoreflect.Message
func (*LatestBlockRep) Reset ¶
func (x *LatestBlockRep) Reset()
func (*LatestBlockRep) String ¶
func (x *LatestBlockRep) String() string
type ReturnCode ¶
type ReturnCode int32
const ( ReturnCode_SUCCESS ReturnCode = 0 ReturnCode_ERROR ReturnCode = 1 )
func (ReturnCode) Descriptor ¶
func (ReturnCode) Descriptor() protoreflect.EnumDescriptor
func (ReturnCode) Enum ¶
func (x ReturnCode) Enum() *ReturnCode
func (ReturnCode) EnumDescriptor
deprecated
func (ReturnCode) EnumDescriptor() ([]byte, []int)
Deprecated: Use ReturnCode.Descriptor instead.
func (ReturnCode) Number ¶
func (x ReturnCode) Number() protoreflect.EnumNumber
func (ReturnCode) String ¶
func (x ReturnCode) String() string
func (ReturnCode) Type ¶
func (ReturnCode) Type() protoreflect.EnumType
type UnimplementedIndexerRpcServiceServer ¶
type UnimplementedIndexerRpcServiceServer struct { }
UnimplementedIndexerRpcServiceServer must be embedded to have forward compatible implementations.
func (UnimplementedIndexerRpcServiceServer) GetLatestBlock ¶
func (UnimplementedIndexerRpcServiceServer) GetLatestBlock(context.Context, *LatestBlock) (*LatestBlockRep, error)
type UnsafeIndexerRpcServiceServer ¶
type UnsafeIndexerRpcServiceServer interface {
// contains filtered or unexported methods
}
UnsafeIndexerRpcServiceServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to IndexerRpcServiceServer will result in compilation errors.