github.com/docker/libcompose@v0.4.1-0.20210616120443-2a046c0bdbf2/project/network.go (about) 1 package project 2 3 import ( 4 "golang.org/x/net/context" 5 6 "github.com/docker/libcompose/config" 7 ) 8 9 // Networks defines the methods a libcompose network aggregate should define. 10 type Networks interface { 11 Initialize(ctx context.Context) error 12 Remove(ctx context.Context) error 13 } 14 15 // NetworksFactory is an interface factory to create Networks object for the specified 16 // configurations (service, networks, …) 17 type NetworksFactory interface { 18 Create(projectName string, networkConfigs map[string]*config.NetworkConfig, serviceConfigs *config.ServiceConfigs, networkEnabled bool) (Networks, error) 19 }