operations

package
v0.0.0-...-d6813a9 Latest Latest
Warning

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

Go to latest
Published: Oct 5, 2020 License: Apache-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 operations API

func (*Client) DescribeDevices

func (a *Client) DescribeDevices(params *DescribeDevicesParams) (*DescribeDevicesOK, error)

DescribeDevices returns the list of devices

func (*Client) GetDeviceByID

func (a *Client) GetDeviceByID(params *GetDeviceByIDParams) (*GetDeviceByIDOK, error)

GetDeviceByID returns device by device ID

func (*Client) SetDeviceStateByID

func (a *Client) SetDeviceStateByID(params *SetDeviceStateByIDParams) (*SetDeviceStateByIDOK, error)

SetDeviceStateByID sets the state of device given device ID

func (*Client) SetTransport

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

SetTransport changes the transport on the client

type ClientService

type ClientService interface {
	DescribeDevices(params *DescribeDevicesParams) (*DescribeDevicesOK, error)

	GetDeviceByID(params *GetDeviceByIDParams) (*GetDeviceByIDOK, error)

	SetDeviceStateByID(params *SetDeviceStateByIDParams) (*SetDeviceStateByIDOK, 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 operations API client.

type DescribeDevicesDefault

type DescribeDevicesDefault struct {
	Payload *models.Error
	// contains filtered or unexported fields
}

DescribeDevicesDefault handles this case with default header values.

Internal Server Error

func NewDescribeDevicesDefault

func NewDescribeDevicesDefault(code int) *DescribeDevicesDefault

NewDescribeDevicesDefault creates a DescribeDevicesDefault with default headers values

func (*DescribeDevicesDefault) Code

func (o *DescribeDevicesDefault) Code() int

Code gets the status code for the describe devices default response

func (*DescribeDevicesDefault) Error

func (o *DescribeDevicesDefault) Error() string

func (*DescribeDevicesDefault) GetPayload

func (o *DescribeDevicesDefault) GetPayload() *models.Error

type DescribeDevicesOK

type DescribeDevicesOK struct {
	Payload models.Devices
}

DescribeDevicesOK handles this case with default header values.

The device list

func NewDescribeDevicesOK

func NewDescribeDevicesOK() *DescribeDevicesOK

NewDescribeDevicesOK creates a DescribeDevicesOK with default headers values

func (*DescribeDevicesOK) Error

func (o *DescribeDevicesOK) Error() string

func (*DescribeDevicesOK) GetPayload

func (o *DescribeDevicesOK) GetPayload() models.Devices

type DescribeDevicesParams

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

DescribeDevicesParams contains all the parameters to send to the API endpoint for the describe devices operation typically these are written to a http.Request

func NewDescribeDevicesParams

func NewDescribeDevicesParams() *DescribeDevicesParams

NewDescribeDevicesParams creates a new DescribeDevicesParams object with the default values initialized.

func NewDescribeDevicesParamsWithContext

func NewDescribeDevicesParamsWithContext(ctx context.Context) *DescribeDevicesParams

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

func NewDescribeDevicesParamsWithHTTPClient

func NewDescribeDevicesParamsWithHTTPClient(client *http.Client) *DescribeDevicesParams

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

func NewDescribeDevicesParamsWithTimeout

func NewDescribeDevicesParamsWithTimeout(timeout time.Duration) *DescribeDevicesParams

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

func (*DescribeDevicesParams) SetContext

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

SetContext adds the context to the describe devices params

func (*DescribeDevicesParams) SetHTTPClient

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

SetHTTPClient adds the HTTPClient to the describe devices params

func (*DescribeDevicesParams) SetTimeout

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

SetTimeout adds the timeout to the describe devices params

func (*DescribeDevicesParams) WithContext

WithContext adds the context to the describe devices params

func (*DescribeDevicesParams) WithHTTPClient

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

WithHTTPClient adds the HTTPClient to the describe devices params

func (*DescribeDevicesParams) WithTimeout

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

WithTimeout adds the timeout to the describe devices params

func (*DescribeDevicesParams) WriteToRequest

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

WriteToRequest writes these params to a swagger request

type DescribeDevicesReader

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

DescribeDevicesReader is a Reader for the DescribeDevices structure.

func (*DescribeDevicesReader) ReadResponse

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

ReadResponse reads a server response into the received o.

type GetDeviceByIDDefault

type GetDeviceByIDDefault struct {
	Payload *models.Error
	// contains filtered or unexported fields
}

GetDeviceByIDDefault handles this case with default header values.

Internal Server Error

func NewGetDeviceByIDDefault

func NewGetDeviceByIDDefault(code int) *GetDeviceByIDDefault

NewGetDeviceByIDDefault creates a GetDeviceByIDDefault with default headers values

func (*GetDeviceByIDDefault) Code

func (o *GetDeviceByIDDefault) Code() int

Code gets the status code for the get device by Id default response

func (*GetDeviceByIDDefault) Error

func (o *GetDeviceByIDDefault) Error() string

func (*GetDeviceByIDDefault) GetPayload

func (o *GetDeviceByIDDefault) GetPayload() *models.Error

type GetDeviceByIDNotFound

type GetDeviceByIDNotFound struct {
}

GetDeviceByIDNotFound handles this case with default header values.

Device not found

func NewGetDeviceByIDNotFound

func NewGetDeviceByIDNotFound() *GetDeviceByIDNotFound

NewGetDeviceByIDNotFound creates a GetDeviceByIDNotFound with default headers values

func (*GetDeviceByIDNotFound) Error

func (o *GetDeviceByIDNotFound) Error() string

type GetDeviceByIDOK

type GetDeviceByIDOK struct {
	Payload *models.Device
}

GetDeviceByIDOK handles this case with default header values.

successful operation

func NewGetDeviceByIDOK

func NewGetDeviceByIDOK() *GetDeviceByIDOK

NewGetDeviceByIDOK creates a GetDeviceByIDOK with default headers values

func (*GetDeviceByIDOK) Error

func (o *GetDeviceByIDOK) Error() string

func (*GetDeviceByIDOK) GetPayload

func (o *GetDeviceByIDOK) GetPayload() *models.Device

type GetDeviceByIDParams

type GetDeviceByIDParams struct {

	/*DeviceID
	  ID of the device

	*/
	DeviceID string

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

GetDeviceByIDParams contains all the parameters to send to the API endpoint for the get device by Id operation typically these are written to a http.Request

func NewGetDeviceByIDParams

func NewGetDeviceByIDParams() *GetDeviceByIDParams

NewGetDeviceByIDParams creates a new GetDeviceByIDParams object with the default values initialized.

func NewGetDeviceByIDParamsWithContext

func NewGetDeviceByIDParamsWithContext(ctx context.Context) *GetDeviceByIDParams

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

func NewGetDeviceByIDParamsWithHTTPClient

func NewGetDeviceByIDParamsWithHTTPClient(client *http.Client) *GetDeviceByIDParams

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

func NewGetDeviceByIDParamsWithTimeout

func NewGetDeviceByIDParamsWithTimeout(timeout time.Duration) *GetDeviceByIDParams

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

func (*GetDeviceByIDParams) SetContext

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

SetContext adds the context to the get device by Id params

func (*GetDeviceByIDParams) SetDeviceID

func (o *GetDeviceByIDParams) SetDeviceID(deviceID string)

SetDeviceID adds the deviceId to the get device by Id params

func (*GetDeviceByIDParams) SetHTTPClient

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

SetHTTPClient adds the HTTPClient to the get device by Id params

func (*GetDeviceByIDParams) SetTimeout

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

SetTimeout adds the timeout to the get device by Id params

func (*GetDeviceByIDParams) WithContext

WithContext adds the context to the get device by Id params

func (*GetDeviceByIDParams) WithDeviceID

func (o *GetDeviceByIDParams) WithDeviceID(deviceID string) *GetDeviceByIDParams

WithDeviceID adds the deviceID to the get device by Id params

func (*GetDeviceByIDParams) WithHTTPClient

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

WithHTTPClient adds the HTTPClient to the get device by Id params

func (*GetDeviceByIDParams) WithTimeout

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

WithTimeout adds the timeout to the get device by Id params

func (*GetDeviceByIDParams) WriteToRequest

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

WriteToRequest writes these params to a swagger request

type GetDeviceByIDReader

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

GetDeviceByIDReader is a Reader for the GetDeviceByID structure.

func (*GetDeviceByIDReader) ReadResponse

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

ReadResponse reads a server response into the received o.

type SetDeviceStateByIDDefault

type SetDeviceStateByIDDefault struct {
	Payload *models.Error
	// contains filtered or unexported fields
}

SetDeviceStateByIDDefault handles this case with default header values.

Internal Server Error

func NewSetDeviceStateByIDDefault

func NewSetDeviceStateByIDDefault(code int) *SetDeviceStateByIDDefault

NewSetDeviceStateByIDDefault creates a SetDeviceStateByIDDefault with default headers values

func (*SetDeviceStateByIDDefault) Code

func (o *SetDeviceStateByIDDefault) Code() int

Code gets the status code for the set device state by Id default response

func (*SetDeviceStateByIDDefault) Error

func (o *SetDeviceStateByIDDefault) Error() string

func (*SetDeviceStateByIDDefault) GetPayload

func (o *SetDeviceStateByIDDefault) GetPayload() *models.Error

type SetDeviceStateByIDNotFound

type SetDeviceStateByIDNotFound struct {
}

SetDeviceStateByIDNotFound handles this case with default header values.

Device not found

func NewSetDeviceStateByIDNotFound

func NewSetDeviceStateByIDNotFound() *SetDeviceStateByIDNotFound

NewSetDeviceStateByIDNotFound creates a SetDeviceStateByIDNotFound with default headers values

func (*SetDeviceStateByIDNotFound) Error

type SetDeviceStateByIDOK

type SetDeviceStateByIDOK struct {
	Payload *models.Device
}

SetDeviceStateByIDOK handles this case with default header values.

successful operation

func NewSetDeviceStateByIDOK

func NewSetDeviceStateByIDOK() *SetDeviceStateByIDOK

NewSetDeviceStateByIDOK creates a SetDeviceStateByIDOK with default headers values

func (*SetDeviceStateByIDOK) Error

func (o *SetDeviceStateByIDOK) Error() string

func (*SetDeviceStateByIDOK) GetPayload

func (o *SetDeviceStateByIDOK) GetPayload() *models.Device

type SetDeviceStateByIDParams

type SetDeviceStateByIDParams struct {

	/*DeviceID
	  ID of the device

	*/
	DeviceID string
	/*State
	  The state of the device (on or off)

	*/
	State string

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

SetDeviceStateByIDParams contains all the parameters to send to the API endpoint for the set device state by Id operation typically these are written to a http.Request

func NewSetDeviceStateByIDParams

func NewSetDeviceStateByIDParams() *SetDeviceStateByIDParams

NewSetDeviceStateByIDParams creates a new SetDeviceStateByIDParams object with the default values initialized.

func NewSetDeviceStateByIDParamsWithContext

func NewSetDeviceStateByIDParamsWithContext(ctx context.Context) *SetDeviceStateByIDParams

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

func NewSetDeviceStateByIDParamsWithHTTPClient

func NewSetDeviceStateByIDParamsWithHTTPClient(client *http.Client) *SetDeviceStateByIDParams

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

func NewSetDeviceStateByIDParamsWithTimeout

func NewSetDeviceStateByIDParamsWithTimeout(timeout time.Duration) *SetDeviceStateByIDParams

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

func (*SetDeviceStateByIDParams) SetContext

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

SetContext adds the context to the set device state by Id params

func (*SetDeviceStateByIDParams) SetDeviceID

func (o *SetDeviceStateByIDParams) SetDeviceID(deviceID string)

SetDeviceID adds the deviceId to the set device state by Id params

func (*SetDeviceStateByIDParams) SetHTTPClient

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

SetHTTPClient adds the HTTPClient to the set device state by Id params

func (*SetDeviceStateByIDParams) SetState

func (o *SetDeviceStateByIDParams) SetState(state string)

SetState adds the state to the set device state by Id params

func (*SetDeviceStateByIDParams) SetTimeout

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

SetTimeout adds the timeout to the set device state by Id params

func (*SetDeviceStateByIDParams) WithContext

WithContext adds the context to the set device state by Id params

func (*SetDeviceStateByIDParams) WithDeviceID

func (o *SetDeviceStateByIDParams) WithDeviceID(deviceID string) *SetDeviceStateByIDParams

WithDeviceID adds the deviceID to the set device state by Id params

func (*SetDeviceStateByIDParams) WithHTTPClient

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

WithHTTPClient adds the HTTPClient to the set device state by Id params

func (*SetDeviceStateByIDParams) WithState

WithState adds the state to the set device state by Id params

func (*SetDeviceStateByIDParams) WithTimeout

WithTimeout adds the timeout to the set device state by Id params

func (*SetDeviceStateByIDParams) WriteToRequest

WriteToRequest writes these params to a swagger request

type SetDeviceStateByIDReader

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

SetDeviceStateByIDReader is a Reader for the SetDeviceStateByID structure.

func (*SetDeviceStateByIDReader) ReadResponse

func (o *SetDeviceStateByIDReader) 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