github.com/zhuohuang-hust/src-cbuild@v0.0.0-20230105071821-c7aab3e7c840/api/server/router/volume/backend.go (about) 1 package volume 2 3 import ( 4 // TODO return types need to be refactored into pkg 5 "github.com/docker/docker/api/types" 6 "github.com/docker/docker/api/types/filters" 7 ) 8 9 // Backend is the methods that need to be implemented to provide 10 // volume specific functionality 11 type Backend interface { 12 Volumes(filter string) ([]*types.Volume, []string, error) 13 VolumeInspect(name string) (*types.Volume, error) 14 VolumeCreate(name, driverName string, opts, labels map[string]string) (*types.Volume, error) 15 VolumeRm(name string, force bool) error 16 VolumesPrune(pruneFilters filters.Args) (*types.VolumesPruneReport, error) 17 }