instance

package
v1.3.1 Latest Latest
Warning

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

Go to latest
Published: Jul 21, 2020 License: MPL-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

type Client struct {
	// contains filtered or unexported fields
}

Client for instance API

func (*Client) GetWorkloadInstance

func (a *Client) GetWorkloadInstance(params *GetWorkloadInstanceParams, authInfo runtime.ClientAuthInfoWriter) (*GetWorkloadInstanceOK, error)

GetWorkloadInstance gets a workload instance

func (*Client) RestartInstance

func (a *Client) RestartInstance(params *RestartInstanceParams, authInfo runtime.ClientAuthInfoWriter) (*RestartInstanceNoContent, error)

RestartInstance restarts an instance

The action is performed asynchronously and a successful response does not mean the instance has restarted yet.

func (*Client) SetTransport

func (a *Client) SetTransport(transport runtime.ClientTransport)

SetTransport changes the transport on the client

type ClientService

type ClientService interface {
	GetWorkloadInstance(params *GetWorkloadInstanceParams, authInfo runtime.ClientAuthInfoWriter) (*GetWorkloadInstanceOK, error)

	RestartInstance(params *RestartInstanceParams, authInfo runtime.ClientAuthInfoWriter) (*RestartInstanceNoContent, error)

	SetTransport(transport runtime.ClientTransport)
}

ClientService is the interface for Client methods

func New

func New(transport runtime.ClientTransport, formats strfmt.Registry) ClientService

New creates a new instance API client.

type GetWorkloadInstanceDefault

type GetWorkloadInstanceDefault struct {
	Payload *workload_models.StackpathapiStatus
	// contains filtered or unexported fields
}

GetWorkloadInstanceDefault handles this case with default header values.

Default error structure.

func NewGetWorkloadInstanceDefault

func NewGetWorkloadInstanceDefault(code int) *GetWorkloadInstanceDefault

NewGetWorkloadInstanceDefault creates a GetWorkloadInstanceDefault with default headers values

func (*GetWorkloadInstanceDefault) Code

func (o *GetWorkloadInstanceDefault) Code() int

Code gets the status code for the get workload instance default response

func (*GetWorkloadInstanceDefault) Error

func (*GetWorkloadInstanceDefault) GetPayload

type GetWorkloadInstanceInternalServerError

type GetWorkloadInstanceInternalServerError struct {
	Payload *workload_models.StackpathapiStatus
}

GetWorkloadInstanceInternalServerError handles this case with default header values.

Internal server error.

func NewGetWorkloadInstanceInternalServerError

func NewGetWorkloadInstanceInternalServerError() *GetWorkloadInstanceInternalServerError

NewGetWorkloadInstanceInternalServerError creates a GetWorkloadInstanceInternalServerError with default headers values

func (*GetWorkloadInstanceInternalServerError) Error

func (*GetWorkloadInstanceInternalServerError) GetPayload

type GetWorkloadInstanceOK

type GetWorkloadInstanceOK struct {
	Payload *workload_models.V1GetWorkloadInstanceResponse
}

GetWorkloadInstanceOK handles this case with default header values.

GetWorkloadInstanceOK get workload instance o k

func NewGetWorkloadInstanceOK

func NewGetWorkloadInstanceOK() *GetWorkloadInstanceOK

NewGetWorkloadInstanceOK creates a GetWorkloadInstanceOK with default headers values

func (*GetWorkloadInstanceOK) Error

func (o *GetWorkloadInstanceOK) Error() string

func (*GetWorkloadInstanceOK) GetPayload

type GetWorkloadInstanceParams

type GetWorkloadInstanceParams struct {

	/*InstanceName
	  The name of the instance to retrieve

	*/
	InstanceName string
	/*StackID
	  The ID of the stack containing the workload whose instance to retrieve

	*/
	StackID string
	/*WorkloadID
	  The ID of the workload whose instance to retrieve

	*/
	WorkloadID string

	Context    context.Context
	HTTPClient *http.Client
	// contains filtered or unexported fields
}

GetWorkloadInstanceParams contains all the parameters to send to the API endpoint for the get workload instance operation typically these are written to a http.Request

func NewGetWorkloadInstanceParams

func NewGetWorkloadInstanceParams() *GetWorkloadInstanceParams

NewGetWorkloadInstanceParams creates a new GetWorkloadInstanceParams object with the default values initialized.

func NewGetWorkloadInstanceParamsWithContext

func NewGetWorkloadInstanceParamsWithContext(ctx context.Context) *GetWorkloadInstanceParams

NewGetWorkloadInstanceParamsWithContext creates a new GetWorkloadInstanceParams object with the default values initialized, and the ability to set a context for a request

func NewGetWorkloadInstanceParamsWithHTTPClient

func NewGetWorkloadInstanceParamsWithHTTPClient(client *http.Client) *GetWorkloadInstanceParams

NewGetWorkloadInstanceParamsWithHTTPClient creates a new GetWorkloadInstanceParams object with the default values initialized, and the ability to set a custom HTTPClient for a request

func NewGetWorkloadInstanceParamsWithTimeout

func NewGetWorkloadInstanceParamsWithTimeout(timeout time.Duration) *GetWorkloadInstanceParams

NewGetWorkloadInstanceParamsWithTimeout creates a new GetWorkloadInstanceParams object with the default values initialized, and the ability to set a timeout on a request

func (*GetWorkloadInstanceParams) SetContext

func (o *GetWorkloadInstanceParams) SetContext(ctx context.Context)

SetContext adds the context to the get workload instance params

func (*GetWorkloadInstanceParams) SetHTTPClient

func (o *GetWorkloadInstanceParams) SetHTTPClient(client *http.Client)

SetHTTPClient adds the HTTPClient to the get workload instance params

func (*GetWorkloadInstanceParams) SetInstanceName

func (o *GetWorkloadInstanceParams) SetInstanceName(instanceName string)

SetInstanceName adds the instanceName to the get workload instance params

func (*GetWorkloadInstanceParams) SetStackID

func (o *GetWorkloadInstanceParams) SetStackID(stackID string)

SetStackID adds the stackId to the get workload instance params

func (*GetWorkloadInstanceParams) SetTimeout

func (o *GetWorkloadInstanceParams) SetTimeout(timeout time.Duration)

SetTimeout adds the timeout to the get workload instance params

func (*GetWorkloadInstanceParams) SetWorkloadID

func (o *GetWorkloadInstanceParams) SetWorkloadID(workloadID string)

SetWorkloadID adds the workloadId to the get workload instance params

func (*GetWorkloadInstanceParams) WithContext

WithContext adds the context to the get workload instance params

func (*GetWorkloadInstanceParams) WithHTTPClient

func (o *GetWorkloadInstanceParams) WithHTTPClient(client *http.Client) *GetWorkloadInstanceParams

WithHTTPClient adds the HTTPClient to the get workload instance params

func (*GetWorkloadInstanceParams) WithInstanceName

func (o *GetWorkloadInstanceParams) WithInstanceName(instanceName string) *GetWorkloadInstanceParams

WithInstanceName adds the instanceName to the get workload instance params

func (*GetWorkloadInstanceParams) WithStackID

WithStackID adds the stackID to the get workload instance params

func (*GetWorkloadInstanceParams) WithTimeout

WithTimeout adds the timeout to the get workload instance params

func (*GetWorkloadInstanceParams) WithWorkloadID

func (o *GetWorkloadInstanceParams) WithWorkloadID(workloadID string) *GetWorkloadInstanceParams

WithWorkloadID adds the workloadID to the get workload instance params

func (*GetWorkloadInstanceParams) WriteToRequest

WriteToRequest writes these params to a swagger request

type GetWorkloadInstanceReader

type GetWorkloadInstanceReader struct {
	// contains filtered or unexported fields
}

GetWorkloadInstanceReader is a Reader for the GetWorkloadInstance structure.

func (*GetWorkloadInstanceReader) ReadResponse

func (o *GetWorkloadInstanceReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error)

ReadResponse reads a server response into the received o.

type GetWorkloadInstanceUnauthorized

type GetWorkloadInstanceUnauthorized struct {
	Payload *workload_models.StackpathapiStatus
}

GetWorkloadInstanceUnauthorized handles this case with default header values.

Returned when an unauthorized request is attempted.

func NewGetWorkloadInstanceUnauthorized

func NewGetWorkloadInstanceUnauthorized() *GetWorkloadInstanceUnauthorized

NewGetWorkloadInstanceUnauthorized creates a GetWorkloadInstanceUnauthorized with default headers values

func (*GetWorkloadInstanceUnauthorized) Error

func (*GetWorkloadInstanceUnauthorized) GetPayload

type RestartInstanceDefault

type RestartInstanceDefault struct {
	Payload *workload_models.StackpathapiStatus
	// contains filtered or unexported fields
}

RestartInstanceDefault handles this case with default header values.

Default error structure.

func NewRestartInstanceDefault

func NewRestartInstanceDefault(code int) *RestartInstanceDefault

NewRestartInstanceDefault creates a RestartInstanceDefault with default headers values

func (*RestartInstanceDefault) Code

func (o *RestartInstanceDefault) Code() int

Code gets the status code for the restart instance default response

func (*RestartInstanceDefault) Error

func (o *RestartInstanceDefault) Error() string

func (*RestartInstanceDefault) GetPayload

type RestartInstanceInternalServerError

type RestartInstanceInternalServerError struct {
	Payload *workload_models.StackpathapiStatus
}

RestartInstanceInternalServerError handles this case with default header values.

Internal server error.

func NewRestartInstanceInternalServerError

func NewRestartInstanceInternalServerError() *RestartInstanceInternalServerError

NewRestartInstanceInternalServerError creates a RestartInstanceInternalServerError with default headers values

func (*RestartInstanceInternalServerError) Error

func (*RestartInstanceInternalServerError) GetPayload

type RestartInstanceNoContent

type RestartInstanceNoContent struct {
}

RestartInstanceNoContent handles this case with default header values.

No content

func NewRestartInstanceNoContent

func NewRestartInstanceNoContent() *RestartInstanceNoContent

NewRestartInstanceNoContent creates a RestartInstanceNoContent with default headers values

func (*RestartInstanceNoContent) Error

func (o *RestartInstanceNoContent) Error() string

type RestartInstanceParams

type RestartInstanceParams struct {

	/*InstanceName*/
	InstanceName string
	/*StackID*/
	StackID string
	/*WorkloadID*/
	WorkloadID string

	Context    context.Context
	HTTPClient *http.Client
	// contains filtered or unexported fields
}

RestartInstanceParams contains all the parameters to send to the API endpoint for the restart instance operation typically these are written to a http.Request

func NewRestartInstanceParams

func NewRestartInstanceParams() *RestartInstanceParams

NewRestartInstanceParams creates a new RestartInstanceParams object with the default values initialized.

func NewRestartInstanceParamsWithContext

func NewRestartInstanceParamsWithContext(ctx context.Context) *RestartInstanceParams

NewRestartInstanceParamsWithContext creates a new RestartInstanceParams object with the default values initialized, and the ability to set a context for a request

func NewRestartInstanceParamsWithHTTPClient

func NewRestartInstanceParamsWithHTTPClient(client *http.Client) *RestartInstanceParams

NewRestartInstanceParamsWithHTTPClient creates a new RestartInstanceParams object with the default values initialized, and the ability to set a custom HTTPClient for a request

func NewRestartInstanceParamsWithTimeout

func NewRestartInstanceParamsWithTimeout(timeout time.Duration) *RestartInstanceParams

NewRestartInstanceParamsWithTimeout creates a new RestartInstanceParams object with the default values initialized, and the ability to set a timeout on a request

func (*RestartInstanceParams) SetContext

func (o *RestartInstanceParams) SetContext(ctx context.Context)

SetContext adds the context to the restart instance params

func (*RestartInstanceParams) SetHTTPClient

func (o *RestartInstanceParams) SetHTTPClient(client *http.Client)

SetHTTPClient adds the HTTPClient to the restart instance params

func (*RestartInstanceParams) SetInstanceName

func (o *RestartInstanceParams) SetInstanceName(instanceName string)

SetInstanceName adds the instanceName to the restart instance params

func (*RestartInstanceParams) SetStackID

func (o *RestartInstanceParams) SetStackID(stackID string)

SetStackID adds the stackId to the restart instance params

func (*RestartInstanceParams) SetTimeout

func (o *RestartInstanceParams) SetTimeout(timeout time.Duration)

SetTimeout adds the timeout to the restart instance params

func (*RestartInstanceParams) SetWorkloadID

func (o *RestartInstanceParams) SetWorkloadID(workloadID string)

SetWorkloadID adds the workloadId to the restart instance params

func (*RestartInstanceParams) WithContext

WithContext adds the context to the restart instance params

func (*RestartInstanceParams) WithHTTPClient

func (o *RestartInstanceParams) WithHTTPClient(client *http.Client) *RestartInstanceParams

WithHTTPClient adds the HTTPClient to the restart instance params

func (*RestartInstanceParams) WithInstanceName

func (o *RestartInstanceParams) WithInstanceName(instanceName string) *RestartInstanceParams

WithInstanceName adds the instanceName to the restart instance params

func (*RestartInstanceParams) WithStackID

func (o *RestartInstanceParams) WithStackID(stackID string) *RestartInstanceParams

WithStackID adds the stackID to the restart instance params

func (*RestartInstanceParams) WithTimeout

func (o *RestartInstanceParams) WithTimeout(timeout time.Duration) *RestartInstanceParams

WithTimeout adds the timeout to the restart instance params

func (*RestartInstanceParams) WithWorkloadID

func (o *RestartInstanceParams) WithWorkloadID(workloadID string) *RestartInstanceParams

WithWorkloadID adds the workloadID to the restart instance params

func (*RestartInstanceParams) WriteToRequest

func (o *RestartInstanceParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error

WriteToRequest writes these params to a swagger request

type RestartInstanceReader

type RestartInstanceReader struct {
	// contains filtered or unexported fields
}

RestartInstanceReader is a Reader for the RestartInstance structure.

func (*RestartInstanceReader) ReadResponse

func (o *RestartInstanceReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error)

ReadResponse reads a server response into the received o.

type RestartInstanceUnauthorized

type RestartInstanceUnauthorized struct {
	Payload *workload_models.StackpathapiStatus
}

RestartInstanceUnauthorized handles this case with default header values.

Returned when an unauthorized request is attempted.

func NewRestartInstanceUnauthorized

func NewRestartInstanceUnauthorized() *RestartInstanceUnauthorized

NewRestartInstanceUnauthorized creates a RestartInstanceUnauthorized with default headers values

func (*RestartInstanceUnauthorized) Error

func (*RestartInstanceUnauthorized) GetPayload

Jump to

Keyboard shortcuts

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