Documentation ¶
Index ¶
- Constants
- Variables
- func RegisterBlockchainInterfaceServer(s grpc.ServiceRegistrar, srv BlockchainInterfaceServer)
- type BlockchainInterfaceClient
- type BlockchainInterfaceServer
- type Empty
- type EnrollAccountResponse
- func (*EnrollAccountResponse) Descriptor() ([]byte, []int)deprecated
- func (x *EnrollAccountResponse) GetCode() int32
- func (*EnrollAccountResponse) ProtoMessage()
- func (x *EnrollAccountResponse) ProtoReflect() protoreflect.Message
- func (x *EnrollAccountResponse) Reset()
- func (x *EnrollAccountResponse) String() string
- type LeaveRequestResponse
- func (*LeaveRequestResponse) Descriptor() ([]byte, []int)deprecated
- func (x *LeaveRequestResponse) GetCode() int32
- func (*LeaveRequestResponse) ProtoMessage()
- func (x *LeaveRequestResponse) ProtoReflect() protoreflect.Message
- func (x *LeaveRequestResponse) Reset()
- func (x *LeaveRequestResponse) String() string
- type NodeData
- func (*NodeData) Descriptor() ([]byte, []int)deprecated
- func (x *NodeData) GetAddress() string
- func (x *NodeData) GetPubkey() []byte
- func (x *NodeData) GetSignature() []byte
- func (*NodeData) ProtoMessage()
- func (x *NodeData) ProtoReflect() protoreflect.Message
- func (x *NodeData) Reset()
- func (x *NodeData) String() string
- type SetupCommitteeRequest
- func (*SetupCommitteeRequest) Descriptor() ([]byte, []int)deprecated
- func (x *SetupCommitteeRequest) GetNodeip() string
- func (x *SetupCommitteeRequest) GetRound() int32
- func (x *SetupCommitteeRequest) GetVrfResult() *VrfValue
- func (x *SetupCommitteeRequest) GetVrfpubkey() []byte
- func (*SetupCommitteeRequest) ProtoMessage()
- func (x *SetupCommitteeRequest) ProtoReflect() protoreflect.Message
- func (x *SetupCommitteeRequest) Reset()
- func (x *SetupCommitteeRequest) String() string
- type SetupCommitteeResponse
- func (*SetupCommitteeResponse) Descriptor() ([]byte, []int)deprecated
- func (x *SetupCommitteeResponse) GetCode() int32
- func (*SetupCommitteeResponse) ProtoMessage()
- func (x *SetupCommitteeResponse) ProtoReflect() protoreflect.Message
- func (x *SetupCommitteeResponse) Reset()
- func (x *SetupCommitteeResponse) String() string
- type UnimplementedBlockchainInterfaceServer
- func (UnimplementedBlockchainInterfaceServer) EnrollNodeInfo(context.Context, *NodeData) (*EnrollAccountResponse, error)
- func (UnimplementedBlockchainInterfaceServer) LeaveRequest(context.Context, *NodeData) (*Empty, error)
- func (UnimplementedBlockchainInterfaceServer) SetupCommittee(context.Context, *SetupCommitteeRequest) (*SetupCommitteeResponse, error)
- type UnsafeBlockchainInterfaceServer
- type VrfValue
- func (*VrfValue) Descriptor() ([]byte, []int)deprecated
- func (x *VrfValue) GetProof() []byte
- func (x *VrfValue) GetPubkey() []byte
- func (x *VrfValue) GetVal() string
- func (*VrfValue) ProtoMessage()
- func (x *VrfValue) ProtoReflect() protoreflect.Message
- func (x *VrfValue) Reset()
- func (x *VrfValue) String() string
Constants ¶
const ( BlockchainInterface_EnrollNodeInfo_FullMethodName = "/commu_module.BlockchainInterface/EnrollNodeInfo" BlockchainInterface_SetupCommittee_FullMethodName = "/commu_module.BlockchainInterface/SetupCommittee" BlockchainInterface_LeaveRequest_FullMethodName = "/commu_module.BlockchainInterface/LeaveRequest" )
Variables ¶
var BlockchainInterface_ServiceDesc = grpc.ServiceDesc{ ServiceName: "commu_module.BlockchainInterface", HandlerType: (*BlockchainInterfaceServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "EnrollNodeInfo", Handler: _BlockchainInterface_EnrollNodeInfo_Handler, }, { MethodName: "SetupCommittee", Handler: _BlockchainInterface_SetupCommittee_Handler, }, { MethodName: "LeaveRequest", Handler: _BlockchainInterface_LeaveRequest_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "blockchain_interface.proto", }
BlockchainInterface_ServiceDesc is the grpc.ServiceDesc for BlockchainInterface service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)
var File_blockchain_interface_proto protoreflect.FileDescriptor
Functions ¶
func RegisterBlockchainInterfaceServer ¶
func RegisterBlockchainInterfaceServer(s grpc.ServiceRegistrar, srv BlockchainInterfaceServer)
Types ¶
type BlockchainInterfaceClient ¶
type BlockchainInterfaceClient interface { EnrollNodeInfo(ctx context.Context, in *NodeData, opts ...grpc.CallOption) (*EnrollAccountResponse, error) SetupCommittee(ctx context.Context, in *SetupCommitteeRequest, opts ...grpc.CallOption) (*SetupCommitteeResponse, error) LeaveRequest(ctx context.Context, in *NodeData, opts ...grpc.CallOption) (*Empty, error) }
BlockchainInterfaceClient is the client API for BlockchainInterface 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 NewBlockchainInterfaceClient ¶
func NewBlockchainInterfaceClient(cc grpc.ClientConnInterface) BlockchainInterfaceClient
type BlockchainInterfaceServer ¶
type BlockchainInterfaceServer interface { EnrollNodeInfo(context.Context, *NodeData) (*EnrollAccountResponse, error) SetupCommittee(context.Context, *SetupCommitteeRequest) (*SetupCommitteeResponse, error) LeaveRequest(context.Context, *NodeData) (*Empty, error) // contains filtered or unexported methods }
BlockchainInterfaceServer is the server API for BlockchainInterface service. All implementations must embed UnimplementedBlockchainInterfaceServer for forward compatibility
type Empty ¶
type Empty struct {
// contains filtered or unexported fields
}
func (*Empty) Descriptor
deprecated
func (*Empty) ProtoMessage ¶
func (*Empty) ProtoMessage()
func (*Empty) ProtoReflect ¶
func (x *Empty) ProtoReflect() protoreflect.Message
type EnrollAccountResponse ¶
type EnrollAccountResponse struct { Code int32 `protobuf:"varint,1,opt,name=code,proto3" json:"code,omitempty"` // contains filtered or unexported fields }
func (*EnrollAccountResponse) Descriptor
deprecated
func (*EnrollAccountResponse) Descriptor() ([]byte, []int)
Deprecated: Use EnrollAccountResponse.ProtoReflect.Descriptor instead.
func (*EnrollAccountResponse) GetCode ¶
func (x *EnrollAccountResponse) GetCode() int32
func (*EnrollAccountResponse) ProtoMessage ¶
func (*EnrollAccountResponse) ProtoMessage()
func (*EnrollAccountResponse) ProtoReflect ¶
func (x *EnrollAccountResponse) ProtoReflect() protoreflect.Message
func (*EnrollAccountResponse) Reset ¶
func (x *EnrollAccountResponse) Reset()
func (*EnrollAccountResponse) String ¶
func (x *EnrollAccountResponse) String() string
type LeaveRequestResponse ¶
type LeaveRequestResponse struct { Code int32 `protobuf:"varint,1,opt,name=code,proto3" json:"code,omitempty"` // contains filtered or unexported fields }
func (*LeaveRequestResponse) Descriptor
deprecated
func (*LeaveRequestResponse) Descriptor() ([]byte, []int)
Deprecated: Use LeaveRequestResponse.ProtoReflect.Descriptor instead.
func (*LeaveRequestResponse) GetCode ¶
func (x *LeaveRequestResponse) GetCode() int32
func (*LeaveRequestResponse) ProtoMessage ¶
func (*LeaveRequestResponse) ProtoMessage()
func (*LeaveRequestResponse) ProtoReflect ¶
func (x *LeaveRequestResponse) ProtoReflect() protoreflect.Message
func (*LeaveRequestResponse) Reset ¶
func (x *LeaveRequestResponse) Reset()
func (*LeaveRequestResponse) String ¶
func (x *LeaveRequestResponse) String() string
type NodeData ¶
type NodeData struct { Address string `protobuf:"bytes,1,opt,name=address,proto3" json:"address,omitempty"` Pubkey []byte `protobuf:"bytes,2,opt,name=pubkey,proto3" json:"pubkey,omitempty"` Signature []byte `protobuf:"bytes,3,opt,name=signature,proto3" json:"signature,omitempty"` // contains filtered or unexported fields }
func (*NodeData) Descriptor
deprecated
func (*NodeData) GetAddress ¶
func (*NodeData) GetSignature ¶
func (*NodeData) ProtoMessage ¶
func (*NodeData) ProtoMessage()
func (*NodeData) ProtoReflect ¶
func (x *NodeData) ProtoReflect() protoreflect.Message
type SetupCommitteeRequest ¶
type SetupCommitteeRequest struct { Round int32 `protobuf:"varint,1,opt,name=round,proto3" json:"round,omitempty"` Nodeip string `protobuf:"bytes,2,opt,name=nodeip,proto3" json:"nodeip,omitempty"` Vrfpubkey []byte `protobuf:"bytes,3,opt,name=vrfpubkey,proto3" json:"vrfpubkey,omitempty"` VrfResult *VrfValue `protobuf:"bytes,4,opt,name=vrfResult,proto3" json:"vrfResult,omitempty"` // contains filtered or unexported fields }
func (*SetupCommitteeRequest) Descriptor
deprecated
func (*SetupCommitteeRequest) Descriptor() ([]byte, []int)
Deprecated: Use SetupCommitteeRequest.ProtoReflect.Descriptor instead.
func (*SetupCommitteeRequest) GetNodeip ¶
func (x *SetupCommitteeRequest) GetNodeip() string
func (*SetupCommitteeRequest) GetRound ¶
func (x *SetupCommitteeRequest) GetRound() int32
func (*SetupCommitteeRequest) GetVrfResult ¶
func (x *SetupCommitteeRequest) GetVrfResult() *VrfValue
func (*SetupCommitteeRequest) GetVrfpubkey ¶
func (x *SetupCommitteeRequest) GetVrfpubkey() []byte
func (*SetupCommitteeRequest) ProtoMessage ¶
func (*SetupCommitteeRequest) ProtoMessage()
func (*SetupCommitteeRequest) ProtoReflect ¶
func (x *SetupCommitteeRequest) ProtoReflect() protoreflect.Message
func (*SetupCommitteeRequest) Reset ¶
func (x *SetupCommitteeRequest) Reset()
func (*SetupCommitteeRequest) String ¶
func (x *SetupCommitteeRequest) String() string
type SetupCommitteeResponse ¶
type SetupCommitteeResponse struct { Code int32 `protobuf:"varint,1,opt,name=code,proto3" json:"code,omitempty"` // contains filtered or unexported fields }
func (*SetupCommitteeResponse) Descriptor
deprecated
func (*SetupCommitteeResponse) Descriptor() ([]byte, []int)
Deprecated: Use SetupCommitteeResponse.ProtoReflect.Descriptor instead.
func (*SetupCommitteeResponse) GetCode ¶
func (x *SetupCommitteeResponse) GetCode() int32
func (*SetupCommitteeResponse) ProtoMessage ¶
func (*SetupCommitteeResponse) ProtoMessage()
func (*SetupCommitteeResponse) ProtoReflect ¶
func (x *SetupCommitteeResponse) ProtoReflect() protoreflect.Message
func (*SetupCommitteeResponse) Reset ¶
func (x *SetupCommitteeResponse) Reset()
func (*SetupCommitteeResponse) String ¶
func (x *SetupCommitteeResponse) String() string
type UnimplementedBlockchainInterfaceServer ¶
type UnimplementedBlockchainInterfaceServer struct { }
UnimplementedBlockchainInterfaceServer must be embedded to have forward compatible implementations.
func (UnimplementedBlockchainInterfaceServer) EnrollNodeInfo ¶
func (UnimplementedBlockchainInterfaceServer) EnrollNodeInfo(context.Context, *NodeData) (*EnrollAccountResponse, error)
func (UnimplementedBlockchainInterfaceServer) LeaveRequest ¶
func (UnimplementedBlockchainInterfaceServer) SetupCommittee ¶
func (UnimplementedBlockchainInterfaceServer) SetupCommittee(context.Context, *SetupCommitteeRequest) (*SetupCommitteeResponse, error)
type UnsafeBlockchainInterfaceServer ¶
type UnsafeBlockchainInterfaceServer interface {
// contains filtered or unexported methods
}
UnsafeBlockchainInterfaceServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to BlockchainInterfaceServer will result in compilation errors.
type VrfValue ¶
type VrfValue struct { Val string `protobuf:"bytes,1,opt,name=val,proto3" json:"val,omitempty"` Proof []byte `protobuf:"bytes,2,opt,name=proof,proto3" json:"proof,omitempty"` Pubkey []byte `protobuf:"bytes,3,opt,name=pubkey,proto3" json:"pubkey,omitempty"` // contains filtered or unexported fields }
func (*VrfValue) Descriptor
deprecated
func (*VrfValue) ProtoMessage ¶
func (*VrfValue) ProtoMessage()
func (*VrfValue) ProtoReflect ¶
func (x *VrfValue) ProtoReflect() protoreflect.Message