models

package
v0.0.0-...-760f05f Latest Latest
Warning

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

Go to latest
Published: Feb 25, 2022 License: GPL-3.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Event

type Event struct {

	// The category of event
	// Required: true
	// Max Length: 255
	Category *string `json:"category"`

	// The event main content (text message)
	// Max Length: 10000
	Content string `json:"content,omitempty"`

	// The title of event
	// Required: true
	// Max Length: 255
	Owner *string `json:"owner"`

	// The title of event
	// Required: true
	// Max Length: 255
	Title *string `json:"title"`

	// id
	ID ObjectID `json:"_id,omitempty"`

	// date
	// Required: true
	Date *TimeSpan `json:"date"`
}

Event Event defines the structure for an API event

swagger:model Event

func (*Event) MarshalBinary

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

MarshalBinary interface implementation

func (*Event) UnmarshalBinary

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

UnmarshalBinary interface implementation

func (*Event) Validate

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

Validate validates this event

type Events

type Events []*Event

Events Events is a type definition for slice of Event pointers

swagger:model Events

func (Events) Validate

func (m Events) Validate(formats strfmt.Registry) error

Validate validates this events

type GenericError

type GenericError struct {

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

GenericError GenericError is a generic error message returned by a server

swagger:model GenericError

func (*GenericError) MarshalBinary

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

MarshalBinary interface implementation

func (*GenericError) UnmarshalBinary

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

UnmarshalBinary interface implementation

func (*GenericError) Validate

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

Validate validates this generic error

type ObjectID

type ObjectID []uint8

ObjectID ObjectID is the BSON ObjectID type.

swagger:model ObjectID

func (ObjectID) Validate

func (m ObjectID) Validate(formats strfmt.Registry) error

Validate validates this object ID

type TimeSpan

type TimeSpan struct {

	// The event start time in RFC3339 standard ("2006-01-02T15:04:05Z07:00")
	// Required: true
	// Format: date-time
	Start *strfmt.DateTime `json:"start"`

	// The event stop time in RFC3339 standard ("2006-01-02T15:04:05Z07:00")
	// Required: true
	// Format: date-time
	Stop *strfmt.DateTime `json:"stop"`
}

TimeSpan TimeSpan is an struct representing event start and end time

swagger:model TimeSpan

func (*TimeSpan) MarshalBinary

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

MarshalBinary interface implementation

func (*TimeSpan) UnmarshalBinary

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

UnmarshalBinary interface implementation

func (*TimeSpan) Validate

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

Validate validates this time span

type ValidationError

type ValidationError struct {

	// messages
	Messages []string `json:"messages"`
}

ValidationError ValidationError is a collection of validation error messages

swagger:model ValidationError

func (*ValidationError) MarshalBinary

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

MarshalBinary interface implementation

func (*ValidationError) UnmarshalBinary

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

UnmarshalBinary interface implementation

func (*ValidationError) Validate

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

Validate validates this validation error

Jump to

Keyboard shortcuts

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