Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ActionNameRule = regexp.MustCompile("^[a-z](?:[a-z-]*[a-z])?$")
ActionNameRule describes the format an action name must match to be valid.
Functions ¶
Types ¶
type APIClient ¶
type APIClient interface {
io.Closer
// Enqueue takes a list of Actions and queues them up to be executed by
// the designated ActionReceiver, returning the params.Action for each
// queued Action, or an error if there was a problem queueing up the
// Action.
Enqueue(params.Actions) (params.ActionResults, error)
// ListAll takes a list of Tags representing ActionReceivers and returns
// all of the Actions that have been queued or run by each of those
// Entities.
ListAll(params.Entities) (params.ActionsByReceivers, error)
// ListPending takes a list of Tags representing ActionReceivers
// and returns all of the Actions that are queued for each of those
// Entities.
ListPending(params.Entities) (params.ActionsByReceivers, error)
// ListCompleted takes a list of Tags representing ActionReceivers
// and returns all of the Actions that have been run on each of those
// Entities.
ListCompleted(params.Entities) (params.ActionsByReceivers, error)
// Cancel attempts to cancel a queued up Action from running.
Cancel(params.Actions) (params.ActionResults, error)
// ServiceCharmActions is a single query which uses ServicesCharmActions to
// get the charm.Actions for a single Service by tag.
ServiceCharmActions(params.Entity) (*charm.Actions, error)
// Actions fetches actions by tag. These Actions can be used to get
// the ActionReceiver if necessary.
Actions(params.Entities) (params.ActionResults, error)
// FindActionTagsByPrefix takes a list of string prefixes and finds
// corresponding ActionTags that match that prefix.
FindActionTagsByPrefix(params.FindTags) (params.FindTagsResults, error)
}
type APIClient represents the action API functionality.
type ActionCommandBase ¶
type ActionCommandBase struct {
modelcmd.ModelCommandBase
}
ActionCommandBase is the base type for action sub-commands.
func (*ActionCommandBase) NewActionAPIClient ¶
func (c *ActionCommandBase) NewActionAPIClient() (APIClient, error)
NewActionAPIClient returns a client for the action api endpoint.
Source Files
¶
- action.go
- common.go
- defined.go
- do.go
- fetch.go
- status.go
Click to show internal directories.
Click to hide internal directories.