github.com/niedbalski/juju@v0.0.0-20190215020005-8ff100488e47/apiserver/facades/client/block/state.go (about) 1 // Copyright 2015 Canonical Ltd. 2 // Licensed under the AGPLv3, see LICENCE file for details. 3 4 package block 5 6 import ( 7 names "gopkg.in/juju/names.v2" 8 9 "github.com/juju/juju/state" 10 ) 11 12 type blockAccess interface { 13 AllBlocks() ([]state.Block, error) 14 SwitchBlockOn(t state.BlockType, msg string) error 15 SwitchBlockOff(t state.BlockType) error 16 ModelTag() names.ModelTag 17 } 18 19 // TODO - CAAS(ericclaudejones): This should contain state alone, model will be 20 // removed once all relevant methods are moved from state to model. 21 type stateShim struct { 22 *state.State 23 *state.Model 24 }