proto

package
v1.0.2 Latest Latest
Warning

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

Go to latest
Published: Feb 29, 2024 License: BSD-3-Clause Imports: 10 Imported by: 0

Documentation

Index

Constants

View Source
const (
	Plugin_Meta_FullMethodName    = "/proto.Plugin/Meta"
	Plugin_Symbols_FullMethodName = "/proto.Plugin/Symbols"
	Plugin_Call_FullMethodName    = "/proto.Plugin/Call"
)
View Source
const (
	Module_MemoryRead_FullMethodName  = "/proto.Module/MemoryRead"
	Module_MemoryWrite_FullMethodName = "/proto.Module/MemoryWrite"
)

Variables

View Source
var (
	Type_name = map[int32]string{
		0:   "unknown",
		127: "i32",
		126: "i64",
		125: "f32",
		124: "f64",
	}
	Type_value = map[string]int32{
		"unknown": 0,
		"i32":     127,
		"i64":     126,
		"f32":     125,
		"f64":     124,
	}
)

Enum value maps for Type.

View Source
var (
	IOError_name = map[int32]string{
		0:  "none",
		16: "shortWrite",
		17: "invalidWrite",
		18: "shortBuffer",
		19: "eof",
		20: "noProgress",
	}
	IOError_value = map[string]int32{
		"none":         0,
		"shortWrite":   16,
		"invalidWrite": 17,
		"shortBuffer":  18,
		"eof":          19,
		"noProgress":   20,
	}
)

Enum value maps for IOError.

View Source
var File_orbit_proto protoreflect.FileDescriptor
View Source
var Module_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "proto.Module",
	HandlerType: (*ModuleServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "MemoryRead",
			Handler:    _Module_MemoryRead_Handler,
		},
		{
			MethodName: "MemoryWrite",
			Handler:    _Module_MemoryWrite_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "orbit.proto",
}

Module_ServiceDesc is the grpc.ServiceDesc for Module 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: "Meta",
			Handler:    _Plugin_Meta_Handler,
		},
		{
			MethodName: "Symbols",
			Handler:    _Plugin_Symbols_Handler,
		},
		{
			MethodName: "Call",
			Handler:    _Plugin_Call_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "orbit.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 RegisterModuleServer

func RegisterModuleServer(s grpc.ServiceRegistrar, srv ModuleServer)

func RegisterPluginServer

func RegisterPluginServer(s grpc.ServiceRegistrar, srv PluginServer)

Types

type CallRequest

type CallRequest struct {
	Broker   uint32   `protobuf:"varint,1,opt,name=broker,proto3" json:"broker,omitempty"`
	Function string   `protobuf:"bytes,4,opt,name=function,proto3" json:"function,omitempty"`
	Inputs   []uint64 `protobuf:"varint,16,rep,packed,name=inputs,proto3" json:"inputs,omitempty"`
	// contains filtered or unexported fields
}

comes from main

func (*CallRequest) Descriptor deprecated

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

Deprecated: Use CallRequest.ProtoReflect.Descriptor instead.

func (*CallRequest) GetBroker

func (x *CallRequest) GetBroker() uint32

func (*CallRequest) GetFunction

func (x *CallRequest) GetFunction() string

func (*CallRequest) GetInputs

func (x *CallRequest) GetInputs() []uint64

func (*CallRequest) ProtoMessage

func (*CallRequest) ProtoMessage()

func (*CallRequest) ProtoReflect

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

func (*CallRequest) Reset

func (x *CallRequest) Reset()

func (*CallRequest) String

func (x *CallRequest) String() string

type CallReturn

type CallReturn struct {
	Rets []uint64 `protobuf:"varint,1,rep,packed,name=rets,proto3" json:"rets,omitempty"`
	// contains filtered or unexported fields
}

func (*CallReturn) Descriptor deprecated

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

Deprecated: Use CallReturn.ProtoReflect.Descriptor instead.

func (*CallReturn) GetRets

func (x *CallReturn) GetRets() []uint64

func (*CallReturn) ProtoMessage

func (*CallReturn) ProtoMessage()

func (*CallReturn) ProtoReflect

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

func (*CallReturn) Reset

func (x *CallReturn) Reset()

func (*CallReturn) String

func (x *CallReturn) String() string

type Empty

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

func (*Empty) Descriptor deprecated

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

Deprecated: Use Empty.ProtoReflect.Descriptor instead.

func (*Empty) GetBroker

func (x *Empty) GetBroker() 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 FunctionDefinition

type FunctionDefinition struct {
	Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
	Args []Type `protobuf:"varint,2,rep,packed,name=args,proto3,enum=proto.Type" json:"args,omitempty"`
	Rets []Type `protobuf:"varint,3,rep,packed,name=rets,proto3,enum=proto.Type" json:"rets,omitempty"`
	// contains filtered or unexported fields
}

func (*FunctionDefinition) Descriptor deprecated

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

Deprecated: Use FunctionDefinition.ProtoReflect.Descriptor instead.

func (*FunctionDefinition) GetArgs

func (x *FunctionDefinition) GetArgs() []Type

func (*FunctionDefinition) GetName

func (x *FunctionDefinition) GetName() string

func (*FunctionDefinition) GetRets

func (x *FunctionDefinition) GetRets() []Type

func (*FunctionDefinition) ProtoMessage

func (*FunctionDefinition) ProtoMessage()

func (*FunctionDefinition) ProtoReflect

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

func (*FunctionDefinition) Reset

func (x *FunctionDefinition) Reset()

func (*FunctionDefinition) String

func (x *FunctionDefinition) String() string

type FunctionDefinitions

type FunctionDefinitions struct {
	Functions []*FunctionDefinition `protobuf:"bytes,1,rep,name=functions,proto3" json:"functions,omitempty"`
	// contains filtered or unexported fields
}

func (*FunctionDefinitions) Descriptor deprecated

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

Deprecated: Use FunctionDefinitions.ProtoReflect.Descriptor instead.

func (*FunctionDefinitions) GetFunctions

func (x *FunctionDefinitions) GetFunctions() []*FunctionDefinition

func (*FunctionDefinitions) ProtoMessage

func (*FunctionDefinitions) ProtoMessage()

func (*FunctionDefinitions) ProtoReflect

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

func (*FunctionDefinitions) Reset

func (x *FunctionDefinitions) Reset()

func (*FunctionDefinitions) String

func (x *FunctionDefinitions) String() string

type IOError

type IOError int32
const (
	IOError_none         IOError = 0
	IOError_shortWrite   IOError = 16
	IOError_invalidWrite IOError = 17
	IOError_shortBuffer  IOError = 18
	IOError_eof          IOError = 19
	IOError_noProgress   IOError = 20
)

func (IOError) Descriptor

func (IOError) Descriptor() protoreflect.EnumDescriptor

func (IOError) Enum

func (x IOError) Enum() *IOError

func (IOError) EnumDescriptor deprecated

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

Deprecated: Use IOError.Descriptor instead.

func (IOError) Error

func (x IOError) Error() error

TODO: Below should be generated

func (IOError) Number

func (x IOError) Number() protoreflect.EnumNumber

func (IOError) String

func (x IOError) String() string

func (IOError) Type

func (IOError) Type() protoreflect.EnumType

type Metadata

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

func (*Metadata) Descriptor deprecated

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

Deprecated: Use Metadata.ProtoReflect.Descriptor instead.

func (*Metadata) GetName

func (x *Metadata) GetName() string

func (*Metadata) ProtoMessage

func (*Metadata) ProtoMessage()

func (*Metadata) ProtoReflect

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

func (*Metadata) Reset

func (x *Metadata) Reset()

func (*Metadata) String

func (x *Metadata) String() string

type ModuleClient

type ModuleClient interface {
	MemoryRead(ctx context.Context, in *ReadRequest, opts ...grpc.CallOption) (*ReadReturn, error)
	MemoryWrite(ctx context.Context, in *WriteRequest, opts ...grpc.CallOption) (*WriteReturn, error)
}

ModuleClient is the client API for Module 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 NewModuleClient

func NewModuleClient(cc grpc.ClientConnInterface) ModuleClient

type ModuleServer

type ModuleServer interface {
	MemoryRead(context.Context, *ReadRequest) (*ReadReturn, error)
	MemoryWrite(context.Context, *WriteRequest) (*WriteReturn, error)
	// contains filtered or unexported methods
}

ModuleServer is the server API for Module service. All implementations must embed UnimplementedModuleServer for forward compatibility

type PluginClient

type PluginClient interface {
	Meta(ctx context.Context, in *Empty, opts ...grpc.CallOption) (*Metadata, error)
	Symbols(ctx context.Context, in *Empty, opts ...grpc.CallOption) (*FunctionDefinitions, error)
	Call(ctx context.Context, in *CallRequest, opts ...grpc.CallOption) (*CallReturn, 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 PluginServer

type PluginServer interface {
	Meta(context.Context, *Empty) (*Metadata, error)
	Symbols(context.Context, *Empty) (*FunctionDefinitions, error)
	Call(context.Context, *CallRequest) (*CallReturn, error)
	// contains filtered or unexported methods
}

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

type ReadRequest

type ReadRequest struct {
	Offset uint32 `protobuf:"varint,16,opt,name=offset,proto3" json:"offset,omitempty"`
	Size   uint32 `protobuf:"varint,17,opt,name=size,proto3" json:"size,omitempty"`
	// contains filtered or unexported fields
}

comes from plugin

func (*ReadRequest) Descriptor deprecated

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

Deprecated: Use ReadRequest.ProtoReflect.Descriptor instead.

func (*ReadRequest) GetOffset

func (x *ReadRequest) GetOffset() uint32

func (*ReadRequest) GetSize

func (x *ReadRequest) GetSize() uint32

func (*ReadRequest) ProtoMessage

func (*ReadRequest) ProtoMessage()

func (*ReadRequest) ProtoReflect

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

func (*ReadRequest) Reset

func (x *ReadRequest) Reset()

func (*ReadRequest) String

func (x *ReadRequest) String() string

type ReadReturn

type ReadReturn struct {
	Data  []byte  `protobuf:"bytes,1,opt,name=data,proto3" json:"data,omitempty"`
	Error IOError `protobuf:"varint,2,opt,name=error,proto3,enum=proto.IOError" json:"error,omitempty"`
	// contains filtered or unexported fields
}

func (*ReadReturn) Descriptor deprecated

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

Deprecated: Use ReadReturn.ProtoReflect.Descriptor instead.

func (*ReadReturn) GetData

func (x *ReadReturn) GetData() []byte

func (*ReadReturn) GetError

func (x *ReadReturn) GetError() IOError

func (*ReadReturn) ProtoMessage

func (*ReadReturn) ProtoMessage()

func (*ReadReturn) ProtoReflect

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

func (*ReadReturn) Reset

func (x *ReadReturn) Reset()

func (*ReadReturn) String

func (x *ReadReturn) String() string

type Type

type Type int32
const (
	Type_unknown Type = 0
	Type_i32     Type = 127
	Type_i64     Type = 126
	Type_f32     Type = 125
	Type_f64     Type = 124
)

func (Type) Descriptor

func (Type) Descriptor() protoreflect.EnumDescriptor

func (Type) Enum

func (x Type) Enum() *Type

func (Type) EnumDescriptor deprecated

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

Deprecated: Use Type.Descriptor instead.

func (Type) Number

func (x Type) Number() protoreflect.EnumNumber

func (Type) String

func (x Type) String() string

func (Type) Type

func (Type) Type() protoreflect.EnumType

type UnimplementedModuleServer

type UnimplementedModuleServer struct {
}

UnimplementedModuleServer must be embedded to have forward compatible implementations.

func (UnimplementedModuleServer) MemoryRead

func (UnimplementedModuleServer) MemoryWrite

type UnimplementedPluginServer

type UnimplementedPluginServer struct {
}

UnimplementedPluginServer must be embedded to have forward compatible implementations.

func (UnimplementedPluginServer) Call

func (UnimplementedPluginServer) Meta

func (UnimplementedPluginServer) Symbols

type UnsafeModuleServer

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

UnsafeModuleServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to ModuleServer 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.

type WriteRequest

type WriteRequest struct {
	Offset uint32 `protobuf:"varint,16,opt,name=offset,proto3" json:"offset,omitempty"`
	Data   []byte `protobuf:"bytes,17,opt,name=data,proto3" json:"data,omitempty"`
	// contains filtered or unexported fields
}

comes from plugin

func (*WriteRequest) Descriptor deprecated

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

Deprecated: Use WriteRequest.ProtoReflect.Descriptor instead.

func (*WriteRequest) GetData

func (x *WriteRequest) GetData() []byte

func (*WriteRequest) GetOffset

func (x *WriteRequest) GetOffset() uint32

func (*WriteRequest) ProtoMessage

func (*WriteRequest) ProtoMessage()

func (*WriteRequest) ProtoReflect

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

func (*WriteRequest) Reset

func (x *WriteRequest) Reset()

func (*WriteRequest) String

func (x *WriteRequest) String() string

type WriteReturn

type WriteReturn struct {
	Written uint32  `protobuf:"varint,1,opt,name=written,proto3" json:"written,omitempty"`
	Error   IOError `protobuf:"varint,2,opt,name=error,proto3,enum=proto.IOError" json:"error,omitempty"`
	// contains filtered or unexported fields
}

func (*WriteReturn) Descriptor deprecated

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

Deprecated: Use WriteReturn.ProtoReflect.Descriptor instead.

func (*WriteReturn) GetError

func (x *WriteReturn) GetError() IOError

func (*WriteReturn) GetWritten

func (x *WriteReturn) GetWritten() uint32

func (*WriteReturn) ProtoMessage

func (*WriteReturn) ProtoMessage()

func (*WriteReturn) ProtoReflect

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

func (*WriteReturn) Reset

func (x *WriteReturn) Reset()

func (*WriteReturn) String

func (x *WriteReturn) String() string

Jump to

Keyboard shortcuts

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