spaces

package
v0.0.0-...-a002913 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 2, 2015 License: AGPL-3.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type API

type API interface {
	CreateSpaces(params.CreateSpacesParams) (params.ErrorResults, error)
	ListSpaces() (params.ListSpacesResults, error)
}

API defines the methods the Spaces API facade implements.

func NewAPI

func NewAPI(st *state.State, res *common.Resources, auth common.Authorizer) (API, error)

NewAPI creates a new Space API server-side facade with a state.State backing.

type Backing

type Backing interface {
	// EnvironConfig returns the configuration of the environment.
	EnvironConfig() (*config.Config, error)

	// AddSpace creates a space.
	AddSpace(name string, subnetIds []string, public bool) error

	// AllSpaces returns all known Juju network spaces.
	AllSpaces() ([]common.BackingSpace, error)
}

Backing defines the state methods this facede needs, so they can be mocked for testing.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL