Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type File ¶
type File struct { *Request FileDesc *descriptorpb.FileDescriptorProto }
File enscapsulates the generator scope for a single file within a generation request.
func (*File) EnterService ¶
func (s *File) EnterService(d *descriptorpb.ServiceDescriptorProto) *Service
EnterService returns a scope for a service within this file.
func (*File) GoPackage ¶
GoPackage returns the import path and unqualified package name for the file being generated.
func (*File) OutputFileName ¶
OutputFileName returns the name of the file that is generated based on this file.
type Method ¶
type Method struct { *Service MethodDesc *descriptorpb.MethodDescriptorProto }
Method enscapsulates the generator scope for a single method of a service.
func (*Method) GoInputType ¶
GoInputType returns the package path and type name for the Go type that is used as the input message for this method.
func (*Method) GoOutputType ¶
GoOutputType returns the package path and type name for the Go type that is used as the output message for this method.
func (*Method) RuntimeCallConstructor ¶
RuntimeCallConstructor returns the name of the function that returns a new runtime.Call for this method.
func (*Method) RuntimeCallImpl ¶
RuntimeCallImpl returns the name of the runtime.Call implementation for this method.
func (*Method) RuntimeMethodImpl ¶
RuntimeMethodImpl returns the name of the runtime.Method implementation for this method.
type Request ¶
type Request struct { GenRequest *pluginpb.CodeGeneratorRequest GoModule string }
Request enscapsulates the generator scope for an entire generation request.
func (*Request) EnterFile ¶
func (s *Request) EnterFile(d *descriptorpb.FileDescriptorProto) *File
EnterFile returns a scope for a file within this request.
type Service ¶
type Service struct { *File ServiceDesc *descriptorpb.ServiceDescriptorProto }
Service enscapsulates the generator scope for a single service within a file.
func (*Service) ClientConstructor ¶
ClientConstructor returns the name of the function that returns a new client for this service.
func (*Service) ClientImpl ¶
ClientImpl returns the name of the struct that implements the client for this service.
func (*Service) EnterMethod ¶
func (s *Service) EnterMethod(d *descriptorpb.MethodDescriptorProto) *Method
EnterMethod returns a scope for a method within this service.
func (*Service) RuntimeServiceImpl ¶
RuntimeServiceImpl returns the name of the runtime.Service implementation for this service.
func (*Service) ServiceInterface ¶
ServiceInterface returns the name of the user-facing interface for this service.
func (*Service) ServiceRegisterFunc ¶
ServiceRegisterFunc returns the name of the function that registers an implementation of this service with a registry.