// Code generated by protoc-gen-go-grpc. DO NOT EDIT. // versions: // - protoc-gen-go-grpc v1.6.1 // - protoc v4.25.9 // source: sso/ldap.proto package pb import ( context "context" grpc "google.golang.org/grpc" codes "google.golang.org/grpc/codes" status "google.golang.org/grpc/status" ) // This is a compile-time assertion to ensure that this generated file // is compatible with the grpc package it is being compiled against. // Requires gRPC-Go v1.64.0 or later. const _ = grpc.SupportPackageIsVersion9 const ( LdapService_GetUsers_FullMethodName = "/ldap.v1.LdapService/GetUsers" LdapService_CreateUser_FullMethodName = "/ldap.v1.LdapService/CreateUser" LdapService_UpdateUser_FullMethodName = "/ldap.v1.LdapService/UpdateUser" LdapService_ChangePassword_FullMethodName = "/ldap.v1.LdapService/ChangePassword" LdapService_ToggleUserStatus_FullMethodName = "/ldap.v1.LdapService/ToggleUserStatus" LdapService_GetGroups_FullMethodName = "/ldap.v1.LdapService/GetGroups" LdapService_AddUserToGroup_FullMethodName = "/ldap.v1.LdapService/AddUserToGroup" LdapService_RemoveUserFromGroup_FullMethodName = "/ldap.v1.LdapService/RemoveUserFromGroup" ) // LdapServiceClient is the client API for LdapService service. // // For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream. type LdapServiceClient interface { // Управление Пользователями (Bind системного аккаунта) --- GetUsers(ctx context.Context, in *EmptyRequest, opts ...grpc.CallOption) (*UserListResponse, error) CreateUser(ctx context.Context, in *CreateUserRequest, opts ...grpc.CallOption) (*StatusResponse, error) UpdateUser(ctx context.Context, in *UpdateUserRequest, opts ...grpc.CallOption) (*StatusResponse, error) ChangePassword(ctx context.Context, in *ChangePasswordRequest, opts ...grpc.CallOption) (*StatusResponse, error) ToggleUserStatus(ctx context.Context, in *ToggleStatusRequest, opts ...grpc.CallOption) (*StatusResponse, error) // Управление Группами --- GetGroups(ctx context.Context, in *EmptyRequest, opts ...grpc.CallOption) (*GroupListResponse, error) AddUserToGroup(ctx context.Context, in *GroupMemberRequest, opts ...grpc.CallOption) (*StatusResponse, error) RemoveUserFromGroup(ctx context.Context, in *GroupMemberRequest, opts ...grpc.CallOption) (*StatusResponse, error) } type ldapServiceClient struct { cc grpc.ClientConnInterface } func NewLdapServiceClient(cc grpc.ClientConnInterface) LdapServiceClient { return &ldapServiceClient{cc} } func (c *ldapServiceClient) GetUsers(ctx context.Context, in *EmptyRequest, opts ...grpc.CallOption) (*UserListResponse, error) { cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...) out := new(UserListResponse) err := c.cc.Invoke(ctx, LdapService_GetUsers_FullMethodName, in, out, cOpts...) if err != nil { return nil, err } return out, nil } func (c *ldapServiceClient) CreateUser(ctx context.Context, in *CreateUserRequest, opts ...grpc.CallOption) (*StatusResponse, error) { cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...) out := new(StatusResponse) err := c.cc.Invoke(ctx, LdapService_CreateUser_FullMethodName, in, out, cOpts...) if err != nil { return nil, err } return out, nil } func (c *ldapServiceClient) UpdateUser(ctx context.Context, in *UpdateUserRequest, opts ...grpc.CallOption) (*StatusResponse, error) { cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...) out := new(StatusResponse) err := c.cc.Invoke(ctx, LdapService_UpdateUser_FullMethodName, in, out, cOpts...) if err != nil { return nil, err } return out, nil } func (c *ldapServiceClient) ChangePassword(ctx context.Context, in *ChangePasswordRequest, opts ...grpc.CallOption) (*StatusResponse, error) { cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...) out := new(StatusResponse) err := c.cc.Invoke(ctx, LdapService_ChangePassword_FullMethodName, in, out, cOpts...) if err != nil { return nil, err } return out, nil } func (c *ldapServiceClient) ToggleUserStatus(ctx context.Context, in *ToggleStatusRequest, opts ...grpc.CallOption) (*StatusResponse, error) { cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...) out := new(StatusResponse) err := c.cc.Invoke(ctx, LdapService_ToggleUserStatus_FullMethodName, in, out, cOpts...) if err != nil { return nil, err } return out, nil } func (c *ldapServiceClient) GetGroups(ctx context.Context, in *EmptyRequest, opts ...grpc.CallOption) (*GroupListResponse, error) { cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...) out := new(GroupListResponse) err := c.cc.Invoke(ctx, LdapService_GetGroups_FullMethodName, in, out, cOpts...) if err != nil { return nil, err } return out, nil } func (c *ldapServiceClient) AddUserToGroup(ctx context.Context, in *GroupMemberRequest, opts ...grpc.CallOption) (*StatusResponse, error) { cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...) out := new(StatusResponse) err := c.cc.Invoke(ctx, LdapService_AddUserToGroup_FullMethodName, in, out, cOpts...) if err != nil { return nil, err } return out, nil } func (c *ldapServiceClient) RemoveUserFromGroup(ctx context.Context, in *GroupMemberRequest, opts ...grpc.CallOption) (*StatusResponse, error) { cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...) out := new(StatusResponse) err := c.cc.Invoke(ctx, LdapService_RemoveUserFromGroup_FullMethodName, in, out, cOpts...) if err != nil { return nil, err } return out, nil } // LdapServiceServer is the server API for LdapService service. // All implementations must embed UnimplementedLdapServiceServer // for forward compatibility. type LdapServiceServer interface { // Управление Пользователями (Bind системного аккаунта) --- GetUsers(context.Context, *EmptyRequest) (*UserListResponse, error) CreateUser(context.Context, *CreateUserRequest) (*StatusResponse, error) UpdateUser(context.Context, *UpdateUserRequest) (*StatusResponse, error) ChangePassword(context.Context, *ChangePasswordRequest) (*StatusResponse, error) ToggleUserStatus(context.Context, *ToggleStatusRequest) (*StatusResponse, error) // Управление Группами --- GetGroups(context.Context, *EmptyRequest) (*GroupListResponse, error) AddUserToGroup(context.Context, *GroupMemberRequest) (*StatusResponse, error) RemoveUserFromGroup(context.Context, *GroupMemberRequest) (*StatusResponse, error) mustEmbedUnimplementedLdapServiceServer() } // UnimplementedLdapServiceServer must be embedded to have // forward compatible implementations. // // NOTE: this should be embedded by value instead of pointer to avoid a nil // pointer dereference when methods are called. type UnimplementedLdapServiceServer struct{} func (UnimplementedLdapServiceServer) GetUsers(context.Context, *EmptyRequest) (*UserListResponse, error) { return nil, status.Error(codes.Unimplemented, "method GetUsers not implemented") } func (UnimplementedLdapServiceServer) CreateUser(context.Context, *CreateUserRequest) (*StatusResponse, error) { return nil, status.Error(codes.Unimplemented, "method CreateUser not implemented") } func (UnimplementedLdapServiceServer) UpdateUser(context.Context, *UpdateUserRequest) (*StatusResponse, error) { return nil, status.Error(codes.Unimplemented, "method UpdateUser not implemented") } func (UnimplementedLdapServiceServer) ChangePassword(context.Context, *ChangePasswordRequest) (*StatusResponse, error) { return nil, status.Error(codes.Unimplemented, "method ChangePassword not implemented") } func (UnimplementedLdapServiceServer) ToggleUserStatus(context.Context, *ToggleStatusRequest) (*StatusResponse, error) { return nil, status.Error(codes.Unimplemented, "method ToggleUserStatus not implemented") } func (UnimplementedLdapServiceServer) GetGroups(context.Context, *EmptyRequest) (*GroupListResponse, error) { return nil, status.Error(codes.Unimplemented, "method GetGroups not implemented") } func (UnimplementedLdapServiceServer) AddUserToGroup(context.Context, *GroupMemberRequest) (*StatusResponse, error) { return nil, status.Error(codes.Unimplemented, "method AddUserToGroup not implemented") } func (UnimplementedLdapServiceServer) RemoveUserFromGroup(context.Context, *GroupMemberRequest) (*StatusResponse, error) { return nil, status.Error(codes.Unimplemented, "method RemoveUserFromGroup not implemented") } func (UnimplementedLdapServiceServer) mustEmbedUnimplementedLdapServiceServer() {} func (UnimplementedLdapServiceServer) testEmbeddedByValue() {} // UnsafeLdapServiceServer may be embedded to opt out of forward compatibility for this service. // Use of this interface is not recommended, as added methods to LdapServiceServer will // result in compilation errors. type UnsafeLdapServiceServer interface { mustEmbedUnimplementedLdapServiceServer() } func RegisterLdapServiceServer(s grpc.ServiceRegistrar, srv LdapServiceServer) { // If the following call panics, it indicates UnimplementedLdapServiceServer was // embedded by pointer and is nil. This will cause panics if an // unimplemented method is ever invoked, so we test this at initialization // time to prevent it from happening at runtime later due to I/O. if t, ok := srv.(interface{ testEmbeddedByValue() }); ok { t.testEmbeddedByValue() } s.RegisterService(&LdapService_ServiceDesc, srv) } func _LdapService_GetUsers_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(EmptyRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(LdapServiceServer).GetUsers(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: LdapService_GetUsers_FullMethodName, } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(LdapServiceServer).GetUsers(ctx, req.(*EmptyRequest)) } return interceptor(ctx, in, info, handler) } func _LdapService_CreateUser_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(CreateUserRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(LdapServiceServer).CreateUser(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: LdapService_CreateUser_FullMethodName, } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(LdapServiceServer).CreateUser(ctx, req.(*CreateUserRequest)) } return interceptor(ctx, in, info, handler) } func _LdapService_UpdateUser_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(UpdateUserRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(LdapServiceServer).UpdateUser(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: LdapService_UpdateUser_FullMethodName, } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(LdapServiceServer).UpdateUser(ctx, req.(*UpdateUserRequest)) } return interceptor(ctx, in, info, handler) } func _LdapService_ChangePassword_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(ChangePasswordRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(LdapServiceServer).ChangePassword(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: LdapService_ChangePassword_FullMethodName, } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(LdapServiceServer).ChangePassword(ctx, req.(*ChangePasswordRequest)) } return interceptor(ctx, in, info, handler) } func _LdapService_ToggleUserStatus_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(ToggleStatusRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(LdapServiceServer).ToggleUserStatus(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: LdapService_ToggleUserStatus_FullMethodName, } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(LdapServiceServer).ToggleUserStatus(ctx, req.(*ToggleStatusRequest)) } return interceptor(ctx, in, info, handler) } func _LdapService_GetGroups_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(EmptyRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(LdapServiceServer).GetGroups(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: LdapService_GetGroups_FullMethodName, } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(LdapServiceServer).GetGroups(ctx, req.(*EmptyRequest)) } return interceptor(ctx, in, info, handler) } func _LdapService_AddUserToGroup_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(GroupMemberRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(LdapServiceServer).AddUserToGroup(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: LdapService_AddUserToGroup_FullMethodName, } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(LdapServiceServer).AddUserToGroup(ctx, req.(*GroupMemberRequest)) } return interceptor(ctx, in, info, handler) } func _LdapService_RemoveUserFromGroup_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(GroupMemberRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(LdapServiceServer).RemoveUserFromGroup(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: LdapService_RemoveUserFromGroup_FullMethodName, } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(LdapServiceServer).RemoveUserFromGroup(ctx, req.(*GroupMemberRequest)) } return interceptor(ctx, in, info, handler) } // LdapService_ServiceDesc is the grpc.ServiceDesc for LdapService service. // It's only intended for direct use with grpc.RegisterService, // and not to be introspected or modified (even as a copy) var LdapService_ServiceDesc = grpc.ServiceDesc{ ServiceName: "ldap.v1.LdapService", HandlerType: (*LdapServiceServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "GetUsers", Handler: _LdapService_GetUsers_Handler, }, { MethodName: "CreateUser", Handler: _LdapService_CreateUser_Handler, }, { MethodName: "UpdateUser", Handler: _LdapService_UpdateUser_Handler, }, { MethodName: "ChangePassword", Handler: _LdapService_ChangePassword_Handler, }, { MethodName: "ToggleUserStatus", Handler: _LdapService_ToggleUserStatus_Handler, }, { MethodName: "GetGroups", Handler: _LdapService_GetGroups_Handler, }, { MethodName: "AddUserToGroup", Handler: _LdapService_AddUserToGroup_Handler, }, { MethodName: "RemoveUserFromGroup", Handler: _LdapService_RemoveUserFromGroup_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "sso/ldap.proto", }