Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
var File__2ban_proto protoreflect.FileDescriptor
var IP2Ban_ServiceDesc = grpc.ServiceDesc{ ServiceName: "IP2ban", HandlerType: (*IP2BanServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "IP", Handler: _IP2Ban_IP_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "2ban.proto", }
IP2Ban_ServiceDesc is the grpc.ServiceDesc for IP2Ban service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)
Functions ¶
func RegisterIP2BanServer ¶
func RegisterIP2BanServer(s grpc.ServiceRegistrar, srv IP2BanServer)
Types ¶
type IP2BanClient ¶
type IP2BanClient interface {
IP(ctx context.Context, in *IPStringRequest, opts ...grpc.CallOption) (*OKReply, error)
}
IP2BanClient is the client API for IP2Ban 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 NewIP2BanClient ¶
func NewIP2BanClient(cc grpc.ClientConnInterface) IP2BanClient
type IP2BanServer ¶
type IP2BanServer interface { IP(context.Context, *IPStringRequest) (*OKReply, error) // contains filtered or unexported methods }
IP2BanServer is the server API for IP2Ban service. All implementations must embed UnimplementedIP2BanServer for forward compatibility
type IPStringRequest ¶
type IPStringRequest struct { Ip string `protobuf:"bytes,1,opt,name=ip,proto3" json:"ip,omitempty"` // contains filtered or unexported fields }
func (*IPStringRequest) Descriptor
deprecated
func (*IPStringRequest) Descriptor() ([]byte, []int)
Deprecated: Use IPStringRequest.ProtoReflect.Descriptor instead.
func (*IPStringRequest) GetIp ¶
func (x *IPStringRequest) GetIp() string
func (*IPStringRequest) ProtoMessage ¶
func (*IPStringRequest) ProtoMessage()
func (*IPStringRequest) ProtoReflect ¶
func (x *IPStringRequest) ProtoReflect() protoreflect.Message
func (*IPStringRequest) Reset ¶
func (x *IPStringRequest) Reset()
func (*IPStringRequest) String ¶
func (x *IPStringRequest) String() string
type OKReply ¶
type OKReply struct { Ok bool `protobuf:"varint,1,opt,name=ok,proto3" json:"ok,omitempty"` // contains filtered or unexported fields }
func (*OKReply) Descriptor
deprecated
func (*OKReply) ProtoMessage ¶
func (*OKReply) ProtoMessage()
func (*OKReply) ProtoReflect ¶
func (x *OKReply) ProtoReflect() protoreflect.Message
type Server ¶
type Server struct {
UnimplementedIP2BanServer
}
type UnimplementedIP2BanServer ¶
type UnimplementedIP2BanServer struct { }
UnimplementedIP2BanServer must be embedded to have forward compatible implementations.
func (UnimplementedIP2BanServer) IP ¶
func (UnimplementedIP2BanServer) IP(context.Context, *IPStringRequest) (*OKReply, error)
type UnsafeIP2BanServer ¶
type UnsafeIP2BanServer interface {
// contains filtered or unexported methods
}
UnsafeIP2BanServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to IP2BanServer will result in compilation errors.