Documentation ¶
Index ¶
- type Server
- func (s *Server) CreateTodo(ctx context.Context, req *todolistpb.CreateTodoRequest) (*todolistpb.CreateTodoResponse, error)
- func (s *Server) DeleteTodo(ctx context.Context, req *todolistpb.DeleteTodoRequest) (*todolistpb.DeleteTodoResponse, error)
- func (s *Server) ListTodos(req *todolistpb.ListTodosRequest, ...) error
- func (s *Server) ReadTodo(ctx context.Context, req *todolistpb.ReadTodoRequest) (*todolistpb.ReadTodoResponse, error)
- func (s *Server) UpdateTodo(ctx context.Context, req *todolistpb.UpdateTodoRequest) (*todolistpb.UpdateTodoResponse, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Server ¶
type Server struct {
Repo db.Repository
}
Server is implementing TodoListServiceServer interface
func (*Server) CreateTodo ¶
func (s *Server) CreateTodo(ctx context.Context, req *todolistpb.CreateTodoRequest) (*todolistpb.CreateTodoResponse, error)
CreateTodo request handler
func (*Server) DeleteTodo ¶
func (s *Server) DeleteTodo(ctx context.Context, req *todolistpb.DeleteTodoRequest) (*todolistpb.DeleteTodoResponse, error)
DeleteTodo request handler
func (*Server) ListTodos ¶
func (s *Server) ListTodos(req *todolistpb.ListTodosRequest, stream todolistpb.TodoListService_ListTodosServer) error
ListTodos request handler
func (*Server) ReadTodo ¶
func (s *Server) ReadTodo(ctx context.Context, req *todolistpb.ReadTodoRequest) (*todolistpb.ReadTodoResponse, error)
ReadTodo request handler
func (*Server) UpdateTodo ¶
func (s *Server) UpdateTodo(ctx context.Context, req *todolistpb.UpdateTodoRequest) (*todolistpb.UpdateTodoResponse, error)
UpdateTodo request handler
Click to show internal directories.
Click to hide internal directories.