models

package
Version: v0.29.0 Latest Latest
Warning

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

Go to latest
Published: Jan 23, 2022 License: Apache-2.0 Imports: 7 Imported by: 52

Documentation

Index

Constants

View Source
const (

	// OrderStatusPlaced captures enum value "placed"
	OrderStatusPlaced string = "placed"

	// OrderStatusApproved captures enum value "approved"
	OrderStatusApproved string = "approved"

	// OrderStatusDelivered captures enum value "delivered"
	OrderStatusDelivered string = "delivered"
)
View Source
const (

	// PetStatusAvailable captures enum value "available"
	PetStatusAvailable string = "available"

	// PetStatusPending captures enum value "pending"
	PetStatusPending string = "pending"

	// PetStatusSold captures enum value "sold"
	PetStatusSold string = "sold"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type APIResponse

type APIResponse struct {

	// code
	Code int32 `json:"code,omitempty"`

	// message
	Message string `json:"message,omitempty"`

	// type
	Type string `json:"type,omitempty"`
}

APIResponse is the response to an API call

swagger:model ApiResponse

func (*APIResponse) ContextValidate added in v0.26.0

func (m *APIResponse) ContextValidate(ctx context.Context, formats strfmt.Registry) error

ContextValidate validates this Api response based on context it is used

func (*APIResponse) MarshalBinary

func (m *APIResponse) MarshalBinary() ([]byte, error)

MarshalBinary interface implementation

func (*APIResponse) UnmarshalBinary

func (m *APIResponse) UnmarshalBinary(b []byte) error

UnmarshalBinary interface implementation

func (*APIResponse) Validate

func (m *APIResponse) Validate(formats strfmt.Registry) error

Validate validates this Api response

type Category

type Category struct {

	// id
	ID int64 `json:"id,omitempty"`

	// name
	Name string `json:"name,omitempty"`
}

Category category

swagger:model Category

func (*Category) ContextValidate added in v0.26.0

func (m *Category) ContextValidate(ctx context.Context, formats strfmt.Registry) error

ContextValidate validates this category based on context it is used

func (*Category) MarshalBinary

func (m *Category) MarshalBinary() ([]byte, error)

MarshalBinary interface implementation

func (*Category) UnmarshalBinary

func (m *Category) UnmarshalBinary(b []byte) error

UnmarshalBinary interface implementation

func (*Category) Validate

func (m *Category) Validate(formats strfmt.Registry) error

Validate validates this category

type Order

type Order struct {

	// complete
	Complete *bool `json:"complete,omitempty"`

	// id
	ID int64 `json:"id,omitempty"`

	// pet Id
	PetID int64 `json:"petId,omitempty"`

	// quantity
	Quantity int32 `json:"quantity,omitempty"`

	// ship date
	// Format: date-time
	ShipDate strfmt.DateTime `json:"shipDate,omitempty"`

	// Order Status
	// Enum: [placed approved delivered]
	Status string `json:"status,omitempty"`
}

Order order

swagger:model Order

func (*Order) ContextValidate added in v0.26.0

func (m *Order) ContextValidate(ctx context.Context, formats strfmt.Registry) error

ContextValidate validates this order based on context it is used

func (*Order) MarshalBinary

func (m *Order) MarshalBinary() ([]byte, error)

MarshalBinary interface implementation

func (*Order) UnmarshalBinary

func (m *Order) UnmarshalBinary(b []byte) error

UnmarshalBinary interface implementation

func (*Order) Validate

func (m *Order) Validate(formats strfmt.Registry) error

Validate validates this order

type Pet

type Pet struct {

	// category
	Category *Category `json:"category,omitempty"`

	// id
	ID int64 `json:"id,omitempty" gorm:"primary_key" query:"filter,sort"`

	// name
	// Example: doggie
	// Required: true
	Name *string `json:"name" query:"filter,sort"`

	// photo urls
	// Required: true
	PhotoUrls []string `json:"photoUrls" gorm:"-"`

	// pet status in the store
	// Enum: [available pending sold]
	Status string `json:"status,omitempty" query:"filter,sort"`

	// tags
	Tags []*Tag `json:"tags"`
}

Pet pet

swagger:model Pet

func (*Pet) ContextValidate added in v0.26.0

func (m *Pet) ContextValidate(ctx context.Context, formats strfmt.Registry) error

ContextValidate validate this pet based on the context it is used

func (*Pet) MarshalBinary

func (m *Pet) MarshalBinary() ([]byte, error)

MarshalBinary interface implementation

func (*Pet) UnmarshalBinary

func (m *Pet) UnmarshalBinary(b []byte) error

UnmarshalBinary interface implementation

func (*Pet) Validate

func (m *Pet) Validate(formats strfmt.Registry) error

Validate validates this pet

type Tag

type Tag struct {

	// id
	ID int64 `json:"id,omitempty"`

	// name
	Name string `json:"name,omitempty"`
}

Tag tag

swagger:model Tag

func (*Tag) ContextValidate added in v0.26.0

func (m *Tag) ContextValidate(ctx context.Context, formats strfmt.Registry) error

ContextValidate validates this tag based on context it is used

func (*Tag) MarshalBinary

func (m *Tag) MarshalBinary() ([]byte, error)

MarshalBinary interface implementation

func (*Tag) UnmarshalBinary

func (m *Tag) UnmarshalBinary(b []byte) error

UnmarshalBinary interface implementation

func (*Tag) Validate

func (m *Tag) Validate(formats strfmt.Registry) error

Validate validates this tag

Jump to

Keyboard shortcuts

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