proto

package
v0.0.0-...-a4f8eeb Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 25, 2022 License: GPL-3.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrorCode_name = map[int32]string{
		0: "OK",
	}
	ErrorCode_value = map[string]int32{
		"OK": 0,
	}
)

Enum value maps for ErrorCode.

View Source
var File_plugin_proto protoreflect.FileDescriptor
View Source
var PluginHelper_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "proto.PluginHelper",
	HandlerType: (*PluginHelperServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "Eval",
			Handler:    _PluginHelper_Eval_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "plugin.proto",
}

PluginHelper_ServiceDesc is the grpc.ServiceDesc for PluginHelper service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)

View Source
var Plugin_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "proto.Plugin",
	HandlerType: (*PluginServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "Enable",
			Handler:    _Plugin_Enable_Handler,
		},
		{
			MethodName: "Disable",
			Handler:    _Plugin_Disable_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "plugin.proto",
}

Plugin_ServiceDesc is the grpc.ServiceDesc for Plugin service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)

Functions

func RegisterPluginHelperServer

func RegisterPluginHelperServer(s grpc.ServiceRegistrar, srv PluginHelperServer)

func RegisterPluginServer

func RegisterPluginServer(s grpc.ServiceRegistrar, srv PluginServer)

Types

type Empty

type Empty struct {
	Helper uint32 `protobuf:"varint,1,opt,name=helper,proto3" json:"helper,omitempty"`
	// contains filtered or unexported fields
}

func (*Empty) Descriptor deprecated

func (*Empty) Descriptor() ([]byte, []int)

Deprecated: Use Empty.ProtoReflect.Descriptor instead.

func (*Empty) GetHelper

func (x *Empty) GetHelper() uint32

func (*Empty) ProtoMessage

func (*Empty) ProtoMessage()

func (*Empty) ProtoReflect

func (x *Empty) ProtoReflect() protoreflect.Message

func (*Empty) Reset

func (x *Empty) Reset()

func (*Empty) String

func (x *Empty) String() string

type Error

type Error struct {
	Code ErrorCode `protobuf:"varint,1,opt,name=code,proto3,enum=proto.ErrorCode" json:"code,omitempty"`
	// contains filtered or unexported fields
}

func (*Error) Descriptor deprecated

func (*Error) Descriptor() ([]byte, []int)

Deprecated: Use Error.ProtoReflect.Descriptor instead.

func (*Error) GetCode

func (x *Error) GetCode() ErrorCode

func (*Error) ProtoMessage

func (*Error) ProtoMessage()

func (*Error) ProtoReflect

func (x *Error) ProtoReflect() protoreflect.Message

func (*Error) Reset

func (x *Error) Reset()

func (*Error) String

func (x *Error) String() string

type ErrorCode

type ErrorCode int32
const (
	ErrorCode_OK ErrorCode = 0
)

func (ErrorCode) Descriptor

func (ErrorCode) Descriptor() protoreflect.EnumDescriptor

func (ErrorCode) Enum

func (x ErrorCode) Enum() *ErrorCode

func (ErrorCode) EnumDescriptor deprecated

func (ErrorCode) EnumDescriptor() ([]byte, []int)

Deprecated: Use ErrorCode.Descriptor instead.

func (ErrorCode) Number

func (x ErrorCode) Number() protoreflect.EnumNumber

func (ErrorCode) String

func (x ErrorCode) String() string

func (ErrorCode) Type

type EvalRequest

type EvalRequest struct {
	Str string `protobuf:"bytes,1,opt,name=str,proto3" json:"str,omitempty"` // eval str
	// contains filtered or unexported fields
}

func (*EvalRequest) Descriptor deprecated

func (*EvalRequest) Descriptor() ([]byte, []int)

Deprecated: Use EvalRequest.ProtoReflect.Descriptor instead.

func (*EvalRequest) GetStr

func (x *EvalRequest) GetStr() string

func (*EvalRequest) ProtoMessage

func (*EvalRequest) ProtoMessage()

func (*EvalRequest) ProtoReflect

func (x *EvalRequest) ProtoReflect() protoreflect.Message

func (*EvalRequest) Reset

func (x *EvalRequest) Reset()

func (*EvalRequest) String

func (x *EvalRequest) String() string

type EvalResponse

type EvalResponse struct {
	Ret string `protobuf:"bytes,1,opt,name=ret,proto3" json:"ret,omitempty"` // return value
	// contains filtered or unexported fields
}

func (*EvalResponse) Descriptor deprecated

func (*EvalResponse) Descriptor() ([]byte, []int)

Deprecated: Use EvalResponse.ProtoReflect.Descriptor instead.

func (*EvalResponse) GetRet

func (x *EvalResponse) GetRet() string

func (*EvalResponse) ProtoMessage

func (*EvalResponse) ProtoMessage()

func (*EvalResponse) ProtoReflect

func (x *EvalResponse) ProtoReflect() protoreflect.Message

func (*EvalResponse) Reset

func (x *EvalResponse) Reset()

func (*EvalResponse) String

func (x *EvalResponse) String() string

type PluginClient

type PluginClient interface {
	Enable(ctx context.Context, in *Empty, opts ...grpc.CallOption) (*Error, error)
	Disable(ctx context.Context, in *Empty, opts ...grpc.CallOption) (*Error, error)
}

PluginClient is the client API for Plugin 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 NewPluginClient

func NewPluginClient(cc grpc.ClientConnInterface) PluginClient

type PluginHelperClient

type PluginHelperClient interface {
	Eval(ctx context.Context, in *EvalRequest, opts ...grpc.CallOption) (*EvalResponse, error)
}

PluginHelperClient is the client API for PluginHelper 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.

type PluginHelperServer

type PluginHelperServer interface {
	Eval(context.Context, *EvalRequest) (*EvalResponse, error)
	// contains filtered or unexported methods
}

PluginHelperServer is the server API for PluginHelper service. All implementations must embed UnimplementedPluginHelperServer for forward compatibility

type PluginServer

type PluginServer interface {
	Enable(context.Context, *Empty) (*Error, error)
	Disable(context.Context, *Empty) (*Error, error)
	// contains filtered or unexported methods
}

PluginServer is the server API for Plugin service. All implementations must embed UnimplementedPluginServer for forward compatibility

type UnimplementedPluginHelperServer

type UnimplementedPluginHelperServer struct {
}

UnimplementedPluginHelperServer must be embedded to have forward compatible implementations.

func (UnimplementedPluginHelperServer) Eval

type UnimplementedPluginServer

type UnimplementedPluginServer struct {
}

UnimplementedPluginServer must be embedded to have forward compatible implementations.

func (UnimplementedPluginServer) Disable

func (UnimplementedPluginServer) Enable

type UnsafePluginHelperServer

type UnsafePluginHelperServer interface {
	// contains filtered or unexported methods
}

UnsafePluginHelperServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to PluginHelperServer will result in compilation errors.

type UnsafePluginServer

type UnsafePluginServer interface {
	// contains filtered or unexported methods
}

UnsafePluginServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to PluginServer will result in compilation errors.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL