events

package
v0.1.24 Latest Latest
Warning

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

Go to latest
Published: Sep 7, 2018 License: Apache-2.0 Imports: 11 Imported by: 12

Documentation

Index

Constants

View Source
const EmitEventBadRequestCode int = 400

EmitEventBadRequestCode is the HTTP code returned for type EmitEventBadRequest

View Source
const EmitEventForbiddenCode int = 403

EmitEventForbiddenCode is the HTTP code returned for type EmitEventForbidden

View Source
const EmitEventOKCode int = 200

EmitEventOKCode is the HTTP code returned for type EmitEventOK

View Source
const EmitEventUnauthorizedCode int = 401

EmitEventUnauthorizedCode is the HTTP code returned for type EmitEventUnauthorized

Variables

This section is empty.

Functions

This section is empty.

Types

type EmitEvent

type EmitEvent struct {
	Context *middleware.Context
	Handler EmitEventHandler
}

EmitEvent swagger:route POST / events emitEvent

Emit an event

func NewEmitEvent

func NewEmitEvent(ctx *middleware.Context, handler EmitEventHandler) *EmitEvent

NewEmitEvent creates a new http.Handler for the emit event operation

func (*EmitEvent) ServeHTTP

func (o *EmitEvent) ServeHTTP(rw http.ResponseWriter, r *http.Request)

type EmitEventBadRequest

type EmitEventBadRequest struct {

	/*
	  In: Body
	*/
	Payload *v1.Error `json:"body,omitempty"`
}

EmitEventBadRequest Invalid input

swagger:response emitEventBadRequest

func NewEmitEventBadRequest

func NewEmitEventBadRequest() *EmitEventBadRequest

NewEmitEventBadRequest creates EmitEventBadRequest with default headers values

func (*EmitEventBadRequest) SetPayload

func (o *EmitEventBadRequest) SetPayload(payload *v1.Error)

SetPayload sets the payload to the emit event bad request response

func (*EmitEventBadRequest) WithPayload

func (o *EmitEventBadRequest) WithPayload(payload *v1.Error) *EmitEventBadRequest

WithPayload adds the payload to the emit event bad request response

func (*EmitEventBadRequest) WriteResponse

func (o *EmitEventBadRequest) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)

WriteResponse to the client

type EmitEventDefault

type EmitEventDefault struct {

	/*
	  In: Body
	*/
	Payload *v1.Error `json:"body,omitempty"`
	// contains filtered or unexported fields
}

EmitEventDefault Unknown error

swagger:response emitEventDefault

func NewEmitEventDefault

func NewEmitEventDefault(code int) *EmitEventDefault

NewEmitEventDefault creates EmitEventDefault with default headers values

func (*EmitEventDefault) SetPayload

func (o *EmitEventDefault) SetPayload(payload *v1.Error)

SetPayload sets the payload to the emit event default response

func (*EmitEventDefault) SetStatusCode

func (o *EmitEventDefault) SetStatusCode(code int)

SetStatusCode sets the status to the emit event default response

func (*EmitEventDefault) WithPayload

func (o *EmitEventDefault) WithPayload(payload *v1.Error) *EmitEventDefault

WithPayload adds the payload to the emit event default response

func (*EmitEventDefault) WithStatusCode

func (o *EmitEventDefault) WithStatusCode(code int) *EmitEventDefault

WithStatusCode adds the status to the emit event default response

func (*EmitEventDefault) WriteResponse

func (o *EmitEventDefault) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)

WriteResponse to the client

type EmitEventForbidden added in v0.1.18

type EmitEventForbidden struct {

	/*
	  In: Body
	*/
	Payload *v1.Error `json:"body,omitempty"`
}

EmitEventForbidden access to this resource is forbidden

swagger:response emitEventForbidden

func NewEmitEventForbidden added in v0.1.18

func NewEmitEventForbidden() *EmitEventForbidden

NewEmitEventForbidden creates EmitEventForbidden with default headers values

func (*EmitEventForbidden) SetPayload added in v0.1.18

func (o *EmitEventForbidden) SetPayload(payload *v1.Error)

SetPayload sets the payload to the emit event forbidden response

func (*EmitEventForbidden) WithPayload added in v0.1.18

func (o *EmitEventForbidden) WithPayload(payload *v1.Error) *EmitEventForbidden

WithPayload adds the payload to the emit event forbidden response

func (*EmitEventForbidden) WriteResponse added in v0.1.18

func (o *EmitEventForbidden) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)

WriteResponse to the client

type EmitEventHandler

type EmitEventHandler interface {
	Handle(EmitEventParams, interface{}) middleware.Responder
}

EmitEventHandler interface for that can handle valid emit event params

type EmitEventHandlerFunc

type EmitEventHandlerFunc func(EmitEventParams, interface{}) middleware.Responder

EmitEventHandlerFunc turns a function with the right signature into a emit event handler

func (EmitEventHandlerFunc) Handle

func (fn EmitEventHandlerFunc) Handle(params EmitEventParams, principal interface{}) middleware.Responder

Handle executing the request and returning a response

type EmitEventOK

type EmitEventOK struct {

	/*
	  In: Body
	*/
	Payload *v1.Emission `json:"body,omitempty"`
}

EmitEventOK Event emitted

swagger:response emitEventOK

func NewEmitEventOK

func NewEmitEventOK() *EmitEventOK

NewEmitEventOK creates EmitEventOK with default headers values

func (*EmitEventOK) SetPayload

func (o *EmitEventOK) SetPayload(payload *v1.Emission)

SetPayload sets the payload to the emit event o k response

func (*EmitEventOK) WithPayload

func (o *EmitEventOK) WithPayload(payload *v1.Emission) *EmitEventOK

WithPayload adds the payload to the emit event o k response

func (*EmitEventOK) WriteResponse

func (o *EmitEventOK) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)

WriteResponse to the client

type EmitEventParams

type EmitEventParams struct {

	// HTTP Request Object
	HTTPRequest *http.Request `json:"-"`

	/*
	  Required: true
	  In: header
	*/
	XDispatchOrg string
	/*emission object
	  Required: true
	  In: body
	*/
	Body *v1.Emission
}

EmitEventParams contains all the bound params for the emit event operation typically these are obtained from a http.Request

swagger:parameters emitEvent

func NewEmitEventParams

func NewEmitEventParams() EmitEventParams

NewEmitEventParams creates a new EmitEventParams object no default values defined in spec.

func (*EmitEventParams) BindRequest

func (o *EmitEventParams) BindRequest(r *http.Request, route *middleware.MatchedRoute) error

BindRequest both binds and validates a request, it assumes that complex things implement a Validatable(strfmt.Registry) error interface for simple values it will use straight method calls.

To ensure default values, the struct must have been initialized with NewEmitEventParams() beforehand.

type EmitEventURL

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

EmitEventURL generates an URL for the emit event operation

func (*EmitEventURL) Build

func (o *EmitEventURL) Build() (*url.URL, error)

Build a url path and query string

func (*EmitEventURL) BuildFull

func (o *EmitEventURL) BuildFull(scheme, host string) (*url.URL, error)

BuildFull builds a full url with scheme, host, path and query string

func (*EmitEventURL) Must

func (o *EmitEventURL) Must(u *url.URL, err error) *url.URL

Must is a helper function to panic when the url builder returns an error

func (*EmitEventURL) SetBasePath

func (o *EmitEventURL) SetBasePath(bp string)

SetBasePath sets the base path for this url builder, only required when it's different from the base path specified in the swagger spec. When the value of the base path is an empty string

func (*EmitEventURL) String

func (o *EmitEventURL) String() string

String returns the string representation of the path with query string

func (*EmitEventURL) StringFull

func (o *EmitEventURL) StringFull(scheme, host string) string

StringFull returns the string representation of a complete url

func (*EmitEventURL) WithBasePath

func (o *EmitEventURL) WithBasePath(bp string) *EmitEventURL

WithBasePath sets the base path for this url builder, only required when it's different from the base path specified in the swagger spec. When the value of the base path is an empty string

type EmitEventUnauthorized

type EmitEventUnauthorized struct {

	/*
	  In: Body
	*/
	Payload *v1.Error `json:"body,omitempty"`
}

EmitEventUnauthorized Unauthorized Request

swagger:response emitEventUnauthorized

func NewEmitEventUnauthorized

func NewEmitEventUnauthorized() *EmitEventUnauthorized

NewEmitEventUnauthorized creates EmitEventUnauthorized with default headers values

func (*EmitEventUnauthorized) SetPayload

func (o *EmitEventUnauthorized) SetPayload(payload *v1.Error)

SetPayload sets the payload to the emit event unauthorized response

func (*EmitEventUnauthorized) WithPayload

func (o *EmitEventUnauthorized) WithPayload(payload *v1.Error) *EmitEventUnauthorized

WithPayload adds the payload to the emit event unauthorized response

func (*EmitEventUnauthorized) WriteResponse

func (o *EmitEventUnauthorized) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)

WriteResponse to the client

Jump to

Keyboard shortcuts

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