3
0
corteza/system/proto/role.pb.go

255 lines
8.4 KiB
Go

// Code generated by protoc-gen-go. DO NOT EDIT.
// source: role.proto
package proto
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 FindRoleRequest struct {
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *FindRoleRequest) Reset() { *m = FindRoleRequest{} }
func (m *FindRoleRequest) String() string { return proto.CompactTextString(m) }
func (*FindRoleRequest) ProtoMessage() {}
func (*FindRoleRequest) Descriptor() ([]byte, []int) {
return fileDescriptor_48a3ff9f7c9032f8, []int{0}
}
func (m *FindRoleRequest) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_FindRoleRequest.Unmarshal(m, b)
}
func (m *FindRoleRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_FindRoleRequest.Marshal(b, m, deterministic)
}
func (m *FindRoleRequest) XXX_Merge(src proto.Message) {
xxx_messageInfo_FindRoleRequest.Merge(m, src)
}
func (m *FindRoleRequest) XXX_Size() int {
return xxx_messageInfo_FindRoleRequest.Size(m)
}
func (m *FindRoleRequest) XXX_DiscardUnknown() {
xxx_messageInfo_FindRoleRequest.DiscardUnknown(m)
}
var xxx_messageInfo_FindRoleRequest proto.InternalMessageInfo
type FindRoleResponse struct {
Roles []*Role `protobuf:"bytes,1,rep,name=roles,proto3" json:"roles,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *FindRoleResponse) Reset() { *m = FindRoleResponse{} }
func (m *FindRoleResponse) String() string { return proto.CompactTextString(m) }
func (*FindRoleResponse) ProtoMessage() {}
func (*FindRoleResponse) Descriptor() ([]byte, []int) {
return fileDescriptor_48a3ff9f7c9032f8, []int{1}
}
func (m *FindRoleResponse) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_FindRoleResponse.Unmarshal(m, b)
}
func (m *FindRoleResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_FindRoleResponse.Marshal(b, m, deterministic)
}
func (m *FindRoleResponse) XXX_Merge(src proto.Message) {
xxx_messageInfo_FindRoleResponse.Merge(m, src)
}
func (m *FindRoleResponse) XXX_Size() int {
return xxx_messageInfo_FindRoleResponse.Size(m)
}
func (m *FindRoleResponse) XXX_DiscardUnknown() {
xxx_messageInfo_FindRoleResponse.DiscardUnknown(m)
}
var xxx_messageInfo_FindRoleResponse proto.InternalMessageInfo
func (m *FindRoleResponse) GetRoles() []*Role {
if m != nil {
return m.Roles
}
return nil
}
type Role struct {
ID uint64 `protobuf:"varint,1,opt,name=ID,proto3" json:"ID,omitempty"`
Handle string `protobuf:"bytes,2,opt,name=handle,proto3" json:"handle,omitempty"`
Name string `protobuf:"bytes,3,opt,name=name,proto3" json:"name,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *Role) Reset() { *m = Role{} }
func (m *Role) String() string { return proto.CompactTextString(m) }
func (*Role) ProtoMessage() {}
func (*Role) Descriptor() ([]byte, []int) {
return fileDescriptor_48a3ff9f7c9032f8, []int{2}
}
func (m *Role) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_Role.Unmarshal(m, b)
}
func (m *Role) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_Role.Marshal(b, m, deterministic)
}
func (m *Role) XXX_Merge(src proto.Message) {
xxx_messageInfo_Role.Merge(m, src)
}
func (m *Role) XXX_Size() int {
return xxx_messageInfo_Role.Size(m)
}
func (m *Role) XXX_DiscardUnknown() {
xxx_messageInfo_Role.DiscardUnknown(m)
}
var xxx_messageInfo_Role proto.InternalMessageInfo
func (m *Role) GetID() uint64 {
if m != nil {
return m.ID
}
return 0
}
func (m *Role) GetHandle() string {
if m != nil {
return m.Handle
}
return ""
}
func (m *Role) GetName() string {
if m != nil {
return m.Name
}
return ""
}
func init() {
proto.RegisterType((*FindRoleRequest)(nil), "system.FindRoleRequest")
proto.RegisterType((*FindRoleResponse)(nil), "system.FindRoleResponse")
proto.RegisterType((*Role)(nil), "system.Role")
}
func init() { proto.RegisterFile("role.proto", fileDescriptor_48a3ff9f7c9032f8) }
var fileDescriptor_48a3ff9f7c9032f8 = []byte{
// 189 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0xe2, 0x2a, 0xca, 0xcf, 0x49,
0xd5, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, 0x62, 0x2b, 0xae, 0x2c, 0x2e, 0x49, 0xcd, 0x55, 0x12,
0xe4, 0xe2, 0x77, 0xcb, 0xcc, 0x4b, 0x09, 0xca, 0xcf, 0x49, 0x0d, 0x4a, 0x2d, 0x2c, 0x4d, 0x2d,
0x2e, 0x51, 0x32, 0xe3, 0x12, 0x40, 0x08, 0x15, 0x17, 0xe4, 0xe7, 0x15, 0xa7, 0x0a, 0x29, 0x71,
0xb1, 0x82, 0x34, 0x17, 0x4b, 0x30, 0x2a, 0x30, 0x6b, 0x70, 0x1b, 0xf1, 0xe8, 0x41, 0xb4, 0xeb,
0x81, 0x15, 0x41, 0xa4, 0x94, 0x9c, 0xb8, 0x58, 0x40, 0x5c, 0x21, 0x3e, 0x2e, 0x26, 0x4f, 0x17,
0x09, 0x46, 0x05, 0x46, 0x0d, 0x96, 0x20, 0x26, 0x4f, 0x17, 0x21, 0x31, 0x2e, 0xb6, 0x8c, 0xc4,
0xbc, 0x94, 0x9c, 0x54, 0x09, 0x26, 0x05, 0x46, 0x0d, 0xce, 0x20, 0x28, 0x4f, 0x48, 0x88, 0x8b,
0x25, 0x2f, 0x31, 0x37, 0x55, 0x82, 0x19, 0x2c, 0x0a, 0x66, 0x1b, 0x39, 0x71, 0xb1, 0x82, 0xcc,
0x28, 0x16, 0xb2, 0xe4, 0x62, 0x01, 0x39, 0x42, 0x48, 0x1c, 0x66, 0x13, 0x9a, 0x2b, 0xa5, 0x24,
0x30, 0x25, 0x20, 0x6e, 0x75, 0x62, 0x8f, 0x62, 0x05, 0xfb, 0x31, 0x89, 0x0d, 0x4c, 0x19, 0x03,
0x02, 0x00, 0x00, 0xff, 0xff, 0x80, 0x25, 0xf0, 0xe7, 0xf8, 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
// RolesClient is the client API for Roles service.
//
// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.
type RolesClient interface {
Find(ctx context.Context, in *FindRoleRequest, opts ...grpc.CallOption) (*FindRoleResponse, error)
}
type rolesClient struct {
cc *grpc.ClientConn
}
func NewRolesClient(cc *grpc.ClientConn) RolesClient {
return &rolesClient{cc}
}
func (c *rolesClient) Find(ctx context.Context, in *FindRoleRequest, opts ...grpc.CallOption) (*FindRoleResponse, error) {
out := new(FindRoleResponse)
err := c.cc.Invoke(ctx, "/system.Roles/Find", in, out, opts...)
if err != nil {
return nil, err
}
return out, nil
}
// RolesServer is the server API for Roles service.
type RolesServer interface {
Find(context.Context, *FindRoleRequest) (*FindRoleResponse, error)
}
// UnimplementedRolesServer can be embedded to have forward compatible implementations.
type UnimplementedRolesServer struct {
}
func (*UnimplementedRolesServer) Find(ctx context.Context, req *FindRoleRequest) (*FindRoleResponse, error) {
return nil, status.Errorf(codes.Unimplemented, "method Find not implemented")
}
func RegisterRolesServer(s *grpc.Server, srv RolesServer) {
s.RegisterService(&_Roles_serviceDesc, srv)
}
func _Roles_Find_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
in := new(FindRoleRequest)
if err := dec(in); err != nil {
return nil, err
}
if interceptor == nil {
return srv.(RolesServer).Find(ctx, in)
}
info := &grpc.UnaryServerInfo{
Server: srv,
FullMethod: "/system.Roles/Find",
}
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
return srv.(RolesServer).Find(ctx, req.(*FindRoleRequest))
}
return interceptor(ctx, in, info, handler)
}
var _Roles_serviceDesc = grpc.ServiceDesc{
ServiceName: "system.Roles",
HandlerType: (*RolesServer)(nil),
Methods: []grpc.MethodDesc{
{
MethodName: "Find",
Handler: _Roles_Find_Handler,
},
},
Streams: []grpc.StreamDesc{},
Metadata: "role.proto",
}