summaryrefslogtreecommitdiff
path: root/libpod/state.go
diff options
context:
space:
mode:
Diffstat (limited to 'libpod/state.go')
-rw-r--r--libpod/state.go7
1 files changed, 7 insertions, 0 deletions
diff --git a/libpod/state.go b/libpod/state.go
index 4a79b8d2d..63865a541 100644
--- a/libpod/state.go
+++ b/libpod/state.go
@@ -28,6 +28,13 @@ type State interface {
UpdateContainer(ctr *Container) error
// SaveContainer saves a container's current state to the backing store
SaveContainer(ctr *Container) error
+ // ContainerInUse checks if other containers depend upon a given
+ // container
+ // It returns a slice of the IDs of containers which depend on the given
+ // container. If the slice is empty, no container depend on the given
+ // container.
+ // A container cannot be removed if other containers depend on it
+ ContainerInUse(ctr *Container) ([]string, error)
// Retrieves all containers presently in state
AllContainers() ([]*Container, error)