api

package
v0.0.0-...-216fc9e Latest Latest
Warning

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

Go to latest
Published: Dec 21, 2020 License: MIT Imports: 13 Imported by: 0

Documentation

Index

Constants

View Source
const TerseDeleteOKCode int = 200

TerseDeleteOKCode is the HTTP code returned for type TerseDeleteOK

View Source
const TerseDeleteOneOKCode int = 200

TerseDeleteOneOKCode is the HTTP code returned for type TerseDeleteOneOK

View Source
const TerseExportOKCode int = 200

TerseExportOKCode is the HTTP code returned for type TerseExportOK

View Source
const TerseExportOneOKCode int = 200

TerseExportOneOKCode is the HTTP code returned for type TerseExportOneOK

View Source
const TerseImportOKCode int = 200

TerseImportOKCode is the HTTP code returned for type TerseImportOK

View Source
const TerseTerseOKCode int = 200

TerseTerseOKCode is the HTTP code returned for type TerseTerseOK

View Source
const TerseVisitsOKCode int = 200

TerseVisitsOKCode is the HTTP code returned for type TerseVisitsOK

View Source
const TerseWriteOKCode int = 200

TerseWriteOKCode is the HTTP code returned for type TerseWriteOK

Variables

This section is empty.

Functions

This section is empty.

Types

type TerseDelete

type TerseDelete struct {
	Context *middleware.Context
	Handler TerseDeleteHandler
}

TerseDelete swagger:route DELETE /api/delete api terseDelete

Delete all Terse and or Visits data.

All Terse and or Visits data will be deleted according to the deletion information specified.

func NewTerseDelete

func NewTerseDelete(ctx *middleware.Context, handler TerseDeleteHandler) *TerseDelete

NewTerseDelete creates a new http.Handler for the terse delete operation

func (*TerseDelete) ServeHTTP

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

type TerseDeleteDefault

type TerseDeleteDefault struct {

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

TerseDeleteDefault Unexpected error.

swagger:response terseDeleteDefault

func NewTerseDeleteDefault

func NewTerseDeleteDefault(code int) *TerseDeleteDefault

NewTerseDeleteDefault creates TerseDeleteDefault with default headers values

func (*TerseDeleteDefault) SetPayload

func (o *TerseDeleteDefault) SetPayload(payload *models.Error)

SetPayload sets the payload to the terse delete default response

func (*TerseDeleteDefault) SetStatusCode

func (o *TerseDeleteDefault) SetStatusCode(code int)

SetStatusCode sets the status to the terse delete default response

func (*TerseDeleteDefault) WithPayload

func (o *TerseDeleteDefault) WithPayload(payload *models.Error) *TerseDeleteDefault

WithPayload adds the payload to the terse delete default response

func (*TerseDeleteDefault) WithStatusCode

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

WithStatusCode adds the status to the terse delete default response

func (*TerseDeleteDefault) WriteResponse

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

WriteResponse to the client

type TerseDeleteHandler

type TerseDeleteHandler interface {
	Handle(TerseDeleteParams) middleware.Responder
}

TerseDeleteHandler interface for that can handle valid terse delete params

type TerseDeleteHandlerFunc

type TerseDeleteHandlerFunc func(TerseDeleteParams) middleware.Responder

TerseDeleteHandlerFunc turns a function with the right signature into a terse delete handler

func (TerseDeleteHandlerFunc) Handle

Handle executing the request and returning a response

type TerseDeleteOK

type TerseDeleteOK struct {
}

TerseDeleteOK terse delete o k

swagger:response terseDeleteOK

func NewTerseDeleteOK

func NewTerseDeleteOK() *TerseDeleteOK

NewTerseDeleteOK creates TerseDeleteOK with default headers values

func (*TerseDeleteOK) WriteResponse

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

WriteResponse to the client

type TerseDeleteOne

type TerseDeleteOne struct {
	Context *middleware.Context
	Handler TerseDeleteOneHandler
}

TerseDeleteOne swagger:route DELETE /api/delete/{shortened} api terseDeleteOne

Delete Terse and or Visits data for the given shortened URL.

If only Terse data is deleted, the API user is responsible for cleaning up its Visits data before adding new Terse data under the same shortened URL.

func NewTerseDeleteOne

func NewTerseDeleteOne(ctx *middleware.Context, handler TerseDeleteOneHandler) *TerseDeleteOne

NewTerseDeleteOne creates a new http.Handler for the terse delete one operation

func (*TerseDeleteOne) ServeHTTP

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

type TerseDeleteOneDefault

type TerseDeleteOneDefault struct {

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

TerseDeleteOneDefault Unexpected error.

swagger:response terseDeleteOneDefault

func NewTerseDeleteOneDefault

func NewTerseDeleteOneDefault(code int) *TerseDeleteOneDefault

NewTerseDeleteOneDefault creates TerseDeleteOneDefault with default headers values

func (*TerseDeleteOneDefault) SetPayload

func (o *TerseDeleteOneDefault) SetPayload(payload *models.Error)

SetPayload sets the payload to the terse delete one default response

func (*TerseDeleteOneDefault) SetStatusCode

func (o *TerseDeleteOneDefault) SetStatusCode(code int)

SetStatusCode sets the status to the terse delete one default response

func (*TerseDeleteOneDefault) WithPayload

func (o *TerseDeleteOneDefault) WithPayload(payload *models.Error) *TerseDeleteOneDefault

WithPayload adds the payload to the terse delete one default response

func (*TerseDeleteOneDefault) WithStatusCode

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

WithStatusCode adds the status to the terse delete one default response

func (*TerseDeleteOneDefault) WriteResponse

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

WriteResponse to the client

type TerseDeleteOneHandler

type TerseDeleteOneHandler interface {
	Handle(TerseDeleteOneParams) middleware.Responder
}

TerseDeleteOneHandler interface for that can handle valid terse delete one params

type TerseDeleteOneHandlerFunc

type TerseDeleteOneHandlerFunc func(TerseDeleteOneParams) middleware.Responder

TerseDeleteOneHandlerFunc turns a function with the right signature into a terse delete one handler

func (TerseDeleteOneHandlerFunc) Handle

Handle executing the request and returning a response

type TerseDeleteOneOK

type TerseDeleteOneOK struct {
}

TerseDeleteOneOK The shortened URL's data was successfully deleted from the backend storage.

swagger:response terseDeleteOneOK

func NewTerseDeleteOneOK

func NewTerseDeleteOneOK() *TerseDeleteOneOK

NewTerseDeleteOneOK creates TerseDeleteOneOK with default headers values

func (*TerseDeleteOneOK) WriteResponse

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

WriteResponse to the client

type TerseDeleteOneParams

type TerseDeleteOneParams struct {

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

	/*Indicate if Terse and or Visits data should be deleted.
	  Required: true
	  In: body
	*/
	Delete *models.Delete
	/*The shortened URL whose data should be deleted.
	  Required: true
	  In: path
	*/
	Shortened string
}

TerseDeleteOneParams contains all the bound params for the terse delete one operation typically these are obtained from a http.Request

swagger:parameters terseDeleteOne

func NewTerseDeleteOneParams

func NewTerseDeleteOneParams() TerseDeleteOneParams

NewTerseDeleteOneParams creates a new TerseDeleteOneParams object no default values defined in spec.

func (*TerseDeleteOneParams) BindRequest

func (o *TerseDeleteOneParams) 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 NewTerseDeleteOneParams() beforehand.

type TerseDeleteOneURL

type TerseDeleteOneURL struct {
	Shortened string
	// contains filtered or unexported fields
}

TerseDeleteOneURL generates an URL for the terse delete one operation

func (*TerseDeleteOneURL) Build

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

Build a url path and query string

func (*TerseDeleteOneURL) BuildFull

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

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

func (*TerseDeleteOneURL) Must

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

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

func (*TerseDeleteOneURL) SetBasePath

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

func (o *TerseDeleteOneURL) String() string

String returns the string representation of the path with query string

func (*TerseDeleteOneURL) StringFull

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

StringFull returns the string representation of a complete url

func (*TerseDeleteOneURL) WithBasePath

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

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 TerseDeleteParams

type TerseDeleteParams struct {

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

	/*A JSON object containing the deletion information. If Terse or Visits data is marked for deletion, it will all be deleted.
	  Required: true
	  In: body
	*/
	Delete *models.Delete
}

TerseDeleteParams contains all the bound params for the terse delete operation typically these are obtained from a http.Request

swagger:parameters terseDelete

func NewTerseDeleteParams

func NewTerseDeleteParams() TerseDeleteParams

NewTerseDeleteParams creates a new TerseDeleteParams object no default values defined in spec.

func (*TerseDeleteParams) BindRequest

func (o *TerseDeleteParams) 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 NewTerseDeleteParams() beforehand.

type TerseDeleteURL

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

TerseDeleteURL generates an URL for the terse delete operation

func (*TerseDeleteURL) Build

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

Build a url path and query string

func (*TerseDeleteURL) BuildFull

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

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

func (*TerseDeleteURL) Must

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

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

func (*TerseDeleteURL) SetBasePath

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

func (o *TerseDeleteURL) String() string

String returns the string representation of the path with query string

func (*TerseDeleteURL) StringFull

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

StringFull returns the string representation of a complete url

func (*TerseDeleteURL) WithBasePath

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

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 TerseExport

type TerseExport struct {
	Context *middleware.Context
	Handler TerseExportHandler
}

TerseExport swagger:route GET /api/export api terseExport

Export all Terse and Visits data from the backend.

Depending on the underlying storage and amount of data, this may take a while.

func NewTerseExport

func NewTerseExport(ctx *middleware.Context, handler TerseExportHandler) *TerseExport

NewTerseExport creates a new http.Handler for the terse export operation

func (*TerseExport) ServeHTTP

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

type TerseExportDefault

type TerseExportDefault struct {

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

TerseExportDefault Unexpected error.

swagger:response terseExportDefault

func NewTerseExportDefault

func NewTerseExportDefault(code int) *TerseExportDefault

NewTerseExportDefault creates TerseExportDefault with default headers values

func (*TerseExportDefault) SetPayload

func (o *TerseExportDefault) SetPayload(payload *models.Error)

SetPayload sets the payload to the terse export default response

func (*TerseExportDefault) SetStatusCode

func (o *TerseExportDefault) SetStatusCode(code int)

SetStatusCode sets the status to the terse export default response

func (*TerseExportDefault) WithPayload

func (o *TerseExportDefault) WithPayload(payload *models.Error) *TerseExportDefault

WithPayload adds the payload to the terse export default response

func (*TerseExportDefault) WithStatusCode

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

WithStatusCode adds the status to the terse export default response

func (*TerseExportDefault) WriteResponse

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

WriteResponse to the client

type TerseExportHandler

type TerseExportHandler interface {
	Handle(TerseExportParams) middleware.Responder
}

TerseExportHandler interface for that can handle valid terse export params

type TerseExportHandlerFunc

type TerseExportHandlerFunc func(TerseExportParams) middleware.Responder

TerseExportHandlerFunc turns a function with the right signature into a terse export handler

func (TerseExportHandlerFunc) Handle

Handle executing the request and returning a response

type TerseExportOK

type TerseExportOK struct {

	/*All of the Terse and Visits data from the backend.
	  In: Body
	*/
	Payload map[string]models.Export `json:"body,omitempty"`
}

TerseExportOK The export was successfully retrieved.

swagger:response terseExportOK

func NewTerseExportOK

func NewTerseExportOK() *TerseExportOK

NewTerseExportOK creates TerseExportOK with default headers values

func (*TerseExportOK) SetPayload

func (o *TerseExportOK) SetPayload(payload map[string]models.Export)

SetPayload sets the payload to the terse export o k response

func (*TerseExportOK) WithPayload

func (o *TerseExportOK) WithPayload(payload map[string]models.Export) *TerseExportOK

WithPayload adds the payload to the terse export o k response

func (*TerseExportOK) WriteResponse

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

WriteResponse to the client

type TerseExportOne

type TerseExportOne struct {
	Context *middleware.Context
	Handler TerseExportOneHandler
}

TerseExportOne swagger:route GET /api/export/{shortened} api terseExportOne

Export Terse and Visits data for the given shortened URL.

func NewTerseExportOne

func NewTerseExportOne(ctx *middleware.Context, handler TerseExportOneHandler) *TerseExportOne

NewTerseExportOne creates a new http.Handler for the terse export one operation

func (*TerseExportOne) ServeHTTP

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

type TerseExportOneDefault

type TerseExportOneDefault struct {

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

TerseExportOneDefault Unexpected error.

swagger:response terseExportOneDefault

func NewTerseExportOneDefault

func NewTerseExportOneDefault(code int) *TerseExportOneDefault

NewTerseExportOneDefault creates TerseExportOneDefault with default headers values

func (*TerseExportOneDefault) SetPayload

func (o *TerseExportOneDefault) SetPayload(payload *models.Error)

SetPayload sets the payload to the terse export one default response

func (*TerseExportOneDefault) SetStatusCode

func (o *TerseExportOneDefault) SetStatusCode(code int)

SetStatusCode sets the status to the terse export one default response

func (*TerseExportOneDefault) WithPayload

func (o *TerseExportOneDefault) WithPayload(payload *models.Error) *TerseExportOneDefault

WithPayload adds the payload to the terse export one default response

func (*TerseExportOneDefault) WithStatusCode

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

WithStatusCode adds the status to the terse export one default response

func (*TerseExportOneDefault) WriteResponse

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

WriteResponse to the client

type TerseExportOneHandler

type TerseExportOneHandler interface {
	Handle(TerseExportOneParams) middleware.Responder
}

TerseExportOneHandler interface for that can handle valid terse export one params

type TerseExportOneHandlerFunc

type TerseExportOneHandlerFunc func(TerseExportOneParams) middleware.Responder

TerseExportOneHandlerFunc turns a function with the right signature into a terse export one handler

func (TerseExportOneHandlerFunc) Handle

Handle executing the request and returning a response

type TerseExportOneOK

type TerseExportOneOK struct {

	/*
	  In: Body
	*/
	Payload *models.Export `json:"body,omitempty"`
}

TerseExportOneOK The export was successfully retrieved.

swagger:response terseExportOneOK

func NewTerseExportOneOK

func NewTerseExportOneOK() *TerseExportOneOK

NewTerseExportOneOK creates TerseExportOneOK with default headers values

func (*TerseExportOneOK) SetPayload

func (o *TerseExportOneOK) SetPayload(payload *models.Export)

SetPayload sets the payload to the terse export one o k response

func (*TerseExportOneOK) WithPayload

func (o *TerseExportOneOK) WithPayload(payload *models.Export) *TerseExportOneOK

WithPayload adds the payload to the terse export one o k response

func (*TerseExportOneOK) WriteResponse

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

WriteResponse to the client

type TerseExportOneParams

type TerseExportOneParams struct {

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

	/*The shortened URL to get the export for.
	  Required: true
	  In: path
	*/
	Shortened string
}

TerseExportOneParams contains all the bound params for the terse export one operation typically these are obtained from a http.Request

swagger:parameters terseExportOne

func NewTerseExportOneParams

func NewTerseExportOneParams() TerseExportOneParams

NewTerseExportOneParams creates a new TerseExportOneParams object no default values defined in spec.

func (*TerseExportOneParams) BindRequest

func (o *TerseExportOneParams) 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 NewTerseExportOneParams() beforehand.

type TerseExportOneURL

type TerseExportOneURL struct {
	Shortened string
	// contains filtered or unexported fields
}

TerseExportOneURL generates an URL for the terse export one operation

func (*TerseExportOneURL) Build

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

Build a url path and query string

func (*TerseExportOneURL) BuildFull

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

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

func (*TerseExportOneURL) Must

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

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

func (*TerseExportOneURL) SetBasePath

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

func (o *TerseExportOneURL) String() string

String returns the string representation of the path with query string

func (*TerseExportOneURL) StringFull

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

StringFull returns the string representation of a complete url

func (*TerseExportOneURL) WithBasePath

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

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 TerseExportParams

type TerseExportParams struct {

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

TerseExportParams contains all the bound params for the terse export operation typically these are obtained from a http.Request

swagger:parameters terseExport

func NewTerseExportParams

func NewTerseExportParams() TerseExportParams

NewTerseExportParams creates a new TerseExportParams object no default values defined in spec.

func (*TerseExportParams) BindRequest

func (o *TerseExportParams) 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 NewTerseExportParams() beforehand.

type TerseExportURL

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

TerseExportURL generates an URL for the terse export operation

func (*TerseExportURL) Build

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

Build a url path and query string

func (*TerseExportURL) BuildFull

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

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

func (*TerseExportURL) Must

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

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

func (*TerseExportURL) SetBasePath

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

func (o *TerseExportURL) String() string

String returns the string representation of the path with query string

func (*TerseExportURL) StringFull

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

StringFull returns the string representation of a complete url

func (*TerseExportURL) WithBasePath

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

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 TerseImport

type TerseImport struct {
	Context *middleware.Context
	Handler TerseImportHandler
}

TerseImport swagger:route POST /api/import api terseImport

Import existing Terse and Visits data for the given shortened URLs.

Any imported data will overwrite existing data. Unless deletion information is specified. In that case all Terse or Visits data can be deleted before importing the new data.

func NewTerseImport

func NewTerseImport(ctx *middleware.Context, handler TerseImportHandler) *TerseImport

NewTerseImport creates a new http.Handler for the terse import operation

func (*TerseImport) ServeHTTP

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

type TerseImportBody

type TerseImportBody struct {

	// delete
	Delete *models.Delete `json:"delete,omitempty"`

	// import
	Import map[string]models.Export `json:"import,omitempty"`
}

TerseImportBody terse import body

swagger:model TerseImportBody

func (*TerseImportBody) MarshalBinary

func (o *TerseImportBody) MarshalBinary() ([]byte, error)

MarshalBinary interface implementation

func (*TerseImportBody) UnmarshalBinary

func (o *TerseImportBody) UnmarshalBinary(b []byte) error

UnmarshalBinary interface implementation

func (*TerseImportBody) Validate

func (o *TerseImportBody) Validate(formats strfmt.Registry) error

Validate validates this terse import body

type TerseImportDefault

type TerseImportDefault struct {

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

TerseImportDefault Unexpected error.

swagger:response terseImportDefault

func NewTerseImportDefault

func NewTerseImportDefault(code int) *TerseImportDefault

NewTerseImportDefault creates TerseImportDefault with default headers values

func (*TerseImportDefault) SetPayload

func (o *TerseImportDefault) SetPayload(payload *models.Error)

SetPayload sets the payload to the terse import default response

func (*TerseImportDefault) SetStatusCode

func (o *TerseImportDefault) SetStatusCode(code int)

SetStatusCode sets the status to the terse import default response

func (*TerseImportDefault) WithPayload

func (o *TerseImportDefault) WithPayload(payload *models.Error) *TerseImportDefault

WithPayload adds the payload to the terse import default response

func (*TerseImportDefault) WithStatusCode

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

WithStatusCode adds the status to the terse import default response

func (*TerseImportDefault) WriteResponse

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

WriteResponse to the client

type TerseImportHandler

type TerseImportHandler interface {
	Handle(TerseImportParams) middleware.Responder
}

TerseImportHandler interface for that can handle valid terse import params

type TerseImportHandlerFunc

type TerseImportHandlerFunc func(TerseImportParams) middleware.Responder

TerseImportHandlerFunc turns a function with the right signature into a terse import handler

func (TerseImportHandlerFunc) Handle

Handle executing the request and returning a response

type TerseImportOK

type TerseImportOK struct {
}

TerseImportOK terse import o k

swagger:response terseImportOK

func NewTerseImportOK

func NewTerseImportOK() *TerseImportOK

NewTerseImportOK creates TerseImportOK with default headers values

func (*TerseImportOK) WriteResponse

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

WriteResponse to the client

type TerseImportParams

type TerseImportParams struct {

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

	/*A JSON object containing the deletion information. If Terse or Visits data is marked for deletion, it will all be deleted. An object matching shortened URLs to their previously exported data is also required.
	  Required: true
	  In: body
	*/
	ImportDelete TerseImportBody
}

TerseImportParams contains all the bound params for the terse import operation typically these are obtained from a http.Request

swagger:parameters terseImport

func NewTerseImportParams

func NewTerseImportParams() TerseImportParams

NewTerseImportParams creates a new TerseImportParams object no default values defined in spec.

func (*TerseImportParams) BindRequest

func (o *TerseImportParams) 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 NewTerseImportParams() beforehand.

type TerseImportURL

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

TerseImportURL generates an URL for the terse import operation

func (*TerseImportURL) Build

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

Build a url path and query string

func (*TerseImportURL) BuildFull

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

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

func (*TerseImportURL) Must

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

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

func (*TerseImportURL) SetBasePath

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

func (o *TerseImportURL) String() string

String returns the string representation of the path with query string

func (*TerseImportURL) StringFull

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

StringFull returns the string representation of a complete url

func (*TerseImportURL) WithBasePath

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

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 TerseTerse

type TerseTerse struct {
	Context *middleware.Context
	Handler TerseTerseHandler
}

TerseTerse swagger:route GET /api/terse/{shortened} api terseTerse

Read the Terse data for the given shortened URL.

func NewTerseTerse

func NewTerseTerse(ctx *middleware.Context, handler TerseTerseHandler) *TerseTerse

NewTerseTerse creates a new http.Handler for the terse terse operation

func (*TerseTerse) ServeHTTP

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

type TerseTerseDefault

type TerseTerseDefault struct {

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

TerseTerseDefault Unexpected error.

swagger:response terseTerseDefault

func NewTerseTerseDefault

func NewTerseTerseDefault(code int) *TerseTerseDefault

NewTerseTerseDefault creates TerseTerseDefault with default headers values

func (*TerseTerseDefault) SetPayload

func (o *TerseTerseDefault) SetPayload(payload *models.Error)

SetPayload sets the payload to the terse terse default response

func (*TerseTerseDefault) SetStatusCode

func (o *TerseTerseDefault) SetStatusCode(code int)

SetStatusCode sets the status to the terse terse default response

func (*TerseTerseDefault) WithPayload

func (o *TerseTerseDefault) WithPayload(payload *models.Error) *TerseTerseDefault

WithPayload adds the payload to the terse terse default response

func (*TerseTerseDefault) WithStatusCode

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

WithStatusCode adds the status to the terse terse default response

func (*TerseTerseDefault) WriteResponse

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

WriteResponse to the client

type TerseTerseHandler

type TerseTerseHandler interface {
	Handle(TerseTerseParams) middleware.Responder
}

TerseTerseHandler interface for that can handle valid terse terse params

type TerseTerseHandlerFunc

type TerseTerseHandlerFunc func(TerseTerseParams) middleware.Responder

TerseTerseHandlerFunc turns a function with the right signature into a terse terse handler

func (TerseTerseHandlerFunc) Handle

Handle executing the request and returning a response

type TerseTerseOK

type TerseTerseOK struct {

	/*
	  In: Body
	*/
	Payload *models.Terse `json:"body,omitempty"`
}

TerseTerseOK The Terse data was successfully retrieved.

swagger:response terseTerseOK

func NewTerseTerseOK

func NewTerseTerseOK() *TerseTerseOK

NewTerseTerseOK creates TerseTerseOK with default headers values

func (*TerseTerseOK) SetPayload

func (o *TerseTerseOK) SetPayload(payload *models.Terse)

SetPayload sets the payload to the terse terse o k response

func (*TerseTerseOK) WithPayload

func (o *TerseTerseOK) WithPayload(payload *models.Terse) *TerseTerseOK

WithPayload adds the payload to the terse terse o k response

func (*TerseTerseOK) WriteResponse

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

WriteResponse to the client

type TerseTerseParams

type TerseTerseParams struct {

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

	/*The shortened URL to get the Terse data for.
	  Required: true
	  In: path
	*/
	Shortened string
}

TerseTerseParams contains all the bound params for the terse terse operation typically these are obtained from a http.Request

swagger:parameters terseTerse

func NewTerseTerseParams

func NewTerseTerseParams() TerseTerseParams

NewTerseTerseParams creates a new TerseTerseParams object no default values defined in spec.

func (*TerseTerseParams) BindRequest

func (o *TerseTerseParams) 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 NewTerseTerseParams() beforehand.

type TerseTerseURL

type TerseTerseURL struct {
	Shortened string
	// contains filtered or unexported fields
}

TerseTerseURL generates an URL for the terse terse operation

func (*TerseTerseURL) Build

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

Build a url path and query string

func (*TerseTerseURL) BuildFull

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

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

func (*TerseTerseURL) Must

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

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

func (*TerseTerseURL) SetBasePath

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

func (o *TerseTerseURL) String() string

String returns the string representation of the path with query string

func (*TerseTerseURL) StringFull

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

StringFull returns the string representation of a complete url

func (*TerseTerseURL) WithBasePath

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

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 TerseVisits

type TerseVisits struct {
	Context *middleware.Context
	Handler TerseVisitsHandler
}

TerseVisits swagger:route GET /api/visits/{shortened} api terseVisits

Get the Visits data for the given shortened URL.

func NewTerseVisits

func NewTerseVisits(ctx *middleware.Context, handler TerseVisitsHandler) *TerseVisits

NewTerseVisits creates a new http.Handler for the terse visits operation

func (*TerseVisits) ServeHTTP

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

type TerseVisitsDefault

type TerseVisitsDefault struct {

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

TerseVisitsDefault Unexpected error.

swagger:response terseVisitsDefault

func NewTerseVisitsDefault

func NewTerseVisitsDefault(code int) *TerseVisitsDefault

NewTerseVisitsDefault creates TerseVisitsDefault with default headers values

func (*TerseVisitsDefault) SetPayload

func (o *TerseVisitsDefault) SetPayload(payload *models.Error)

SetPayload sets the payload to the terse visits default response

func (*TerseVisitsDefault) SetStatusCode

func (o *TerseVisitsDefault) SetStatusCode(code int)

SetStatusCode sets the status to the terse visits default response

func (*TerseVisitsDefault) WithPayload

func (o *TerseVisitsDefault) WithPayload(payload *models.Error) *TerseVisitsDefault

WithPayload adds the payload to the terse visits default response

func (*TerseVisitsDefault) WithStatusCode

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

WithStatusCode adds the status to the terse visits default response

func (*TerseVisitsDefault) WriteResponse

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

WriteResponse to the client

type TerseVisitsHandler

type TerseVisitsHandler interface {
	Handle(TerseVisitsParams) middleware.Responder
}

TerseVisitsHandler interface for that can handle valid terse visits params

type TerseVisitsHandlerFunc

type TerseVisitsHandlerFunc func(TerseVisitsParams) middleware.Responder

TerseVisitsHandlerFunc turns a function with the right signature into a terse visits handler

func (TerseVisitsHandlerFunc) Handle

Handle executing the request and returning a response

type TerseVisitsOK

type TerseVisitsOK struct {

	/*The visit data for the given shortened URL.
	  In: Body
	*/
	Payload []*models.Visit `json:"body,omitempty"`
}

TerseVisitsOK The Visits data was successfully retrieved.

swagger:response terseVisitsOK

func NewTerseVisitsOK

func NewTerseVisitsOK() *TerseVisitsOK

NewTerseVisitsOK creates TerseVisitsOK with default headers values

func (*TerseVisitsOK) SetPayload

func (o *TerseVisitsOK) SetPayload(payload []*models.Visit)

SetPayload sets the payload to the terse visits o k response

func (*TerseVisitsOK) WithPayload

func (o *TerseVisitsOK) WithPayload(payload []*models.Visit) *TerseVisitsOK

WithPayload adds the payload to the terse visits o k response

func (*TerseVisitsOK) WriteResponse

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

WriteResponse to the client

type TerseVisitsParams

type TerseVisitsParams struct {

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

	/*The shortened URL to get the s data for.
	  Required: true
	  In: path
	*/
	Shortened string
}

TerseVisitsParams contains all the bound params for the terse visits operation typically these are obtained from a http.Request

swagger:parameters terseVisits

func NewTerseVisitsParams

func NewTerseVisitsParams() TerseVisitsParams

NewTerseVisitsParams creates a new TerseVisitsParams object no default values defined in spec.

func (*TerseVisitsParams) BindRequest

func (o *TerseVisitsParams) 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 NewTerseVisitsParams() beforehand.

type TerseVisitsURL

type TerseVisitsURL struct {
	Shortened string
	// contains filtered or unexported fields
}

TerseVisitsURL generates an URL for the terse visits operation

func (*TerseVisitsURL) Build

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

Build a url path and query string

func (*TerseVisitsURL) BuildFull

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

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

func (*TerseVisitsURL) Must

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

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

func (*TerseVisitsURL) SetBasePath

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

func (o *TerseVisitsURL) String() string

String returns the string representation of the path with query string

func (*TerseVisitsURL) StringFull

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

StringFull returns the string representation of a complete url

func (*TerseVisitsURL) WithBasePath

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

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 TerseWrite

type TerseWrite struct {
	Context *middleware.Context
	Handler TerseWriteHandler
}

TerseWrite swagger:route POST /api/write/{operation} api terseWrite

Perform a write operation on Terse data for a given shortened URL.

"insert" will fail if the shortened URL already exists. "update" will fail if the shortened URL does not already exist. "upsert" will only fail if there is a failure interacting with the underlying storage. If no shortened URL is included in the given Terse data, one will be generated randomly and returned in the response.

func NewTerseWrite

func NewTerseWrite(ctx *middleware.Context, handler TerseWriteHandler) *TerseWrite

NewTerseWrite creates a new http.Handler for the terse write operation

func (*TerseWrite) ServeHTTP

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

type TerseWriteDefault

type TerseWriteDefault struct {

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

TerseWriteDefault Unexpected error.

swagger:response terseWriteDefault

func NewTerseWriteDefault

func NewTerseWriteDefault(code int) *TerseWriteDefault

NewTerseWriteDefault creates TerseWriteDefault with default headers values

func (*TerseWriteDefault) SetPayload

func (o *TerseWriteDefault) SetPayload(payload *models.Error)

SetPayload sets the payload to the terse write default response

func (*TerseWriteDefault) SetStatusCode

func (o *TerseWriteDefault) SetStatusCode(code int)

SetStatusCode sets the status to the terse write default response

func (*TerseWriteDefault) WithPayload

func (o *TerseWriteDefault) WithPayload(payload *models.Error) *TerseWriteDefault

WithPayload adds the payload to the terse write default response

func (*TerseWriteDefault) WithStatusCode

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

WithStatusCode adds the status to the terse write default response

func (*TerseWriteDefault) WriteResponse

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

WriteResponse to the client

type TerseWriteHandler

type TerseWriteHandler interface {
	Handle(TerseWriteParams) middleware.Responder
}

TerseWriteHandler interface for that can handle valid terse write params

type TerseWriteHandlerFunc

type TerseWriteHandlerFunc func(TerseWriteParams) middleware.Responder

TerseWriteHandlerFunc turns a function with the right signature into a terse write handler

func (TerseWriteHandlerFunc) Handle

Handle executing the request and returning a response

type TerseWriteOK

type TerseWriteOK struct {

	/*The shortened URL affected.
	  In: Body
	*/
	Payload string `json:"body,omitempty"`
}

TerseWriteOK The write operation was successful.

swagger:response terseWriteOK

func NewTerseWriteOK

func NewTerseWriteOK() *TerseWriteOK

NewTerseWriteOK creates TerseWriteOK with default headers values

func (*TerseWriteOK) SetPayload

func (o *TerseWriteOK) SetPayload(payload string)

SetPayload sets the payload to the terse write o k response

func (*TerseWriteOK) WithPayload

func (o *TerseWriteOK) WithPayload(payload string) *TerseWriteOK

WithPayload adds the payload to the terse write o k response

func (*TerseWriteOK) WriteResponse

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

WriteResponse to the client

type TerseWriteParams

type TerseWriteParams struct {

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

	/*The write operation to perform with the Terse data.
	  Required: true
	  In: path
	*/
	Operation string
	/*The Terse data, with an optional shortened URL. If no shortened URL is given, one will be generated randomly and returned in the response.
	  Required: true
	  In: body
	*/
	Terse *models.TerseOptionalShortened
}

TerseWriteParams contains all the bound params for the terse write operation typically these are obtained from a http.Request

swagger:parameters terseWrite

func NewTerseWriteParams

func NewTerseWriteParams() TerseWriteParams

NewTerseWriteParams creates a new TerseWriteParams object no default values defined in spec.

func (*TerseWriteParams) BindRequest

func (o *TerseWriteParams) 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 NewTerseWriteParams() beforehand.

type TerseWriteURL

type TerseWriteURL struct {
	Operation string
	// contains filtered or unexported fields
}

TerseWriteURL generates an URL for the terse write operation

func (*TerseWriteURL) Build

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

Build a url path and query string

func (*TerseWriteURL) BuildFull

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

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

func (*TerseWriteURL) Must

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

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

func (*TerseWriteURL) SetBasePath

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

func (o *TerseWriteURL) String() string

String returns the string representation of the path with query string

func (*TerseWriteURL) StringFull

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

StringFull returns the string representation of a complete url

func (*TerseWriteURL) WithBasePath

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

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

Jump to

Keyboard shortcuts

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