236 lines
7.9 KiB
Go
236 lines
7.9 KiB
Go
|
// Code generated by protoc-gen-go. DO NOT EDIT.
|
||
|
// source: bacheca.proto
|
||
|
|
||
|
package bacheca
|
||
|
|
||
|
import (
|
||
|
context "context"
|
||
|
fmt "fmt"
|
||
|
proto "github.com/golang/protobuf/proto"
|
||
|
grpc "google.golang.org/grpc"
|
||
|
codes "google.golang.org/grpc/codes"
|
||
|
status "google.golang.org/grpc/status"
|
||
|
math "math"
|
||
|
)
|
||
|
|
||
|
// 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
|
||
|
|
||
|
type GetFeedRequest_FeedType int32
|
||
|
|
||
|
const (
|
||
|
GetFeedRequest_RSS GetFeedRequest_FeedType = 0
|
||
|
GetFeedRequest_ATOM GetFeedRequest_FeedType = 1
|
||
|
GetFeedRequest_JSON GetFeedRequest_FeedType = 2
|
||
|
)
|
||
|
|
||
|
var GetFeedRequest_FeedType_name = map[int32]string{
|
||
|
0: "RSS",
|
||
|
1: "ATOM",
|
||
|
2: "JSON",
|
||
|
}
|
||
|
|
||
|
var GetFeedRequest_FeedType_value = map[string]int32{
|
||
|
"RSS": 0,
|
||
|
"ATOM": 1,
|
||
|
"JSON": 2,
|
||
|
}
|
||
|
|
||
|
func (x GetFeedRequest_FeedType) String() string {
|
||
|
return proto.EnumName(GetFeedRequest_FeedType_name, int32(x))
|
||
|
}
|
||
|
|
||
|
func (GetFeedRequest_FeedType) EnumDescriptor() ([]byte, []int) {
|
||
|
return fileDescriptor_fb1fda27af5c282e, []int{0, 0}
|
||
|
}
|
||
|
|
||
|
type GetFeedRequest struct {
|
||
|
FeedType GetFeedRequest_FeedType `protobuf:"varint,1,opt,name=feedType,proto3,enum=GetFeedRequest_FeedType" json:"feedType,omitempty"`
|
||
|
XXX_NoUnkeyedLiteral struct{} `json:"-"`
|
||
|
XXX_unrecognized []byte `json:"-"`
|
||
|
XXX_sizecache int32 `json:"-"`
|
||
|
}
|
||
|
|
||
|
func (m *GetFeedRequest) Reset() { *m = GetFeedRequest{} }
|
||
|
func (m *GetFeedRequest) String() string { return proto.CompactTextString(m) }
|
||
|
func (*GetFeedRequest) ProtoMessage() {}
|
||
|
func (*GetFeedRequest) Descriptor() ([]byte, []int) {
|
||
|
return fileDescriptor_fb1fda27af5c282e, []int{0}
|
||
|
}
|
||
|
|
||
|
func (m *GetFeedRequest) XXX_Unmarshal(b []byte) error {
|
||
|
return xxx_messageInfo_GetFeedRequest.Unmarshal(m, b)
|
||
|
}
|
||
|
func (m *GetFeedRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
|
||
|
return xxx_messageInfo_GetFeedRequest.Marshal(b, m, deterministic)
|
||
|
}
|
||
|
func (m *GetFeedRequest) XXX_Merge(src proto.Message) {
|
||
|
xxx_messageInfo_GetFeedRequest.Merge(m, src)
|
||
|
}
|
||
|
func (m *GetFeedRequest) XXX_Size() int {
|
||
|
return xxx_messageInfo_GetFeedRequest.Size(m)
|
||
|
}
|
||
|
func (m *GetFeedRequest) XXX_DiscardUnknown() {
|
||
|
xxx_messageInfo_GetFeedRequest.DiscardUnknown(m)
|
||
|
}
|
||
|
|
||
|
var xxx_messageInfo_GetFeedRequest proto.InternalMessageInfo
|
||
|
|
||
|
func (m *GetFeedRequest) GetFeedType() GetFeedRequest_FeedType {
|
||
|
if m != nil {
|
||
|
return m.FeedType
|
||
|
}
|
||
|
return GetFeedRequest_RSS
|
||
|
}
|
||
|
|
||
|
type GetFeedResponse struct {
|
||
|
Data string `protobuf:"bytes,1,opt,name=data,proto3" json:"data,omitempty"`
|
||
|
XXX_NoUnkeyedLiteral struct{} `json:"-"`
|
||
|
XXX_unrecognized []byte `json:"-"`
|
||
|
XXX_sizecache int32 `json:"-"`
|
||
|
}
|
||
|
|
||
|
func (m *GetFeedResponse) Reset() { *m = GetFeedResponse{} }
|
||
|
func (m *GetFeedResponse) String() string { return proto.CompactTextString(m) }
|
||
|
func (*GetFeedResponse) ProtoMessage() {}
|
||
|
func (*GetFeedResponse) Descriptor() ([]byte, []int) {
|
||
|
return fileDescriptor_fb1fda27af5c282e, []int{1}
|
||
|
}
|
||
|
|
||
|
func (m *GetFeedResponse) XXX_Unmarshal(b []byte) error {
|
||
|
return xxx_messageInfo_GetFeedResponse.Unmarshal(m, b)
|
||
|
}
|
||
|
func (m *GetFeedResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
|
||
|
return xxx_messageInfo_GetFeedResponse.Marshal(b, m, deterministic)
|
||
|
}
|
||
|
func (m *GetFeedResponse) XXX_Merge(src proto.Message) {
|
||
|
xxx_messageInfo_GetFeedResponse.Merge(m, src)
|
||
|
}
|
||
|
func (m *GetFeedResponse) XXX_Size() int {
|
||
|
return xxx_messageInfo_GetFeedResponse.Size(m)
|
||
|
}
|
||
|
func (m *GetFeedResponse) XXX_DiscardUnknown() {
|
||
|
xxx_messageInfo_GetFeedResponse.DiscardUnknown(m)
|
||
|
}
|
||
|
|
||
|
var xxx_messageInfo_GetFeedResponse proto.InternalMessageInfo
|
||
|
|
||
|
func (m *GetFeedResponse) GetData() string {
|
||
|
if m != nil {
|
||
|
return m.Data
|
||
|
}
|
||
|
return ""
|
||
|
}
|
||
|
|
||
|
func init() {
|
||
|
proto.RegisterEnum("GetFeedRequest_FeedType", GetFeedRequest_FeedType_name, GetFeedRequest_FeedType_value)
|
||
|
proto.RegisterType((*GetFeedRequest)(nil), "GetFeedRequest")
|
||
|
proto.RegisterType((*GetFeedResponse)(nil), "GetFeedResponse")
|
||
|
}
|
||
|
|
||
|
func init() { proto.RegisterFile("bacheca.proto", fileDescriptor_fb1fda27af5c282e) }
|
||
|
|
||
|
var fileDescriptor_fb1fda27af5c282e = []byte{
|
||
|
// 178 bytes of a gzipped FileDescriptorProto
|
||
|
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0xe2, 0x4d, 0x4a, 0x4c, 0xce,
|
||
|
0x48, 0x4d, 0x4e, 0xd4, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x57, 0xca, 0xe7, 0xe2, 0x73, 0x4f, 0x2d,
|
||
|
0x71, 0x4b, 0x4d, 0x4d, 0x09, 0x4a, 0x2d, 0x2c, 0x4d, 0x2d, 0x2e, 0x11, 0x32, 0xe1, 0xe2, 0x48,
|
||
|
0x4b, 0x4d, 0x4d, 0x09, 0xa9, 0x2c, 0x48, 0x95, 0x60, 0x54, 0x60, 0xd4, 0xe0, 0x33, 0x92, 0xd0,
|
||
|
0x43, 0x55, 0xa2, 0xe7, 0x06, 0x95, 0x0f, 0x82, 0xab, 0x54, 0x52, 0xe7, 0xe2, 0x80, 0x89, 0x0a,
|
||
|
0xb1, 0x73, 0x31, 0x07, 0x05, 0x07, 0x0b, 0x30, 0x08, 0x71, 0x70, 0xb1, 0x38, 0x86, 0xf8, 0xfb,
|
||
|
0x0a, 0x30, 0x82, 0x58, 0x5e, 0xc1, 0xfe, 0x7e, 0x02, 0x4c, 0x4a, 0xaa, 0x5c, 0xfc, 0x70, 0xd3,
|
||
|
0x8a, 0x0b, 0xf2, 0xf3, 0x8a, 0x53, 0x85, 0x84, 0xb8, 0x58, 0x52, 0x12, 0x4b, 0x12, 0xc1, 0xb6,
|
||
|
0x71, 0x06, 0x81, 0xd9, 0x46, 0xe6, 0x5c, 0xac, 0x3e, 0xf9, 0x49, 0x49, 0x95, 0x42, 0x7a, 0x5c,
|
||
|
0xec, 0x50, 0xf5, 0x42, 0xfc, 0x68, 0xee, 0x90, 0x12, 0xd0, 0x43, 0x33, 0x4a, 0x89, 0x21, 0x89,
|
||
|
0x0d, 0xec, 0x2f, 0x63, 0x40, 0x00, 0x00, 0x00, 0xff, 0xff, 0xaf, 0x00, 0x13, 0xe2, 0xe8, 0x00,
|
||
|
0x00, 0x00,
|
||
|
}
|
||
|
|
||
|
// Reference imports to suppress errors if they are not otherwise used.
|
||
|
var _ context.Context
|
||
|
var _ grpc.ClientConn
|
||
|
|
||
|
// This is a compile-time assertion to ensure that this generated file
|
||
|
// is compatible with the grpc package it is being compiled against.
|
||
|
const _ = grpc.SupportPackageIsVersion4
|
||
|
|
||
|
// LobbyClient is the client API for Lobby service.
|
||
|
//
|
||
|
// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.
|
||
|
type LobbyClient interface {
|
||
|
GetFeed(ctx context.Context, in *GetFeedRequest, opts ...grpc.CallOption) (*GetFeedResponse, error)
|
||
|
}
|
||
|
|
||
|
type lobbyClient struct {
|
||
|
cc *grpc.ClientConn
|
||
|
}
|
||
|
|
||
|
func NewLobbyClient(cc *grpc.ClientConn) LobbyClient {
|
||
|
return &lobbyClient{cc}
|
||
|
}
|
||
|
|
||
|
func (c *lobbyClient) GetFeed(ctx context.Context, in *GetFeedRequest, opts ...grpc.CallOption) (*GetFeedResponse, error) {
|
||
|
out := new(GetFeedResponse)
|
||
|
err := c.cc.Invoke(ctx, "/Lobby/GetFeed", in, out, opts...)
|
||
|
if err != nil {
|
||
|
return nil, err
|
||
|
}
|
||
|
return out, nil
|
||
|
}
|
||
|
|
||
|
// LobbyServer is the server API for Lobby service.
|
||
|
type LobbyServer interface {
|
||
|
GetFeed(context.Context, *GetFeedRequest) (*GetFeedResponse, error)
|
||
|
}
|
||
|
|
||
|
// UnimplementedLobbyServer can be embedded to have forward compatible implementations.
|
||
|
type UnimplementedLobbyServer struct {
|
||
|
}
|
||
|
|
||
|
func (*UnimplementedLobbyServer) GetFeed(ctx context.Context, req *GetFeedRequest) (*GetFeedResponse, error) {
|
||
|
return nil, status.Errorf(codes.Unimplemented, "method GetFeed not implemented")
|
||
|
}
|
||
|
|
||
|
func RegisterLobbyServer(s *grpc.Server, srv LobbyServer) {
|
||
|
s.RegisterService(&_Lobby_serviceDesc, srv)
|
||
|
}
|
||
|
|
||
|
func _Lobby_GetFeed_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
|
||
|
in := new(GetFeedRequest)
|
||
|
if err := dec(in); err != nil {
|
||
|
return nil, err
|
||
|
}
|
||
|
if interceptor == nil {
|
||
|
return srv.(LobbyServer).GetFeed(ctx, in)
|
||
|
}
|
||
|
info := &grpc.UnaryServerInfo{
|
||
|
Server: srv,
|
||
|
FullMethod: "/Lobby/GetFeed",
|
||
|
}
|
||
|
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
|
||
|
return srv.(LobbyServer).GetFeed(ctx, req.(*GetFeedRequest))
|
||
|
}
|
||
|
return interceptor(ctx, in, info, handler)
|
||
|
}
|
||
|
|
||
|
var _Lobby_serviceDesc = grpc.ServiceDesc{
|
||
|
ServiceName: "Lobby",
|
||
|
HandlerType: (*LobbyServer)(nil),
|
||
|
Methods: []grpc.MethodDesc{
|
||
|
{
|
||
|
MethodName: "GetFeed",
|
||
|
Handler: _Lobby_GetFeed_Handler,
|
||
|
},
|
||
|
},
|
||
|
Streams: []grpc.StreamDesc{},
|
||
|
Metadata: "bacheca.proto",
|
||
|
}
|