Documentation
¶
Index ¶
- func Create(params CreateParams) (*models.IDResponse, error)
- func Delete(params DeleteParams) error
- func Get(params GetParams) (*models.InstanceConfiguration, error)
- func List(params ListParams) ([]*models.InstanceConfiguration, error)
- func NewConfig(source io.Reader) (*models.InstanceConfiguration, error)
- func PullToFolder(params PullToFolderParams) error
- func Update(params UpdateParams) error
- type CreateParams
- type DeleteParams
- type GetParams
- type InstanceConfigurationOperation
- type ListParams
- type PullToFolderParams
- type UpdateParams
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Create ¶
func Create(params CreateParams) (*models.IDResponse, error)
Create creates a new instance configuration.
func Delete ¶
func Delete(params DeleteParams) error
Delete deletes an already existing instance configuration.
func Get ¶
func Get(params GetParams) (*models.InstanceConfiguration, error)
Get obtains an instance configuration from an ID
func List ¶
func List(params ListParams) ([]*models.InstanceConfiguration, error)
List returns an array of all instance configurations
func NewConfig ¶
func NewConfig(source io.Reader) (*models.InstanceConfiguration, error)
NewConfig creates a new InstanceConfiguration from an io.Reader containing a JSON payload.
func PullToFolder ¶
func PullToFolder(params PullToFolderParams) error
PullToFolder downloads instance configs and save them in a local folder
func Update ¶
func Update(params UpdateParams) error
Update overwrites an already existing instance configuration.
Types ¶
type CreateParams ¶
type CreateParams struct {
*api.API
Config *models.InstanceConfiguration
}
CreateParams is used to create a new instance configuration.
func (CreateParams) Validate ¶
func (params CreateParams) Validate() error
Validate ensures that the parameters are correct.
type DeleteParams ¶
DeleteParams is used to delete an instance configuration from its ID.
func (DeleteParams) Validate ¶
func (params DeleteParams) Validate() error
Validate ensures that the parameters are correct.
type InstanceConfigurationOperation ¶
type InstanceConfigurationOperation uint
InstanceConfigurationOperation define an operation needed for the iC.
const ( // InstanceConfigurationOperationNone No operation needed on IC InstanceConfigurationOperationNone InstanceConfigurationOperation = 0 // InstanceConfigurationOperationUpdate update IC InstanceConfigurationOperationUpdate InstanceConfigurationOperation = 1 // InstanceConfigurationOperationCreate create IC InstanceConfigurationOperationCreate InstanceConfigurationOperation = 2 )
func (InstanceConfigurationOperation) String ¶
func (a InstanceConfigurationOperation) String() string
func (InstanceConfigurationOperation) Valid ¶
func (a InstanceConfigurationOperation) Valid() bool
Valid check validity of instance configuration action
type ListParams ¶
ListParams is used to list all of the available instance configurations.
func (ListParams) Validate ¶
func (params ListParams) Validate() error
Validate ensures that the parameters are correct.
type PullToFolderParams ¶
PullToFolderParams is used to store all available instance configurations in a local folder.
func (PullToFolderParams) Validate ¶
func (params PullToFolderParams) Validate() error
Validate ensures that the parameters are correct.
type UpdateParams ¶
type UpdateParams struct {
*api.API
ID string
Config *models.InstanceConfiguration
}
UpdateParams is used to overwrite an existing instance configuration.
func (UpdateParams) Validate ¶
func (params UpdateParams) Validate() error
Validate ensures that the parameters are correct.