matrixprotobuf

git clone git://archive.git.mtrnord.blog/MTRNord/matrixprotobuf.git
Log | Files | Refs | README | LICENSE

matrix.pb.go (12368B)


      1 // Code generated by protoc-gen-go. DO NOT EDIT.
      2 // source: matrix.proto
      3 
      4 /*
      5 Package matrixProtos is a generated protocol buffer package.
      6 
      7 It is generated from these files:
      8 	matrix.proto
      9 
     10 It has these top-level messages:
     11 	VersionsResponse
     12 	Version
     13 	VersionRequest
     14 	LoginRequest
     15 	LoginResponse
     16 	LoginError
     17 */
     18 package matrixProtos
     19 
     20 import proto "github.com/golang/protobuf/proto"
     21 import fmt "fmt"
     22 import math "math"
     23 
     24 import (
     25 	context "golang.org/x/net/context"
     26 	grpc "google.golang.org/grpc"
     27 )
     28 
     29 // Reference imports to suppress errors if they are not otherwise used.
     30 var _ = proto.Marshal
     31 var _ = fmt.Errorf
     32 var _ = math.Inf
     33 
     34 // This is a compile-time assertion to ensure that this generated file
     35 // is compatible with the proto package it is being compiled against.
     36 // A compilation error at this line likely means your copy of the
     37 // proto package needs to be updated.
     38 const _ = proto.ProtoPackageIsVersion2 // please upgrade the proto package
     39 
     40 type VersionsResponse struct {
     41 	Versions []*Version `protobuf:"bytes,1,rep,name=versions" json:"versions,omitempty"`
     42 }
     43 
     44 func (m *VersionsResponse) Reset()                    { *m = VersionsResponse{} }
     45 func (m *VersionsResponse) String() string            { return proto.CompactTextString(m) }
     46 func (*VersionsResponse) ProtoMessage()               {}
     47 func (*VersionsResponse) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{0} }
     48 
     49 func (m *VersionsResponse) GetVersions() []*Version {
     50 	if m != nil {
     51 		return m.Versions
     52 	}
     53 	return nil
     54 }
     55 
     56 type Version struct {
     57 	Version string `protobuf:"bytes,1,opt,name=version" json:"version,omitempty"`
     58 }
     59 
     60 func (m *Version) Reset()                    { *m = Version{} }
     61 func (m *Version) String() string            { return proto.CompactTextString(m) }
     62 func (*Version) ProtoMessage()               {}
     63 func (*Version) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{1} }
     64 
     65 func (m *Version) GetVersion() string {
     66 	if m != nil {
     67 		return m.Version
     68 	}
     69 	return ""
     70 }
     71 
     72 type VersionRequest struct {
     73 	Address string `protobuf:"bytes,1,opt,name=address" json:"address,omitempty"`
     74 }
     75 
     76 func (m *VersionRequest) Reset()                    { *m = VersionRequest{} }
     77 func (m *VersionRequest) String() string            { return proto.CompactTextString(m) }
     78 func (*VersionRequest) ProtoMessage()               {}
     79 func (*VersionRequest) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{2} }
     80 
     81 func (m *VersionRequest) GetAddress() string {
     82 	if m != nil {
     83 		return m.Address
     84 	}
     85 	return ""
     86 }
     87 
     88 type LoginRequest struct {
     89 	Type     string `protobuf:"bytes,1,opt,name=type" json:"type,omitempty"`
     90 	User     string `protobuf:"bytes,2,opt,name=user" json:"user,omitempty"`
     91 	Password string `protobuf:"bytes,3,opt,name=password" json:"password,omitempty"`
     92 	Medium   string `protobuf:"bytes,4,opt,name=medium" json:"medium,omitempty"`
     93 	Address  string `protobuf:"bytes,5,opt,name=address" json:"address,omitempty"`
     94 }
     95 
     96 func (m *LoginRequest) Reset()                    { *m = LoginRequest{} }
     97 func (m *LoginRequest) String() string            { return proto.CompactTextString(m) }
     98 func (*LoginRequest) ProtoMessage()               {}
     99 func (*LoginRequest) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{3} }
    100 
    101 func (m *LoginRequest) GetType() string {
    102 	if m != nil {
    103 		return m.Type
    104 	}
    105 	return ""
    106 }
    107 
    108 func (m *LoginRequest) GetUser() string {
    109 	if m != nil {
    110 		return m.User
    111 	}
    112 	return ""
    113 }
    114 
    115 func (m *LoginRequest) GetPassword() string {
    116 	if m != nil {
    117 		return m.Password
    118 	}
    119 	return ""
    120 }
    121 
    122 func (m *LoginRequest) GetMedium() string {
    123 	if m != nil {
    124 		return m.Medium
    125 	}
    126 	return ""
    127 }
    128 
    129 func (m *LoginRequest) GetAddress() string {
    130 	if m != nil {
    131 		return m.Address
    132 	}
    133 	return ""
    134 }
    135 
    136 type LoginResponse struct {
    137 	AccessToken  string `protobuf:"bytes,1,opt,name=access_token,json=accessToken" json:"access_token,omitempty"`
    138 	HomeServer   string `protobuf:"bytes,2,opt,name=home_server,json=homeServer" json:"home_server,omitempty"`
    139 	UserId       string `protobuf:"bytes,3,opt,name=user_id,json=userId" json:"user_id,omitempty"`
    140 	RefreshToken string `protobuf:"bytes,4,opt,name=refresh_token,json=refreshToken" json:"refresh_token,omitempty"`
    141 }
    142 
    143 func (m *LoginResponse) Reset()                    { *m = LoginResponse{} }
    144 func (m *LoginResponse) String() string            { return proto.CompactTextString(m) }
    145 func (*LoginResponse) ProtoMessage()               {}
    146 func (*LoginResponse) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{4} }
    147 
    148 func (m *LoginResponse) GetAccessToken() string {
    149 	if m != nil {
    150 		return m.AccessToken
    151 	}
    152 	return ""
    153 }
    154 
    155 func (m *LoginResponse) GetHomeServer() string {
    156 	if m != nil {
    157 		return m.HomeServer
    158 	}
    159 	return ""
    160 }
    161 
    162 func (m *LoginResponse) GetUserId() string {
    163 	if m != nil {
    164 		return m.UserId
    165 	}
    166 	return ""
    167 }
    168 
    169 func (m *LoginResponse) GetRefreshToken() string {
    170 	if m != nil {
    171 		return m.RefreshToken
    172 	}
    173 	return ""
    174 }
    175 
    176 type LoginError struct {
    177 	Errcode string `protobuf:"bytes,1,opt,name=errcode" json:"errcode,omitempty"`
    178 	Error   string `protobuf:"bytes,2,opt,name=error" json:"error,omitempty"`
    179 }
    180 
    181 func (m *LoginError) Reset()                    { *m = LoginError{} }
    182 func (m *LoginError) String() string            { return proto.CompactTextString(m) }
    183 func (*LoginError) ProtoMessage()               {}
    184 func (*LoginError) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{5} }
    185 
    186 func (m *LoginError) GetErrcode() string {
    187 	if m != nil {
    188 		return m.Errcode
    189 	}
    190 	return ""
    191 }
    192 
    193 func (m *LoginError) GetError() string {
    194 	if m != nil {
    195 		return m.Error
    196 	}
    197 	return ""
    198 }
    199 
    200 func init() {
    201 	proto.RegisterType((*VersionsResponse)(nil), "matrixProtos.VersionsResponse")
    202 	proto.RegisterType((*Version)(nil), "matrixProtos.Version")
    203 	proto.RegisterType((*VersionRequest)(nil), "matrixProtos.VersionRequest")
    204 	proto.RegisterType((*LoginRequest)(nil), "matrixProtos.LoginRequest")
    205 	proto.RegisterType((*LoginResponse)(nil), "matrixProtos.LoginResponse")
    206 	proto.RegisterType((*LoginError)(nil), "matrixProtos.LoginError")
    207 }
    208 
    209 // Reference imports to suppress errors if they are not otherwise used.
    210 var _ context.Context
    211 var _ grpc.ClientConn
    212 
    213 // This is a compile-time assertion to ensure that this generated file
    214 // is compatible with the grpc package it is being compiled against.
    215 const _ = grpc.SupportPackageIsVersion4
    216 
    217 // Client API for VersionsService service
    218 
    219 type VersionsServiceClient interface {
    220 	Versions(ctx context.Context, in *VersionRequest, opts ...grpc.CallOption) (*VersionsResponse, error)
    221 }
    222 
    223 type versionsServiceClient struct {
    224 	cc *grpc.ClientConn
    225 }
    226 
    227 func NewVersionsServiceClient(cc *grpc.ClientConn) VersionsServiceClient {
    228 	return &versionsServiceClient{cc}
    229 }
    230 
    231 func (c *versionsServiceClient) Versions(ctx context.Context, in *VersionRequest, opts ...grpc.CallOption) (*VersionsResponse, error) {
    232 	out := new(VersionsResponse)
    233 	err := grpc.Invoke(ctx, "/matrixProtos.VersionsService/Versions", in, out, c.cc, opts...)
    234 	if err != nil {
    235 		return nil, err
    236 	}
    237 	return out, nil
    238 }
    239 
    240 // Server API for VersionsService service
    241 
    242 type VersionsServiceServer interface {
    243 	Versions(context.Context, *VersionRequest) (*VersionsResponse, error)
    244 }
    245 
    246 func RegisterVersionsServiceServer(s *grpc.Server, srv VersionsServiceServer) {
    247 	s.RegisterService(&_VersionsService_serviceDesc, srv)
    248 }
    249 
    250 func _VersionsService_Versions_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
    251 	in := new(VersionRequest)
    252 	if err := dec(in); err != nil {
    253 		return nil, err
    254 	}
    255 	if interceptor == nil {
    256 		return srv.(VersionsServiceServer).Versions(ctx, in)
    257 	}
    258 	info := &grpc.UnaryServerInfo{
    259 		Server:     srv,
    260 		FullMethod: "/matrixProtos.VersionsService/Versions",
    261 	}
    262 	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
    263 		return srv.(VersionsServiceServer).Versions(ctx, req.(*VersionRequest))
    264 	}
    265 	return interceptor(ctx, in, info, handler)
    266 }
    267 
    268 var _VersionsService_serviceDesc = grpc.ServiceDesc{
    269 	ServiceName: "matrixProtos.VersionsService",
    270 	HandlerType: (*VersionsServiceServer)(nil),
    271 	Methods: []grpc.MethodDesc{
    272 		{
    273 			MethodName: "Versions",
    274 			Handler:    _VersionsService_Versions_Handler,
    275 		},
    276 	},
    277 	Streams:  []grpc.StreamDesc{},
    278 	Metadata: "matrix.proto",
    279 }
    280 
    281 // Client API for LoginService service
    282 
    283 type LoginServiceClient interface {
    284 	Login(ctx context.Context, in *LoginRequest, opts ...grpc.CallOption) (*LoginResponse, error)
    285 }
    286 
    287 type loginServiceClient struct {
    288 	cc *grpc.ClientConn
    289 }
    290 
    291 func NewLoginServiceClient(cc *grpc.ClientConn) LoginServiceClient {
    292 	return &loginServiceClient{cc}
    293 }
    294 
    295 func (c *loginServiceClient) Login(ctx context.Context, in *LoginRequest, opts ...grpc.CallOption) (*LoginResponse, error) {
    296 	out := new(LoginResponse)
    297 	err := grpc.Invoke(ctx, "/matrixProtos.LoginService/Login", in, out, c.cc, opts...)
    298 	if err != nil {
    299 		return nil, err
    300 	}
    301 	return out, nil
    302 }
    303 
    304 // Server API for LoginService service
    305 
    306 type LoginServiceServer interface {
    307 	Login(context.Context, *LoginRequest) (*LoginResponse, error)
    308 }
    309 
    310 func RegisterLoginServiceServer(s *grpc.Server, srv LoginServiceServer) {
    311 	s.RegisterService(&_LoginService_serviceDesc, srv)
    312 }
    313 
    314 func _LoginService_Login_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
    315 	in := new(LoginRequest)
    316 	if err := dec(in); err != nil {
    317 		return nil, err
    318 	}
    319 	if interceptor == nil {
    320 		return srv.(LoginServiceServer).Login(ctx, in)
    321 	}
    322 	info := &grpc.UnaryServerInfo{
    323 		Server:     srv,
    324 		FullMethod: "/matrixProtos.LoginService/Login",
    325 	}
    326 	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
    327 		return srv.(LoginServiceServer).Login(ctx, req.(*LoginRequest))
    328 	}
    329 	return interceptor(ctx, in, info, handler)
    330 }
    331 
    332 var _LoginService_serviceDesc = grpc.ServiceDesc{
    333 	ServiceName: "matrixProtos.LoginService",
    334 	HandlerType: (*LoginServiceServer)(nil),
    335 	Methods: []grpc.MethodDesc{
    336 		{
    337 			MethodName: "Login",
    338 			Handler:    _LoginService_Login_Handler,
    339 		},
    340 	},
    341 	Streams:  []grpc.StreamDesc{},
    342 	Metadata: "matrix.proto",
    343 }
    344 
    345 func init() { proto.RegisterFile("matrix.proto", fileDescriptor0) }
    346 
    347 var fileDescriptor0 = []byte{
    348 	// 362 bytes of a gzipped FileDescriptorProto
    349 	0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x6c, 0x92, 0x3f, 0x4f, 0xe3, 0x40,
    350 	0x10, 0xc5, 0xe5, 0xcb, 0xdf, 0x9b, 0x38, 0x77, 0xa7, 0xd5, 0xfd, 0xb1, 0x7c, 0x08, 0x82, 0xd3,
    351 	0x44, 0x14, 0x91, 0x08, 0x2d, 0x05, 0x4d, 0x24, 0x90, 0x28, 0xa2, 0x80, 0x68, 0x28, 0x22, 0x63,
    352 	0x0f, 0xc4, 0x42, 0xce, 0x9a, 0x19, 0x27, 0x40, 0xcf, 0x17, 0xe0, 0x1b, 0xa3, 0x5d, 0xcf, 0x5a,
    353 	0x89, 0x94, 0x6e, 0xdf, 0x6f, 0xde, 0x8c, 0xde, 0xee, 0x2c, 0xf8, 0x79, 0x5c, 0x52, 0xf6, 0x36,
    354 	0x2e, 0x48, 0x97, 0x5a, 0x89, 0x9a, 0x19, 0xc1, 0xd1, 0x14, 0x7e, 0xdd, 0x21, 0x71, 0xa6, 0x57,
    355 	0x3c, 0x47, 0x2e, 0xf4, 0x8a, 0x51, 0x9d, 0x42, 0x77, 0x23, 0x2c, 0xf0, 0x06, 0x8d, 0x51, 0x6f,
    356 	0xf2, 0x67, 0xbc, 0xdd, 0x34, 0x96, 0x8e, 0x79, 0x6d, 0x8b, 0x86, 0xd0, 0x11, 0xa8, 0x02, 0xe8,
    357 	0x08, 0x0e, 0xbc, 0x81, 0x37, 0xfa, 0x3e, 0x77, 0x32, 0x3a, 0x81, 0x1f, 0xae, 0x13, 0x5f, 0xd6,
    358 	0xc8, 0xa5, 0xf1, 0xc6, 0x69, 0x4a, 0xc8, 0xec, 0xbc, 0x22, 0xa3, 0x0f, 0x0f, 0xfc, 0x6b, 0xfd,
    359 	0x94, 0xd5, 0x56, 0x05, 0xcd, 0xf2, 0xbd, 0x40, 0xf1, 0xd9, 0xb3, 0x61, 0x6b, 0x46, 0x0a, 0xbe,
    360 	0x55, 0xcc, 0x9c, 0x55, 0x08, 0xdd, 0x22, 0x66, 0x7e, 0xd5, 0x94, 0x06, 0x0d, 0xcb, 0x6b, 0xad,
    361 	0xfe, 0x42, 0x3b, 0xc7, 0x34, 0x5b, 0xe7, 0x41, 0xd3, 0x56, 0x44, 0x6d, 0xc7, 0x68, 0xed, 0xc6,
    362 	0xf8, 0xf4, 0xa0, 0x2f, 0x31, 0xe4, 0x71, 0x8e, 0xc1, 0x8f, 0x93, 0x04, 0x99, 0x17, 0xa5, 0x7e,
    363 	0x46, 0x77, 0xc7, 0x5e, 0xc5, 0x6e, 0x0d, 0x52, 0x47, 0xd0, 0x5b, 0xea, 0x1c, 0x17, 0x8c, 0xb4,
    364 	0xa9, 0xd3, 0x81, 0x41, 0x37, 0x96, 0xa8, 0x7f, 0xd0, 0x31, 0x59, 0x17, 0x99, 0x8b, 0xd8, 0x36,
    365 	0xf2, 0x2a, 0x55, 0x43, 0xe8, 0x13, 0x3e, 0x12, 0xf2, 0x52, 0xa6, 0x57, 0x39, 0x7d, 0x81, 0x76,
    366 	0x7c, 0x74, 0x0e, 0x60, 0x23, 0x4d, 0x89, 0x34, 0x99, 0xec, 0x48, 0x94, 0xe8, 0xd4, 0x3d, 0x8d,
    367 	0x93, 0xea, 0x37, 0xb4, 0xd0, 0x58, 0x24, 0x40, 0x25, 0x26, 0xf7, 0xf0, 0xd3, 0x2d, 0xdc, 0xa4,
    368 	0xc9, 0x12, 0x54, 0x97, 0xd0, 0x75, 0x48, 0x1d, 0xec, 0xdf, 0x74, 0xb5, 0x84, 0xf0, 0x70, 0x6f,
    369 	0xb5, 0xfe, 0x39, 0x93, 0x99, 0x2c, 0xcd, 0x4d, 0xbe, 0x80, 0x96, 0xd5, 0x2a, 0xdc, 0x6d, 0xdc,
    370 	0xde, 0x6c, 0xf8, 0x7f, 0x6f, 0xad, 0x9a, 0xf8, 0xd0, 0xb6, 0x9f, 0xf6, 0xec, 0x2b, 0x00, 0x00,
    371 	0xff, 0xff, 0xe2, 0x4a, 0x17, 0x1e, 0xc4, 0x02, 0x00, 0x00,
    372 }