backend.go 623 B

1234567891011121314151617181920
  1. package system
  2. import (
  3. "time"
  4. "github.com/docker/engine-api/types"
  5. "github.com/docker/engine-api/types/events"
  6. "github.com/docker/engine-api/types/filters"
  7. "golang.org/x/net/context"
  8. )
  9. // Backend is the methods that need to be implemented to provide
  10. // system specific functionality.
  11. type Backend interface {
  12. SystemInfo() (*types.Info, error)
  13. SystemVersion() types.Version
  14. SubscribeToEvents(since, until time.Time, ef filters.Args) ([]events.Message, chan interface{})
  15. UnsubscribeFromEvents(chan interface{})
  16. AuthenticateToRegistry(ctx context.Context, authConfig *types.AuthConfig) (string, string, error)
  17. }