containers.go 2.0 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667
  1. /*
  2. Copyright 2020 Docker, Inc.
  3. Licensed under the Apache License, Version 2.0 (the "License");
  4. you may not use this file except in compliance with the License.
  5. You may obtain a copy of the License at
  6. http://www.apache.org/licenses/LICENSE-2.0
  7. Unless required by applicable law or agreed to in writing, software
  8. distributed under the License is distributed on an "AS IS" BASIS,
  9. WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  10. See the License for the specific language governing permissions and
  11. limitations under the License.
  12. */
  13. package client
  14. import (
  15. "context"
  16. "github.com/docker/api/containers"
  17. "github.com/docker/api/errdefs"
  18. )
  19. type containerService struct {
  20. }
  21. // List returns all the containers
  22. func (c *containerService) List(context.Context, bool) ([]containers.Container, error) {
  23. return nil, errdefs.ErrNotImplemented
  24. }
  25. // Start starts a stopped container
  26. func (c *containerService) Start(context.Context, string) error {
  27. return errdefs.ErrNotImplemented
  28. }
  29. // Stop stops the running container
  30. func (c *containerService) Stop(context.Context, string, *uint32) error {
  31. return errdefs.ErrNotImplemented
  32. }
  33. // Run creates and starts a container
  34. func (c *containerService) Run(context.Context, containers.ContainerConfig) error {
  35. return errdefs.ErrNotImplemented
  36. }
  37. // Exec executes a command inside a running container
  38. func (c *containerService) Exec(context.Context, string, containers.ExecRequest) error {
  39. return errdefs.ErrNotImplemented
  40. }
  41. // Logs returns all the logs of a container
  42. func (c *containerService) Logs(context.Context, string, containers.LogsRequest) error {
  43. return errdefs.ErrNotImplemented
  44. }
  45. // Delete removes containers
  46. func (c *containerService) Delete(context.Context, string, containers.DeleteRequest) error {
  47. return errdefs.ErrNotImplemented
  48. }
  49. // Inspect get a specific container
  50. func (c *containerService) Inspect(context.Context, string) (containers.Container, error) {
  51. return containers.Container{}, errdefs.ErrNotImplemented
  52. }