Documentation
¶
Index ¶
- Variables
- func RegisterBitcoinServer(s grpc.ServiceRegistrar, srv BitcoinServer)
- type BitcoinClient
- type BitcoinServer
- type GenerateToAddressRequest
- func (*GenerateToAddressRequest) Descriptor() ([]byte, []int)deprecated
- func (x *GenerateToAddressRequest) GetAddress() string
- func (x *GenerateToAddressRequest) GetNumOfBlocks() uint32
- func (*GenerateToAddressRequest) ProtoMessage()
- func (x *GenerateToAddressRequest) ProtoReflect() protoreflect.Message
- func (x *GenerateToAddressRequest) Reset()
- func (x *GenerateToAddressRequest) String() string
- type GenerateToAddressResponse
- func (*GenerateToAddressResponse) Descriptor() ([]byte, []int)deprecated
- func (x *GenerateToAddressResponse) GetHashes() []string
- func (*GenerateToAddressResponse) ProtoMessage()
- func (x *GenerateToAddressResponse) ProtoReflect() protoreflect.Message
- func (x *GenerateToAddressResponse) Reset()
- func (x *GenerateToAddressResponse) String() string
- type MockBitcoinClient
- type MockBitcoinClient_Expecter
- type MockBitcoinClient_GenerateToAddress_Call
- func (_c *MockBitcoinClient_GenerateToAddress_Call) Return(_a0 *GenerateToAddressResponse, _a1 error) *MockBitcoinClient_GenerateToAddress_Call
- func (_c *MockBitcoinClient_GenerateToAddress_Call) Run(...) *MockBitcoinClient_GenerateToAddress_Call
- func (_c *MockBitcoinClient_GenerateToAddress_Call) RunAndReturn(...) *MockBitcoinClient_GenerateToAddress_Call
- type UnimplementedBitcoinServer
- type UnsafeBitcoinServer
Constants ¶
This section is empty.
Variables ¶
var Bitcoin_ServiceDesc = grpc.ServiceDesc{ ServiceName: "bitcoin", HandlerType: (*BitcoinServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "GenerateToAddress", Handler: _Bitcoin_GenerateToAddress_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "bitcoin_client.proto", }
Bitcoin_ServiceDesc is the grpc.ServiceDesc for Bitcoin service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)
var File_bitcoin_client_proto protoreflect.FileDescriptor
Functions ¶
func RegisterBitcoinServer ¶
func RegisterBitcoinServer(s grpc.ServiceRegistrar, srv BitcoinServer)
Types ¶
type BitcoinClient ¶
type BitcoinClient interface {
GenerateToAddress(ctx context.Context, in *GenerateToAddressRequest, opts ...grpc.CallOption) (*GenerateToAddressResponse, error)
}
BitcoinClient is the client API for Bitcoin 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 NewBitcoinClient ¶
func NewBitcoinClient(cc grpc.ClientConnInterface) BitcoinClient
type BitcoinServer ¶
type BitcoinServer interface { GenerateToAddress(context.Context, *GenerateToAddressRequest) (*GenerateToAddressResponse, error) // contains filtered or unexported methods }
BitcoinServer is the server API for Bitcoin service. All implementations must embed UnimplementedBitcoinServer for forward compatibility
type GenerateToAddressRequest ¶
type GenerateToAddressRequest struct { Address string `protobuf:"bytes,1,opt,name=address,proto3" json:"address,omitempty"` NumOfBlocks uint32 `protobuf:"varint,2,opt,name=numOfBlocks,proto3" json:"numOfBlocks,omitempty"` // contains filtered or unexported fields }
func (*GenerateToAddressRequest) Descriptor
deprecated
func (*GenerateToAddressRequest) Descriptor() ([]byte, []int)
Deprecated: Use GenerateToAddressRequest.ProtoReflect.Descriptor instead.
func (*GenerateToAddressRequest) GetAddress ¶
func (x *GenerateToAddressRequest) GetAddress() string
func (*GenerateToAddressRequest) GetNumOfBlocks ¶
func (x *GenerateToAddressRequest) GetNumOfBlocks() uint32
func (*GenerateToAddressRequest) ProtoMessage ¶
func (*GenerateToAddressRequest) ProtoMessage()
func (*GenerateToAddressRequest) ProtoReflect ¶
func (x *GenerateToAddressRequest) ProtoReflect() protoreflect.Message
func (*GenerateToAddressRequest) Reset ¶
func (x *GenerateToAddressRequest) Reset()
func (*GenerateToAddressRequest) String ¶
func (x *GenerateToAddressRequest) String() string
type GenerateToAddressResponse ¶
type GenerateToAddressResponse struct { Hashes []string `protobuf:"bytes,1,rep,name=hashes,proto3" json:"hashes,omitempty"` // contains filtered or unexported fields }
func (*GenerateToAddressResponse) Descriptor
deprecated
func (*GenerateToAddressResponse) Descriptor() ([]byte, []int)
Deprecated: Use GenerateToAddressResponse.ProtoReflect.Descriptor instead.
func (*GenerateToAddressResponse) GetHashes ¶
func (x *GenerateToAddressResponse) GetHashes() []string
func (*GenerateToAddressResponse) ProtoMessage ¶
func (*GenerateToAddressResponse) ProtoMessage()
func (*GenerateToAddressResponse) ProtoReflect ¶
func (x *GenerateToAddressResponse) ProtoReflect() protoreflect.Message
func (*GenerateToAddressResponse) Reset ¶
func (x *GenerateToAddressResponse) Reset()
func (*GenerateToAddressResponse) String ¶
func (x *GenerateToAddressResponse) String() string
type MockBitcoinClient ¶ added in v0.3.1
MockBitcoinClient is an autogenerated mock type for the BitcoinClient type
func NewMockBitcoinClient ¶ added in v0.3.1
func NewMockBitcoinClient(t interface { mock.TestingT Cleanup(func()) }) *MockBitcoinClient
NewMockBitcoinClient creates a new instance of MockBitcoinClient. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations. The first argument is typically a *testing.T value.
func (*MockBitcoinClient) EXPECT ¶ added in v0.3.1
func (_m *MockBitcoinClient) EXPECT() *MockBitcoinClient_Expecter
func (*MockBitcoinClient) GenerateToAddress ¶ added in v0.3.1
func (_m *MockBitcoinClient) GenerateToAddress(ctx context.Context, in *GenerateToAddressRequest, opts ...grpc.CallOption) (*GenerateToAddressResponse, error)
GenerateToAddress provides a mock function with given fields: ctx, in, opts
type MockBitcoinClient_Expecter ¶ added in v0.3.1
type MockBitcoinClient_Expecter struct {
// contains filtered or unexported fields
}
func (*MockBitcoinClient_Expecter) GenerateToAddress ¶ added in v0.3.1
func (_e *MockBitcoinClient_Expecter) GenerateToAddress(ctx interface{}, in interface{}, opts ...interface{}) *MockBitcoinClient_GenerateToAddress_Call
GenerateToAddress is a helper method to define mock.On call
- ctx context.Context
- in *GenerateToAddressRequest
- opts ...grpc.CallOption
type MockBitcoinClient_GenerateToAddress_Call ¶ added in v0.3.1
MockBitcoinClient_GenerateToAddress_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GenerateToAddress'
func (*MockBitcoinClient_GenerateToAddress_Call) Return ¶ added in v0.3.1
func (_c *MockBitcoinClient_GenerateToAddress_Call) Return(_a0 *GenerateToAddressResponse, _a1 error) *MockBitcoinClient_GenerateToAddress_Call
func (*MockBitcoinClient_GenerateToAddress_Call) Run ¶ added in v0.3.1
func (_c *MockBitcoinClient_GenerateToAddress_Call) Run(run func(ctx context.Context, in *GenerateToAddressRequest, opts ...grpc.CallOption)) *MockBitcoinClient_GenerateToAddress_Call
func (*MockBitcoinClient_GenerateToAddress_Call) RunAndReturn ¶ added in v0.3.1
func (_c *MockBitcoinClient_GenerateToAddress_Call) RunAndReturn(run func(context.Context, *GenerateToAddressRequest, ...grpc.CallOption) (*GenerateToAddressResponse, error)) *MockBitcoinClient_GenerateToAddress_Call
type UnimplementedBitcoinServer ¶
type UnimplementedBitcoinServer struct { }
UnimplementedBitcoinServer must be embedded to have forward compatible implementations.
func (UnimplementedBitcoinServer) GenerateToAddress ¶
func (UnimplementedBitcoinServer) GenerateToAddress(context.Context, *GenerateToAddressRequest) (*GenerateToAddressResponse, error)
type UnsafeBitcoinServer ¶
type UnsafeBitcoinServer interface {
// contains filtered or unexported methods
}
UnsafeBitcoinServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to BitcoinServer will result in compilation errors.