ca

package
v8.0.0+incompatible Latest Latest
Warning

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

Go to latest
Published: Mar 19, 2020 License: MIT Imports: 8 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

View Source
const (
	// APIName is used by rsc to display command line help
	APIName = "RightScale Cloud Analytics APIs"
)

Variables

View Source
var GenMetadata = setupMetadata()

Metadata synthetized from all CA APIs metadata; setup once

Functions

func RegisterCommands

func RegisterCommands(registrar rsapi.APICommandRegistrar)

RegisterCommands registers all commands with kinpin application.

Types

type API

type API struct {
	*rsapi.API
}

API is the CA 1.0 common client to all cloud analytics APIs.

func FromCommandLine

func FromCommandLine(cmdLine *cmd.CommandLine) (*API, error)

FromCommandLine builds a client from the command line.

func New

func New(h string, a rsapi.Authenticator) *API

New returns a CA API client.

func (*API) BuildRequest

func (a *API) BuildRequest(resource, action, href string, params rsapi.APIParams) (*http.Request, error)

BuildRequest builds a HTTP request from a resource name and href and an action name and parameters. It is intended for generic clients that need to consume APIs in a generic maner. The method builds an HTTP request that can be fed to PerformRequest.

func (*API) RunCommand

func (a *API) RunCommand(cmd string) (*http.Response, error)

RunCommand parses and runs a command given its name.

func (*API) ShowAPIActions

func (a *API) ShowAPIActions(cmd string) error

ShowAPIActions displays a command actions.

func (*API) ShowCommandHelp

func (a *API) ShowCommandHelp(cmd string) error

ShowCommandHelp displays a command help.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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