This section is empty.


This section is empty.


func FormatModelBlockInfo

func FormatModelBlockInfo(all []params.ModelBlockInfo) ([]modelBlockInfo, error)

func FormatTabularBlockedModels

func FormatTabularBlockedModels(writer io.Writer, value interface{}) error

    FormatTabularBlockedModels writes out tabular format for blocked models. This method is exported as it is also used by destroy-model.

    func NewDisableCommand

    func NewDisableCommand() cmd.Command

      NewDisableCommand returns a disable-command command instance that will use the default API.

      func NewEnableCommand

      func NewEnableCommand() cmd.Command

        NewEnableCommand returns a new command that eanbles previously disabled command sets.

        func NewListCommand

        func NewListCommand() cmd.Command

          NewListCommand returns the command that lists the disabled commands for the model.

          func ProcessBlockedError

          func ProcessBlockedError(err error, block Block) error

            ProcessBlockedError ensures that correct and user-friendly message is displayed to the user based on the block type.


            type Block

            type Block int8

              Block describes block type

              const (
              	// BlockDestroy describes the block that
              	// blocks destroy- commands
              	BlockDestroy Block = iota
              	// BlockRemove describes the block that
              	// blocks remove- commands
              	// BlockChange describes the block that
              	// blocks change commands

              type BlockInfo

              type BlockInfo struct {
              	Commands string `yaml:"command-set" json:"command-set"`
              	Message  string `yaml:"message,omitempty" json:"message,omitempty"`

                BlockInfo defines the serialization behaviour of the block information.