Files
QSfera/pkg/proto/v0/settings.pb.micro.go
T

122 lines
4.4 KiB
Go

// Code generated by protoc-gen-micro. DO NOT EDIT.
// source: settings.proto
package proto
import (
fmt "fmt"
proto "github.com/golang/protobuf/proto"
_ "github.com/grpc-ecosystem/grpc-gateway/protoc-gen-swagger/options"
_ "google.golang.org/genproto/googleapis/api/annotations"
math "math"
)
import (
context "context"
client "github.com/micro/go-micro/v2/client"
server "github.com/micro/go-micro/v2/server"
)
// Reference imports to suppress errors if they are not otherwise used.
var _ = proto.Marshal
var _ = fmt.Errorf
var _ = math.Inf
// This is a compile-time assertion to ensure that this generated file
// is compatible with the proto package it is being compiled against.
// A compilation error at this line likely means your copy of the
// proto package needs to be updated.
const _ = proto.ProtoPackageIsVersion3 // please upgrade the proto package
// Reference imports to suppress errors if they are not otherwise used.
var _ context.Context
var _ client.Option
var _ server.Option
// Client API for BundleService service
type BundleService interface {
CreateSettingsBundle(ctx context.Context, in *CreateSettingsBundleRequest, opts ...client.CallOption) (*CreateSettingsBundleResponse, error)
GetSettingsBundle(ctx context.Context, in *GetSettingsBundleRequest, opts ...client.CallOption) (*GetSettingsBundleResponse, error)
ListSettingsBundles(ctx context.Context, in *ListSettingsBundlesRequest, opts ...client.CallOption) (*ListSettingsBundlesResponse, error)
}
type bundleService struct {
c client.Client
name string
}
func NewBundleService(name string, c client.Client) BundleService {
return &bundleService{
c: c,
name: name,
}
}
func (c *bundleService) CreateSettingsBundle(ctx context.Context, in *CreateSettingsBundleRequest, opts ...client.CallOption) (*CreateSettingsBundleResponse, error) {
req := c.c.NewRequest(c.name, "BundleService.CreateSettingsBundle", in)
out := new(CreateSettingsBundleResponse)
err := c.c.Call(ctx, req, out, opts...)
if err != nil {
return nil, err
}
return out, nil
}
func (c *bundleService) GetSettingsBundle(ctx context.Context, in *GetSettingsBundleRequest, opts ...client.CallOption) (*GetSettingsBundleResponse, error) {
req := c.c.NewRequest(c.name, "BundleService.GetSettingsBundle", in)
out := new(GetSettingsBundleResponse)
err := c.c.Call(ctx, req, out, opts...)
if err != nil {
return nil, err
}
return out, nil
}
func (c *bundleService) ListSettingsBundles(ctx context.Context, in *ListSettingsBundlesRequest, opts ...client.CallOption) (*ListSettingsBundlesResponse, error) {
req := c.c.NewRequest(c.name, "BundleService.ListSettingsBundles", in)
out := new(ListSettingsBundlesResponse)
err := c.c.Call(ctx, req, out, opts...)
if err != nil {
return nil, err
}
return out, nil
}
// Server API for BundleService service
type BundleServiceHandler interface {
CreateSettingsBundle(context.Context, *CreateSettingsBundleRequest, *CreateSettingsBundleResponse) error
GetSettingsBundle(context.Context, *GetSettingsBundleRequest, *GetSettingsBundleResponse) error
ListSettingsBundles(context.Context, *ListSettingsBundlesRequest, *ListSettingsBundlesResponse) error
}
func RegisterBundleServiceHandler(s server.Server, hdlr BundleServiceHandler, opts ...server.HandlerOption) error {
type bundleService interface {
CreateSettingsBundle(ctx context.Context, in *CreateSettingsBundleRequest, out *CreateSettingsBundleResponse) error
GetSettingsBundle(ctx context.Context, in *GetSettingsBundleRequest, out *GetSettingsBundleResponse) error
ListSettingsBundles(ctx context.Context, in *ListSettingsBundlesRequest, out *ListSettingsBundlesResponse) error
}
type BundleService struct {
bundleService
}
h := &bundleServiceHandler{hdlr}
return s.Handle(s.NewHandler(&BundleService{h}, opts...))
}
type bundleServiceHandler struct {
BundleServiceHandler
}
func (h *bundleServiceHandler) CreateSettingsBundle(ctx context.Context, in *CreateSettingsBundleRequest, out *CreateSettingsBundleResponse) error {
return h.BundleServiceHandler.CreateSettingsBundle(ctx, in, out)
}
func (h *bundleServiceHandler) GetSettingsBundle(ctx context.Context, in *GetSettingsBundleRequest, out *GetSettingsBundleResponse) error {
return h.BundleServiceHandler.GetSettingsBundle(ctx, in, out)
}
func (h *bundleServiceHandler) ListSettingsBundles(ctx context.Context, in *ListSettingsBundlesRequest, out *ListSettingsBundlesResponse) error {
return h.BundleServiceHandler.ListSettingsBundles(ctx, in, out)
}