alerts

package
v1.5.0 Latest Latest
Warning

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

Go to latest
Published: Nov 23, 2017 License: AGPL-3.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 alerts API

func New

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

New creates a new alerts API client.

func (*Client) Get

func (a *Client) Get(params *GetParams) (*GetOK, error)

Get gets returns an alert rule by name

func (*Client) List

func (a *Client) List(params *ListParams) (*ListOK, error)

List lists returns all alert rules

func (*Client) SetTransport

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

SetTransport changes the transport on the client

type GetOK

type GetOK struct {
	Payload *models.APIAlertsGetResponse
}

GetOK handles this case with default header values.

(empty)

func NewGetOK

func NewGetOK() *GetOK

NewGetOK creates a GetOK with default headers values

func (*GetOK) Error

func (o *GetOK) Error() string

type GetParams

type GetParams struct {

	/*Name*/
	Name string

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

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

func NewGetParams

func NewGetParams() *GetParams

NewGetParams creates a new GetParams object with the default values initialized.

func NewGetParamsWithContext

func NewGetParamsWithContext(ctx context.Context) *GetParams

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

func NewGetParamsWithHTTPClient

func NewGetParamsWithHTTPClient(client *http.Client) *GetParams

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

func NewGetParamsWithTimeout

func NewGetParamsWithTimeout(timeout time.Duration) *GetParams

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

func (*GetParams) SetContext

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

SetContext adds the context to the get params

func (*GetParams) SetHTTPClient

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

SetHTTPClient adds the HTTPClient to the get params

func (*GetParams) SetName

func (o *GetParams) SetName(name string)

SetName adds the name to the get params

func (*GetParams) SetTimeout

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

SetTimeout adds the timeout to the get params

func (*GetParams) WithContext

func (o *GetParams) WithContext(ctx context.Context) *GetParams

WithContext adds the context to the get params

func (*GetParams) WithHTTPClient

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

WithHTTPClient adds the HTTPClient to the get params

func (*GetParams) WithName

func (o *GetParams) WithName(name string) *GetParams

WithName adds the name to the get params

func (*GetParams) WithTimeout

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

WithTimeout adds the timeout to the get params

func (*GetParams) WriteToRequest

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

WriteToRequest writes these params to a swagger request

type GetReader

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

GetReader is a Reader for the Get structure.

func (*GetReader) ReadResponse

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

ReadResponse reads a server response into the received o.

type ListOK

type ListOK struct {
	Payload *models.APIAlertsListResponse
}

ListOK handles this case with default header values.

(empty)

func NewListOK

func NewListOK() *ListOK

NewListOK creates a ListOK with default headers values

func (*ListOK) Error

func (o *ListOK) Error() string

type ListParams

type ListParams struct {
	Context    context.Context
	HTTPClient *http.Client
	// contains filtered or unexported fields
}

ListParams contains all the parameters to send to the API endpoint for the list operation typically these are written to a http.Request

func NewListParams

func NewListParams() *ListParams

NewListParams creates a new ListParams object with the default values initialized.

func NewListParamsWithContext

func NewListParamsWithContext(ctx context.Context) *ListParams

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

func NewListParamsWithHTTPClient

func NewListParamsWithHTTPClient(client *http.Client) *ListParams

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

func NewListParamsWithTimeout

func NewListParamsWithTimeout(timeout time.Duration) *ListParams

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

func (*ListParams) SetContext

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

SetContext adds the context to the list params

func (*ListParams) SetHTTPClient

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

SetHTTPClient adds the HTTPClient to the list params

func (*ListParams) SetTimeout

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

SetTimeout adds the timeout to the list params

func (*ListParams) WithContext

func (o *ListParams) WithContext(ctx context.Context) *ListParams

WithContext adds the context to the list params

func (*ListParams) WithHTTPClient

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

WithHTTPClient adds the HTTPClient to the list params

func (*ListParams) WithTimeout

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

WithTimeout adds the timeout to the list params

func (*ListParams) WriteToRequest

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

WriteToRequest writes these params to a swagger request

type ListReader

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

ListReader is a Reader for the List structure.

func (*ListReader) ReadResponse

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

ReadResponse reads a server response into the received o.

Jump to

Keyboard shortcuts

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