Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(1192)

Side by Side Diff: provider/common/policies.go

Issue 77820044: Add EnvironCapability to state.Policy
Patch Set: Add EnvironCapability to state.Policy Created 9 years, 12 months ago
Left:
Right:
Use n/p to move between diff chunks; N/P to move between comments. Please Sign in to add in-line comments.
Jump to:
View unified diff | Download patch
« no previous file with comments | « provider/azure/environ.go ('k') | provider/dummy/environs.go » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 // Copyright 2014 Canonical Ltd.
2 // Licensed under the AGPLv3, see LICENCE file for details.
3
4 package common
5
6 import (
7 "launchpad.net/juju-core/constraints"
8 "launchpad.net/juju-core/state"
9 )
10
11 // SupportsUnitPlacementPolicy provides an
12 // implementation of SupportsUnitPlacement
13 // that never returns an error, and is
14 // intended for embedding in environs.Environ
15 // implementations.
16 type SupportsUnitPlacementPolicy struct{}
17
18 func (*SupportsUnitPlacementPolicy) SupportsUnitPlacement() error {
19 return nil
20 }
21
22 // NopPrecheckerPolicy provides an implementation of the
23 // state.Prechecker interface that passes all checks.
24 type NopPrecheckerPolicy struct{}
25
26 var _ state.Prechecker = (*NopPrecheckerPolicy)(nil)
27
28 func (*NopPrecheckerPolicy) PrecheckInstance(series string, cons constraints.Val ue) error {
29 return nil
30 }
OLDNEW
« no previous file with comments | « provider/azure/environ.go ('k') | provider/dummy/environs.go » ('j') | no next file with comments »

Powered by Google App Engine
RSS Feeds Recent Issues | This issue
This is Rietveld f62528b