beract

package
v0.5.1 Latest Latest
Warning

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

Go to latest
Published: Mar 13, 2025 License: MIT Imports: 27 Imported by: 0

Documentation

Overview

Code generated by ogen, DO NOT EDIT.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func WithServerURL

func WithServerURL(ctx context.Context, u *url.URL) context.Context

WithServerURL sets context key to override server URL.

Types

type ActivitiesCreateCreated

type ActivitiesCreateCreated struct {
	Type                   ActivitiesCreateCreatedType // switch on this field
	ActivitiesCreateList   ActivitiesCreateList
	ActivitiesCreateObject ActivitiesCreateObject
}

ActivitiesCreateCreated represents sum type.

func NewActivitiesCreateListActivitiesCreateCreated

func NewActivitiesCreateListActivitiesCreateCreated(v ActivitiesCreateList) ActivitiesCreateCreated

NewActivitiesCreateListActivitiesCreateCreated returns new ActivitiesCreateCreated from ActivitiesCreateList.

func NewActivitiesCreateObjectActivitiesCreateCreated

func NewActivitiesCreateObjectActivitiesCreateCreated(v ActivitiesCreateObject) ActivitiesCreateCreated

NewActivitiesCreateObjectActivitiesCreateCreated returns new ActivitiesCreateCreated from ActivitiesCreateObject.

func (*ActivitiesCreateCreated) Decode

func (s *ActivitiesCreateCreated) Decode(d *jx.Decoder) error

Decode decodes ActivitiesCreateCreated from json.

func (ActivitiesCreateCreated) Encode

func (s ActivitiesCreateCreated) Encode(e *jx.Encoder)

Encode encodes ActivitiesCreateCreated as json.

func (ActivitiesCreateCreated) GetActivitiesCreateList

func (s ActivitiesCreateCreated) GetActivitiesCreateList() (v ActivitiesCreateList, ok bool)

GetActivitiesCreateList returns ActivitiesCreateList and true boolean if ActivitiesCreateCreated is ActivitiesCreateList.

func (ActivitiesCreateCreated) GetActivitiesCreateObject

func (s ActivitiesCreateCreated) GetActivitiesCreateObject() (v ActivitiesCreateObject, ok bool)

GetActivitiesCreateObject returns ActivitiesCreateObject and true boolean if ActivitiesCreateCreated is ActivitiesCreateObject.

func (ActivitiesCreateCreated) IsActivitiesCreateList

func (s ActivitiesCreateCreated) IsActivitiesCreateList() bool

IsActivitiesCreateList reports whether ActivitiesCreateCreated is ActivitiesCreateList.

func (ActivitiesCreateCreated) IsActivitiesCreateObject

func (s ActivitiesCreateCreated) IsActivitiesCreateObject() bool

IsActivitiesCreateObject reports whether ActivitiesCreateCreated is ActivitiesCreateObject.

func (ActivitiesCreateCreated) MarshalJSON

func (s ActivitiesCreateCreated) MarshalJSON() ([]byte, error)

MarshalJSON implements stdjson.Marshaler.

func (*ActivitiesCreateCreated) SetActivitiesCreateList

func (s *ActivitiesCreateCreated) SetActivitiesCreateList(v ActivitiesCreateList)

SetActivitiesCreateList sets ActivitiesCreateCreated to ActivitiesCreateList.

func (*ActivitiesCreateCreated) SetActivitiesCreateObject

func (s *ActivitiesCreateCreated) SetActivitiesCreateObject(v ActivitiesCreateObject)

SetActivitiesCreateObject sets ActivitiesCreateCreated to ActivitiesCreateObject.

func (*ActivitiesCreateCreated) UnmarshalJSON

func (s *ActivitiesCreateCreated) UnmarshalJSON(data []byte) error

UnmarshalJSON implements stdjson.Unmarshaler.

func (ActivitiesCreateCreated) Validate

func (s ActivitiesCreateCreated) Validate() error

type ActivitiesCreateCreatedType

type ActivitiesCreateCreatedType string

ActivitiesCreateCreatedType is oneOf type of ActivitiesCreateCreated.

const (
	ActivitiesCreateListActivitiesCreateCreated   ActivitiesCreateCreatedType = "ActivitiesCreateList"
	ActivitiesCreateObjectActivitiesCreateCreated ActivitiesCreateCreatedType = "ActivitiesCreateObject"
)

Possible values for ActivitiesCreateCreatedType.

type ActivitiesCreateList

type ActivitiesCreateList []ActivitiesCreateListItem

func (*ActivitiesCreateList) Decode

func (s *ActivitiesCreateList) Decode(d *jx.Decoder) error

Decode decodes ActivitiesCreateList from json.

func (ActivitiesCreateList) Encode

func (s ActivitiesCreateList) Encode(e *jx.Encoder)

Encode encodes ActivitiesCreateList as json.

func (ActivitiesCreateList) MarshalJSON

func (s ActivitiesCreateList) MarshalJSON() ([]byte, error)

MarshalJSON implements stdjson.Marshaler.

func (*ActivitiesCreateList) UnmarshalJSON

func (s *ActivitiesCreateList) UnmarshalJSON(data []byte) error

UnmarshalJSON implements stdjson.Unmarshaler.

func (ActivitiesCreateList) Validate

func (s ActivitiesCreateList) Validate() error

type ActivitiesCreateListItem

type ActivitiesCreateListItem struct {
	ID     ActivityID        `json:"id"`
	Scores NilActivityScores `json:"scores"`
}

func (*ActivitiesCreateListItem) Decode

func (s *ActivitiesCreateListItem) Decode(d *jx.Decoder) error

Decode decodes ActivitiesCreateListItem from json.

func (*ActivitiesCreateListItem) Encode

func (s *ActivitiesCreateListItem) Encode(e *jx.Encoder)

Encode implements json.Marshaler.

func (*ActivitiesCreateListItem) GetID

GetID returns the value of ID.

func (*ActivitiesCreateListItem) GetScores

GetScores returns the value of Scores.

func (*ActivitiesCreateListItem) MarshalJSON

func (s *ActivitiesCreateListItem) MarshalJSON() ([]byte, error)

MarshalJSON implements stdjson.Marshaler.

func (*ActivitiesCreateListItem) SetID

func (s *ActivitiesCreateListItem) SetID(val ActivityID)

SetID sets the value of ID.

func (*ActivitiesCreateListItem) SetScores

func (s *ActivitiesCreateListItem) SetScores(val NilActivityScores)

SetScores sets the value of Scores.

func (*ActivitiesCreateListItem) UnmarshalJSON

func (s *ActivitiesCreateListItem) UnmarshalJSON(data []byte) error

UnmarshalJSON implements stdjson.Unmarshaler.

func (*ActivitiesCreateListItem) Validate

func (s *ActivitiesCreateListItem) Validate() error

type ActivitiesCreateObject

type ActivitiesCreateObject struct {
	Activities ActivitiesCreateList                  `json:"activities"`
	Artefacts  []ActivitiesCreateObjectArtefactsItem `json:"artefacts"`
}

Ref: #/components/schemas/ActivitiesCreateObject

func (*ActivitiesCreateObject) Decode

func (s *ActivitiesCreateObject) Decode(d *jx.Decoder) error

Decode decodes ActivitiesCreateObject from json.

func (*ActivitiesCreateObject) Encode

func (s *ActivitiesCreateObject) Encode(e *jx.Encoder)

Encode implements json.Marshaler.

func (*ActivitiesCreateObject) GetActivities

func (s *ActivitiesCreateObject) GetActivities() ActivitiesCreateList

GetActivities returns the value of Activities.

func (*ActivitiesCreateObject) GetArtefacts

GetArtefacts returns the value of Artefacts.

func (*ActivitiesCreateObject) MarshalJSON

func (s *ActivitiesCreateObject) MarshalJSON() ([]byte, error)

MarshalJSON implements stdjson.Marshaler.

func (*ActivitiesCreateObject) SetActivities

func (s *ActivitiesCreateObject) SetActivities(val ActivitiesCreateList)

SetActivities sets the value of Activities.

func (*ActivitiesCreateObject) SetArtefacts

SetArtefacts sets the value of Artefacts.

func (*ActivitiesCreateObject) UnmarshalJSON

func (s *ActivitiesCreateObject) UnmarshalJSON(data []byte) error

UnmarshalJSON implements stdjson.Unmarshaler.

func (*ActivitiesCreateObject) Validate

func (s *ActivitiesCreateObject) Validate() error

type ActivitiesCreateObjectArtefactsItem

type ActivitiesCreateObjectArtefactsItem struct {
	ID ArtefactID `json:"id"`
	// Временный URL для загрузки данных артефакта методом PUT.
	UploadURL string `json:"upload_url"`
}

func (*ActivitiesCreateObjectArtefactsItem) Decode

Decode decodes ActivitiesCreateObjectArtefactsItem from json.

func (*ActivitiesCreateObjectArtefactsItem) Encode

Encode implements json.Marshaler.

func (*ActivitiesCreateObjectArtefactsItem) GetID

GetID returns the value of ID.

func (*ActivitiesCreateObjectArtefactsItem) GetUploadURL

func (s *ActivitiesCreateObjectArtefactsItem) GetUploadURL() string

GetUploadURL returns the value of UploadURL.

func (*ActivitiesCreateObjectArtefactsItem) MarshalJSON

func (s *ActivitiesCreateObjectArtefactsItem) MarshalJSON() ([]byte, error)

MarshalJSON implements stdjson.Marshaler.

func (*ActivitiesCreateObjectArtefactsItem) SetID

SetID sets the value of ID.

func (*ActivitiesCreateObjectArtefactsItem) SetUploadURL

func (s *ActivitiesCreateObjectArtefactsItem) SetUploadURL(val string)

SetUploadURL sets the value of UploadURL.

func (*ActivitiesCreateObjectArtefactsItem) UnmarshalJSON

func (s *ActivitiesCreateObjectArtefactsItem) UnmarshalJSON(data []byte) error

UnmarshalJSON implements stdjson.Unmarshaler.

type ActivitiesCreateReq

type ActivitiesCreateReq struct {
	Type                ActivitiesCreateReqType // switch on this field
	ActivityWriteList   ActivityWriteList
	ActivityWriteObject ActivityWriteObject
}

ActivitiesCreateReq represents sum type.

func NewActivityWriteListActivitiesCreateReq

func NewActivityWriteListActivitiesCreateReq(v ActivityWriteList) ActivitiesCreateReq

NewActivityWriteListActivitiesCreateReq returns new ActivitiesCreateReq from ActivityWriteList.

func NewActivityWriteObjectActivitiesCreateReq

func NewActivityWriteObjectActivitiesCreateReq(v ActivityWriteObject) ActivitiesCreateReq

NewActivityWriteObjectActivitiesCreateReq returns new ActivitiesCreateReq from ActivityWriteObject.

func (*ActivitiesCreateReq) Decode

func (s *ActivitiesCreateReq) Decode(d *jx.Decoder) error

Decode decodes ActivitiesCreateReq from json.

func (ActivitiesCreateReq) Encode

func (s ActivitiesCreateReq) Encode(e *jx.Encoder)

Encode encodes ActivitiesCreateReq as json.

func (ActivitiesCreateReq) GetActivityWriteList

func (s ActivitiesCreateReq) GetActivityWriteList() (v ActivityWriteList, ok bool)

GetActivityWriteList returns ActivityWriteList and true boolean if ActivitiesCreateReq is ActivityWriteList.

func (ActivitiesCreateReq) GetActivityWriteObject

func (s ActivitiesCreateReq) GetActivityWriteObject() (v ActivityWriteObject, ok bool)

GetActivityWriteObject returns ActivityWriteObject and true boolean if ActivitiesCreateReq is ActivityWriteObject.

func (ActivitiesCreateReq) IsActivityWriteList

func (s ActivitiesCreateReq) IsActivityWriteList() bool

IsActivityWriteList reports whether ActivitiesCreateReq is ActivityWriteList.

func (ActivitiesCreateReq) IsActivityWriteObject

func (s ActivitiesCreateReq) IsActivityWriteObject() bool

IsActivityWriteObject reports whether ActivitiesCreateReq is ActivityWriteObject.

func (ActivitiesCreateReq) MarshalJSON

func (s ActivitiesCreateReq) MarshalJSON() ([]byte, error)

MarshalJSON implements stdjson.Marshaler.

func (*ActivitiesCreateReq) SetActivityWriteList

func (s *ActivitiesCreateReq) SetActivityWriteList(v ActivityWriteList)

SetActivityWriteList sets ActivitiesCreateReq to ActivityWriteList.

func (*ActivitiesCreateReq) SetActivityWriteObject

func (s *ActivitiesCreateReq) SetActivityWriteObject(v ActivityWriteObject)

SetActivityWriteObject sets ActivitiesCreateReq to ActivityWriteObject.

func (*ActivitiesCreateReq) UnmarshalJSON

func (s *ActivitiesCreateReq) UnmarshalJSON(data []byte) error

UnmarshalJSON implements stdjson.Unmarshaler.

func (ActivitiesCreateReq) Validate

func (s ActivitiesCreateReq) Validate() error

type ActivitiesCreateReqType

type ActivitiesCreateReqType string

ActivitiesCreateReqType is oneOf type of ActivitiesCreateReq.

const (
	ActivityWriteListActivitiesCreateReq   ActivitiesCreateReqType = "ActivityWriteList"
	ActivityWriteObjectActivitiesCreateReq ActivitiesCreateReqType = "ActivityWriteObject"
)

Possible values for ActivitiesCreateReqType.

type ActivitiesCreateRes

type ActivitiesCreateRes interface {
	// contains filtered or unexported methods
}

type ActivitiesListParams

type ActivitiesListParams struct {
	// Идентификаторы активностей.
	Ids []uuid.UUID
}

ActivitiesListParams is parameters of ActivitiesList operation.

type ActivitiesMetricsListOKHeaders

type ActivitiesMetricsListOKHeaders struct {
	XCount   int64
	Response []ActivitiesMetricsListOKItem
}

ActivitiesMetricsListOKHeaders wraps []ActivitiesMetricsListOKItem with response headers.

func (*ActivitiesMetricsListOKHeaders) GetResponse

GetResponse returns the value of Response.

func (*ActivitiesMetricsListOKHeaders) GetXCount

func (s *ActivitiesMetricsListOKHeaders) GetXCount() int64

GetXCount returns the value of XCount.

func (*ActivitiesMetricsListOKHeaders) SetResponse

SetResponse sets the value of Response.

func (*ActivitiesMetricsListOKHeaders) SetXCount

func (s *ActivitiesMetricsListOKHeaders) SetXCount(val int64)

SetXCount sets the value of XCount.

func (*ActivitiesMetricsListOKHeaders) Validate

func (s *ActivitiesMetricsListOKHeaders) Validate() error

type ActivitiesMetricsListOKItem

type ActivitiesMetricsListOKItem struct {
	ActivityID ActivityID         `json:"activity_id"`
	CreatedAt  ActivityCreatedAt  `json:"created_at"`
	PlayerID   PlayerID           `json:"player_id"`
	AppVersion ActivityAppVersion `json:"app_version"`
	ContextID  ContextID          `json:"context_id"`
	// Описание контекста.
	ContextDescription string          `json:"context_description"`
	ArtefactID         NilUUID         `json:"artefact_id"`
	Metrics            ActivityMetrics `json:"metrics"`
}

func (*ActivitiesMetricsListOKItem) Decode

Decode decodes ActivitiesMetricsListOKItem from json.

func (*ActivitiesMetricsListOKItem) Encode

func (s *ActivitiesMetricsListOKItem) Encode(e *jx.Encoder)

Encode implements json.Marshaler.

func (*ActivitiesMetricsListOKItem) GetActivityID

func (s *ActivitiesMetricsListOKItem) GetActivityID() ActivityID

GetActivityID returns the value of ActivityID.

func (*ActivitiesMetricsListOKItem) GetAppVersion

GetAppVersion returns the value of AppVersion.

func (*ActivitiesMetricsListOKItem) GetArtefactID

func (s *ActivitiesMetricsListOKItem) GetArtefactID() NilUUID

GetArtefactID returns the value of ArtefactID.

func (*ActivitiesMetricsListOKItem) GetContextDescription

func (s *ActivitiesMetricsListOKItem) GetContextDescription() string

GetContextDescription returns the value of ContextDescription.

func (*ActivitiesMetricsListOKItem) GetContextID

func (s *ActivitiesMetricsListOKItem) GetContextID() ContextID

GetContextID returns the value of ContextID.

func (*ActivitiesMetricsListOKItem) GetCreatedAt

GetCreatedAt returns the value of CreatedAt.

func (*ActivitiesMetricsListOKItem) GetMetrics

GetMetrics returns the value of Metrics.

func (*ActivitiesMetricsListOKItem) GetPlayerID

func (s *ActivitiesMetricsListOKItem) GetPlayerID() PlayerID

GetPlayerID returns the value of PlayerID.

func (*ActivitiesMetricsListOKItem) MarshalJSON

func (s *ActivitiesMetricsListOKItem) MarshalJSON() ([]byte, error)

MarshalJSON implements stdjson.Marshaler.

func (*ActivitiesMetricsListOKItem) SetActivityID

func (s *ActivitiesMetricsListOKItem) SetActivityID(val ActivityID)

SetActivityID sets the value of ActivityID.

func (*ActivitiesMetricsListOKItem) SetAppVersion

func (s *ActivitiesMetricsListOKItem) SetAppVersion(val ActivityAppVersion)

SetAppVersion sets the value of AppVersion.

func (*ActivitiesMetricsListOKItem) SetArtefactID

func (s *ActivitiesMetricsListOKItem) SetArtefactID(val NilUUID)

SetArtefactID sets the value of ArtefactID.

func (*ActivitiesMetricsListOKItem) SetContextDescription

func (s *ActivitiesMetricsListOKItem) SetContextDescription(val string)

SetContextDescription sets the value of ContextDescription.

func (*ActivitiesMetricsListOKItem) SetContextID

func (s *ActivitiesMetricsListOKItem) SetContextID(val ContextID)

SetContextID sets the value of ContextID.

func (*ActivitiesMetricsListOKItem) SetCreatedAt

func (s *ActivitiesMetricsListOKItem) SetCreatedAt(val ActivityCreatedAt)

SetCreatedAt sets the value of CreatedAt.

func (*ActivitiesMetricsListOKItem) SetMetrics

func (s *ActivitiesMetricsListOKItem) SetMetrics(val ActivityMetrics)

SetMetrics sets the value of Metrics.

func (*ActivitiesMetricsListOKItem) SetPlayerID

func (s *ActivitiesMetricsListOKItem) SetPlayerID(val PlayerID)

SetPlayerID sets the value of PlayerID.

func (*ActivitiesMetricsListOKItem) UnmarshalJSON

func (s *ActivitiesMetricsListOKItem) UnmarshalJSON(data []byte) error

UnmarshalJSON implements stdjson.Unmarshaler.

func (*ActivitiesMetricsListOKItem) Validate

func (s *ActivitiesMetricsListOKItem) Validate() error

type ActivitiesMetricsListParams

type ActivitiesMetricsListParams struct {
	Offset OptInt32
	Limit  OptInt32
	// ID приложения для фильтрации контекстов.
	ApplicationID OptUUID
	// Свойства контекстов приложения.
	// Заполняются в формате имени и значения объединенных
	// пробелом (кодируется как `+` или `%20`).
	// На каждое свойство допускается указывать до 5
	// значений.
	// Множественные значения учитываются как `допустим
	// любой из вариантов`,
	// или же еще можно сказать что они объединяются
	// логическим ИЛИ.
	// В запросе можноственные значения нужно разделять
	// вертикальной чертой.
	// Пример фильтра по свойству `instrument` с тремя
	// допустимыми значениями: `instrument+piano|guitar|drums`.
	ContextProperty []string
	// Список идентификаторов контекстов.
	ContextIds []ContextID
	Since      OptDateTime
	Until      OptDateTime
	// Список игроков, активности которых попадут в выборку.
	PlayerIds []PlayerID
}

ActivitiesMetricsListParams is parameters of ActivitiesMetricsList operation.

type ActivitiesMetricsListRes

type ActivitiesMetricsListRes interface {
	// contains filtered or unexported methods
}

type ActivitiesScores

type ActivitiesScores float64

func (*ActivitiesScores) Decode

func (s *ActivitiesScores) Decode(d *jx.Decoder) error

Decode decodes ActivitiesScores from json.

func (ActivitiesScores) Encode

func (s ActivitiesScores) Encode(e *jx.Encoder)

Encode encodes ActivitiesScores as json.

func (ActivitiesScores) MarshalJSON

func (s ActivitiesScores) MarshalJSON() ([]byte, error)

MarshalJSON implements stdjson.Marshaler.

func (*ActivitiesScores) UnmarshalJSON

func (s *ActivitiesScores) UnmarshalJSON(data []byte) error

UnmarshalJSON implements stdjson.Unmarshaler.

func (ActivitiesScores) Validate

func (s ActivitiesScores) Validate() error

type ActivitiesScoresByTraditionsOKApplicationJSON

type ActivitiesScoresByTraditionsOKApplicationJSON []ActivitiesScoresByTraditionsOKItem

func (*ActivitiesScoresByTraditionsOKApplicationJSON) Decode

Decode decodes ActivitiesScoresByTraditionsOKApplicationJSON from json.

func (ActivitiesScoresByTraditionsOKApplicationJSON) Encode

Encode encodes ActivitiesScoresByTraditionsOKApplicationJSON as json.

func (ActivitiesScoresByTraditionsOKApplicationJSON) MarshalJSON

MarshalJSON implements stdjson.Marshaler.

func (*ActivitiesScoresByTraditionsOKApplicationJSON) UnmarshalJSON

func (s *ActivitiesScoresByTraditionsOKApplicationJSON) UnmarshalJSON(data []byte) error

UnmarshalJSON implements stdjson.Unmarshaler.

func (ActivitiesScoresByTraditionsOKApplicationJSON) Validate

type ActivitiesScoresByTraditionsOKItem

type ActivitiesScoresByTraditionsOKItem struct {
	// ID традиции.
	TraditionID int32            `json:"tradition_id"`
	Scores      ActivitiesScores `json:"scores"`
}

func (*ActivitiesScoresByTraditionsOKItem) Decode

Decode decodes ActivitiesScoresByTraditionsOKItem from json.

func (*ActivitiesScoresByTraditionsOKItem) Encode

Encode implements json.Marshaler.

func (*ActivitiesScoresByTraditionsOKItem) GetScores

GetScores returns the value of Scores.

func (*ActivitiesScoresByTraditionsOKItem) GetTraditionID

func (s *ActivitiesScoresByTraditionsOKItem) GetTraditionID() int32

GetTraditionID returns the value of TraditionID.

func (*ActivitiesScoresByTraditionsOKItem) MarshalJSON

func (s *ActivitiesScoresByTraditionsOKItem) MarshalJSON() ([]byte, error)

MarshalJSON implements stdjson.Marshaler.

func (*ActivitiesScoresByTraditionsOKItem) SetScores

SetScores sets the value of Scores.

func (*ActivitiesScoresByTraditionsOKItem) SetTraditionID

func (s *ActivitiesScoresByTraditionsOKItem) SetTraditionID(val int32)

SetTraditionID sets the value of TraditionID.

func (*ActivitiesScoresByTraditionsOKItem) UnmarshalJSON

func (s *ActivitiesScoresByTraditionsOKItem) UnmarshalJSON(data []byte) error

UnmarshalJSON implements stdjson.Unmarshaler.

func (*ActivitiesScoresByTraditionsOKItem) Validate

type ActivitiesScoresByTraditionsParams

type ActivitiesScoresByTraditionsParams struct {
	// Получение баллов по всем PlayerID пользователя.
	TalentID int32
}

ActivitiesScoresByTraditionsParams is parameters of ActivitiesScoresByTraditions operation.

type ActivitiesScoresByTraditionsRes

type ActivitiesScoresByTraditionsRes interface {
	// contains filtered or unexported methods
}

type ActivitiesScoresForbidden

type ActivitiesScoresForbidden Error

func (*ActivitiesScoresForbidden) Decode

func (s *ActivitiesScoresForbidden) Decode(d *jx.Decoder) error

Decode decodes ActivitiesScoresForbidden from json.

func (*ActivitiesScoresForbidden) Encode

func (s *ActivitiesScoresForbidden) Encode(e *jx.Encoder)

Encode encodes ActivitiesScoresForbidden as json.

func (*ActivitiesScoresForbidden) MarshalJSON

func (s *ActivitiesScoresForbidden) MarshalJSON() ([]byte, error)

MarshalJSON implements stdjson.Marshaler.

func (*ActivitiesScoresForbidden) UnmarshalJSON

func (s *ActivitiesScoresForbidden) UnmarshalJSON(data []byte) error

UnmarshalJSON implements stdjson.Unmarshaler.

type ActivitiesScoresParams

type ActivitiesScoresParams struct {
	// Идентификатор традиции.
	TraditionID OptInt32
	// Список идентификаторов контекстов.
	ContextIds []ContextID
	// Список игроков, активности которых попадут в выборку.
	// Параметр доступен только при использовании
	// авторизации `ServiceKey`.
	PlayerIds []PlayerID
}

ActivitiesScoresParams is parameters of ActivitiesScores operation.

type ActivitiesScoresRes

type ActivitiesScoresRes interface {
	// contains filtered or unexported methods
}

type ActivitiesScoresUnprocessableEntity

type ActivitiesScoresUnprocessableEntity Error

func (*ActivitiesScoresUnprocessableEntity) Decode

Decode decodes ActivitiesScoresUnprocessableEntity from json.

func (*ActivitiesScoresUnprocessableEntity) Encode

Encode encodes ActivitiesScoresUnprocessableEntity as json.

func (*ActivitiesScoresUnprocessableEntity) MarshalJSON

func (s *ActivitiesScoresUnprocessableEntity) MarshalJSON() ([]byte, error)

MarshalJSON implements stdjson.Marshaler.

func (*ActivitiesScoresUnprocessableEntity) UnmarshalJSON

func (s *ActivitiesScoresUnprocessableEntity) UnmarshalJSON(data []byte) error

UnmarshalJSON implements stdjson.Unmarshaler.

type Activity

type Activity struct {
	ID         ActivityID            `json:"id"`
	CreatedAt  ActivityCreatedAt     `json:"created_at"`
	ContextID  ContextID             `json:"context_id"`
	PlayerID   PlayerID              `json:"player_id"`
	AppVersion ActivityAppVersion    `json:"app_version"`
	Scores     NilActivityScores     `json:"scores"`
	ArtefactID NilUUID               `json:"artefact_id"`
	Quarantine NilActivityQuarantine `json:"quarantine"`
}

Сохраненная игровая активность. Ref: #/components/schemas/Activity

func (*Activity) Decode

func (s *Activity) Decode(d *jx.Decoder) error

Decode decodes Activity from json.

func (*Activity) Encode

func (s *Activity) Encode(e *jx.Encoder)

Encode implements json.Marshaler.

func (*Activity) GetAppVersion

func (s *Activity) GetAppVersion() ActivityAppVersion

GetAppVersion returns the value of AppVersion.

func (*Activity) GetArtefactID

func (s *Activity) GetArtefactID() NilUUID

GetArtefactID returns the value of ArtefactID.

func (*Activity) GetContextID

func (s *Activity) GetContextID() ContextID

GetContextID returns the value of ContextID.

func (*Activity) GetCreatedAt

func (s *Activity) GetCreatedAt() ActivityCreatedAt

GetCreatedAt returns the value of CreatedAt.

func (*Activity) GetID

func (s *Activity) GetID() ActivityID

GetID returns the value of ID.

func (*Activity) GetPlayerID

func (s *Activity) GetPlayerID() PlayerID

GetPlayerID returns the value of PlayerID.

func (*Activity) GetQuarantine

func (s *Activity) GetQuarantine() NilActivityQuarantine

GetQuarantine returns the value of Quarantine.

func (*Activity) GetScores

func (s *Activity) GetScores() NilActivityScores

GetScores returns the value of Scores.

func (*Activity) MarshalJSON

func (s *Activity) MarshalJSON() ([]byte, error)

MarshalJSON implements stdjson.Marshaler.

func (*Activity) SetAppVersion

func (s *Activity) SetAppVersion(val ActivityAppVersion)

SetAppVersion sets the value of AppVersion.

func (*Activity) SetArtefactID

func (s *Activity) SetArtefactID(val NilUUID)

SetArtefactID sets the value of ArtefactID.

func (*Activity) SetContextID

func (s *Activity) SetContextID(val ContextID)

SetContextID sets the value of ContextID.

func (*Activity) SetCreatedAt

func (s *Activity) SetCreatedAt(val ActivityCreatedAt)

SetCreatedAt sets the value of CreatedAt.

func (*Activity) SetID

func (s *Activity) SetID(val ActivityID)

SetID sets the value of ID.

func (*Activity) SetPlayerID

func (s *Activity) SetPlayerID(val PlayerID)

SetPlayerID sets the value of PlayerID.

func (*Activity) SetQuarantine

func (s *Activity) SetQuarantine(val NilActivityQuarantine)

SetQuarantine sets the value of Quarantine.

func (*Activity) SetScores

func (s *Activity) SetScores(val NilActivityScores)

SetScores sets the value of Scores.

func (*Activity) UnmarshalJSON

func (s *Activity) UnmarshalJSON(data []byte) error

UnmarshalJSON implements stdjson.Unmarshaler.

func (*Activity) Validate

func (s *Activity) Validate() error

type ActivityAppVersion

type ActivityAppVersion string

func (*ActivityAppVersion) Decode

func (s *ActivityAppVersion) Decode(d *jx.Decoder) error

Decode decodes ActivityAppVersion from json.

func (ActivityAppVersion) Encode

func (s ActivityAppVersion) Encode(e *jx.Encoder)

Encode encodes ActivityAppVersion as json.

func (ActivityAppVersion) MarshalJSON

func (s ActivityAppVersion) MarshalJSON() ([]byte, error)

MarshalJSON implements stdjson.Marshaler.

func (*ActivityAppVersion) UnmarshalJSON

func (s *ActivityAppVersion) UnmarshalJSON(data []byte) error

UnmarshalJSON implements stdjson.Unmarshaler.

type ActivityCreatedAt

type ActivityCreatedAt time.Time

func (*ActivityCreatedAt) Decode

func (s *ActivityCreatedAt) Decode(d *jx.Decoder) error

Decode decodes ActivityCreatedAt from json.

func (ActivityCreatedAt) Encode

func (s ActivityCreatedAt) Encode(e *jx.Encoder)

Encode encodes ActivityCreatedAt as json.

func (ActivityCreatedAt) MarshalJSON

func (s ActivityCreatedAt) MarshalJSON() ([]byte, error)

MarshalJSON implements stdjson.Marshaler.

func (*ActivityCreatedAt) UnmarshalJSON

func (s *ActivityCreatedAt) UnmarshalJSON(data []byte) error

UnmarshalJSON implements stdjson.Unmarshaler.

type ActivityID

type ActivityID uuid.UUID

func (*ActivityID) Decode

func (s *ActivityID) Decode(d *jx.Decoder) error

Decode decodes ActivityID from json.

func (ActivityID) Encode

func (s ActivityID) Encode(e *jx.Encoder)

Encode encodes ActivityID as json.

func (ActivityID) MarshalJSON

func (s ActivityID) MarshalJSON() ([]byte, error)

MarshalJSON implements stdjson.Marshaler.

func (*ActivityID) UnmarshalJSON

func (s *ActivityID) UnmarshalJSON(data []byte) error

UnmarshalJSON implements stdjson.Unmarshaler.

type ActivityMetrics

type ActivityMetrics map[string]float64

Метрики активности. Ref: #/components/schemas/ActivityMetrics

func (*ActivityMetrics) Decode

func (s *ActivityMetrics) Decode(d *jx.Decoder) error

Decode decodes ActivityMetrics from json.

func (ActivityMetrics) Encode

func (s ActivityMetrics) Encode(e *jx.Encoder)

Encode implements json.Marshaler.

func (ActivityMetrics) MarshalJSON

func (s ActivityMetrics) MarshalJSON() ([]byte, error)

MarshalJSON implements stdjson.Marshaler.

func (*ActivityMetrics) UnmarshalJSON

func (s *ActivityMetrics) UnmarshalJSON(data []byte) error

UnmarshalJSON implements stdjson.Unmarshaler.

func (ActivityMetrics) Validate

func (s ActivityMetrics) Validate() error

type ActivityQuarantine

type ActivityQuarantine string
const (
	ActivityQuarantineMissingArtefact ActivityQuarantine = "missing_artefact"
	ActivityQuarantineInvalidArtefact ActivityQuarantine = "invalid_artefact"
)

func (ActivityQuarantine) AllValues

func (ActivityQuarantine) AllValues() []ActivityQuarantine

AllValues returns all ActivityQuarantine values.

func (*ActivityQuarantine) Decode

func (s *ActivityQuarantine) Decode(d *jx.Decoder) error

Decode decodes ActivityQuarantine from json.

func (ActivityQuarantine) Encode

func (s ActivityQuarantine) Encode(e *jx.Encoder)

Encode encodes ActivityQuarantine as json.

func (ActivityQuarantine) MarshalJSON

func (s ActivityQuarantine) MarshalJSON() ([]byte, error)

MarshalJSON implements stdjson.Marshaler.

func (ActivityQuarantine) MarshalText

func (s ActivityQuarantine) MarshalText() ([]byte, error)

MarshalText implements encoding.TextMarshaler.

func (*ActivityQuarantine) UnmarshalJSON

func (s *ActivityQuarantine) UnmarshalJSON(data []byte) error

UnmarshalJSON implements stdjson.Unmarshaler.

func (*ActivityQuarantine) UnmarshalText

func (s *ActivityQuarantine) UnmarshalText(data []byte) error

UnmarshalText implements encoding.TextUnmarshaler.

func (ActivityQuarantine) Validate

func (s ActivityQuarantine) Validate() error

type ActivityReadOK

type ActivityReadOK struct {
	ID         ActivityID                  `json:"id"`
	CreatedAt  ActivityCreatedAt           `json:"created_at"`
	ContextID  ContextID                   `json:"context_id"`
	PlayerID   PlayerID                    `json:"player_id"`
	AppVersion ActivityAppVersion          `json:"app_version"`
	Scores     NilActivityScores           `json:"scores"`
	ArtefactID NilUUID                     `json:"artefact_id"`
	Quarantine NilActivityReadOKQuarantine `json:"quarantine"`
	// Идентификатор приложения.
	ApplicationID uuid.UUID `json:"application_id"`
	// ID традиции.
	TraditionID int32 `json:"tradition_id"`
	// Свойства контекста активности.
	ContextProperties ActivityReadOKContextProperties `json:"context_properties"`
	Metrics           ActivityMetrics                 `json:"metrics"`
}

Merged schema.

func (*ActivityReadOK) Decode

func (s *ActivityReadOK) Decode(d *jx.Decoder) error

Decode decodes ActivityReadOK from json.

func (*ActivityReadOK) Encode

func (s *ActivityReadOK) Encode(e *jx.Encoder)

Encode implements json.Marshaler.

func (*ActivityReadOK) GetAppVersion

func (s *ActivityReadOK) GetAppVersion() ActivityAppVersion

GetAppVersion returns the value of AppVersion.

func (*ActivityReadOK) GetApplicationID

func (s *ActivityReadOK) GetApplicationID() uuid.UUID

GetApplicationID returns the value of ApplicationID.

func (*ActivityReadOK) GetArtefactID

func (s *ActivityReadOK) GetArtefactID() NilUUID

GetArtefactID returns the value of ArtefactID.

func (*ActivityReadOK) GetContextID

func (s *ActivityReadOK) GetContextID() ContextID

GetContextID returns the value of ContextID.

func (*ActivityReadOK) GetContextProperties

func (s *ActivityReadOK) GetContextProperties() ActivityReadOKContextProperties

GetContextProperties returns the value of ContextProperties.

func (*ActivityReadOK) GetCreatedAt

func (s *ActivityReadOK) GetCreatedAt() ActivityCreatedAt

GetCreatedAt returns the value of CreatedAt.

func (*ActivityReadOK) GetID

func (s *ActivityReadOK) GetID() ActivityID

GetID returns the value of ID.

func (*ActivityReadOK) GetMetrics

func (s *ActivityReadOK) GetMetrics() ActivityMetrics

GetMetrics returns the value of Metrics.

func (*ActivityReadOK) GetPlayerID

func (s *ActivityReadOK) GetPlayerID() PlayerID

GetPlayerID returns the value of PlayerID.

func (*ActivityReadOK) GetQuarantine

func (s *ActivityReadOK) GetQuarantine() NilActivityReadOKQuarantine

GetQuarantine returns the value of Quarantine.

func (*ActivityReadOK) GetScores

func (s *ActivityReadOK) GetScores() NilActivityScores

GetScores returns the value of Scores.

func (*ActivityReadOK) GetTraditionID

func (s *ActivityReadOK) GetTraditionID() int32

GetTraditionID returns the value of TraditionID.

func (*ActivityReadOK) MarshalJSON

func (s *ActivityReadOK) MarshalJSON() ([]byte, error)

MarshalJSON implements stdjson.Marshaler.

func (*ActivityReadOK) SetAppVersion

func (s *ActivityReadOK) SetAppVersion(val ActivityAppVersion)

SetAppVersion sets the value of AppVersion.

func (*ActivityReadOK) SetApplicationID

func (s *ActivityReadOK) SetApplicationID(val uuid.UUID)

SetApplicationID sets the value of ApplicationID.

func (*ActivityReadOK) SetArtefactID

func (s *ActivityReadOK) SetArtefactID(val NilUUID)

SetArtefactID sets the value of ArtefactID.

func (*ActivityReadOK) SetContextID

func (s *ActivityReadOK) SetContextID(val ContextID)

SetContextID sets the value of ContextID.

func (*ActivityReadOK) SetContextProperties

func (s *ActivityReadOK) SetContextProperties(val ActivityReadOKContextProperties)

SetContextProperties sets the value of ContextProperties.

func (*ActivityReadOK) SetCreatedAt

func (s *ActivityReadOK) SetCreatedAt(val ActivityCreatedAt)

SetCreatedAt sets the value of CreatedAt.

func (*ActivityReadOK) SetID

func (s *ActivityReadOK) SetID(val ActivityID)

SetID sets the value of ID.

func (*ActivityReadOK) SetMetrics

func (s *ActivityReadOK) SetMetrics(val ActivityMetrics)

SetMetrics sets the value of Metrics.

func (*ActivityReadOK) SetPlayerID

func (s *ActivityReadOK) SetPlayerID(val PlayerID)

SetPlayerID sets the value of PlayerID.

func (*ActivityReadOK) SetQuarantine

func (s *ActivityReadOK) SetQuarantine(val NilActivityReadOKQuarantine)

SetQuarantine sets the value of Quarantine.

func (*ActivityReadOK) SetScores

func (s *ActivityReadOK) SetScores(val NilActivityScores)

SetScores sets the value of Scores.

func (*ActivityReadOK) SetTraditionID

func (s *ActivityReadOK) SetTraditionID(val int32)

SetTraditionID sets the value of TraditionID.

func (*ActivityReadOK) UnmarshalJSON

func (s *ActivityReadOK) UnmarshalJSON(data []byte) error

UnmarshalJSON implements stdjson.Unmarshaler.

func (*ActivityReadOK) Validate

func (s *ActivityReadOK) Validate() error

type ActivityReadOKContextProperties

type ActivityReadOKContextProperties map[string]ActivityReadOKContextPropertiesItem

Свойства контекста активности.

func (*ActivityReadOKContextProperties) Decode

Decode decodes ActivityReadOKContextProperties from json.

func (ActivityReadOKContextProperties) Encode

Encode implements json.Marshaler.

func (ActivityReadOKContextProperties) MarshalJSON

func (s ActivityReadOKContextProperties) MarshalJSON() ([]byte, error)

MarshalJSON implements stdjson.Marshaler.

func (*ActivityReadOKContextProperties) UnmarshalJSON

func (s *ActivityReadOKContextProperties) UnmarshalJSON(data []byte) error

UnmarshalJSON implements stdjson.Unmarshaler.

func (ActivityReadOKContextProperties) Validate

type ActivityReadOKContextPropertiesItem

type ActivityReadOKContextPropertiesItem struct {
	ValueString NilString  `json:"value_string"`
	ValueNumber NilFloat64 `json:"value_number"`
}

func (*ActivityReadOKContextPropertiesItem) Decode

Decode decodes ActivityReadOKContextPropertiesItem from json.

func (*ActivityReadOKContextPropertiesItem) Encode

Encode implements json.Marshaler.

func (*ActivityReadOKContextPropertiesItem) GetValueNumber

func (s *ActivityReadOKContextPropertiesItem) GetValueNumber() NilFloat64

GetValueNumber returns the value of ValueNumber.

func (*ActivityReadOKContextPropertiesItem) GetValueString

func (s *ActivityReadOKContextPropertiesItem) GetValueString() NilString

GetValueString returns the value of ValueString.

func (*ActivityReadOKContextPropertiesItem) MarshalJSON

func (s *ActivityReadOKContextPropertiesItem) MarshalJSON() ([]byte, error)

MarshalJSON implements stdjson.Marshaler.

func (*ActivityReadOKContextPropertiesItem) SetValueNumber

func (s *ActivityReadOKContextPropertiesItem) SetValueNumber(val NilFloat64)

SetValueNumber sets the value of ValueNumber.

func (*ActivityReadOKContextPropertiesItem) SetValueString

func (s *ActivityReadOKContextPropertiesItem) SetValueString(val NilString)

SetValueString sets the value of ValueString.

func (*ActivityReadOKContextPropertiesItem) UnmarshalJSON

func (s *ActivityReadOKContextPropertiesItem) UnmarshalJSON(data []byte) error

UnmarshalJSON implements stdjson.Unmarshaler.

func (*ActivityReadOKContextPropertiesItem) Validate

type ActivityReadOKQuarantine

type ActivityReadOKQuarantine string
const (
	ActivityReadOKQuarantineMissingArtefact ActivityReadOKQuarantine = "missing_artefact"
	ActivityReadOKQuarantineInvalidArtefact ActivityReadOKQuarantine = "invalid_artefact"
)

func (ActivityReadOKQuarantine) AllValues

AllValues returns all ActivityReadOKQuarantine values.

func (*ActivityReadOKQuarantine) Decode

func (s *ActivityReadOKQuarantine) Decode(d *jx.Decoder) error

Decode decodes ActivityReadOKQuarantine from json.

func (ActivityReadOKQuarantine) Encode

func (s ActivityReadOKQuarantine) Encode(e *jx.Encoder)

Encode encodes ActivityReadOKQuarantine as json.

func (ActivityReadOKQuarantine) MarshalJSON

func (s ActivityReadOKQuarantine) MarshalJSON() ([]byte, error)

MarshalJSON implements stdjson.Marshaler.

func (ActivityReadOKQuarantine) MarshalText

func (s ActivityReadOKQuarantine) MarshalText() ([]byte, error)

MarshalText implements encoding.TextMarshaler.

func (*ActivityReadOKQuarantine) UnmarshalJSON

func (s *ActivityReadOKQuarantine) UnmarshalJSON(data []byte) error

UnmarshalJSON implements stdjson.Unmarshaler.

func (*ActivityReadOKQuarantine) UnmarshalText

func (s *ActivityReadOKQuarantine) UnmarshalText(data []byte) error

UnmarshalText implements encoding.TextUnmarshaler.

func (ActivityReadOKQuarantine) Validate

func (s ActivityReadOKQuarantine) Validate() error

type ActivityReadParams

type ActivityReadParams struct {
	ActivityID ActivityID
}

ActivityReadParams is parameters of ActivityRead operation.

type ActivityReadRes

type ActivityReadRes interface {
	// contains filtered or unexported methods
}

type ActivityScores

type ActivityScores float64

func (*ActivityScores) Decode

func (s *ActivityScores) Decode(d *jx.Decoder) error

Decode decodes ActivityScores from json.

func (ActivityScores) Encode

func (s ActivityScores) Encode(e *jx.Encoder)

Encode encodes ActivityScores as json.

func (ActivityScores) MarshalJSON

func (s ActivityScores) MarshalJSON() ([]byte, error)

MarshalJSON implements stdjson.Marshaler.

func (*ActivityScores) UnmarshalJSON

func (s *ActivityScores) UnmarshalJSON(data []byte) error

UnmarshalJSON implements stdjson.Unmarshaler.

func (ActivityScores) Validate

func (s ActivityScores) Validate() error

type ActivityWrite

type ActivityWrite struct {
	AppVersion ActivityAppVersion      `json:"app_version"`
	ContextID  ContextID               `json:"context_id"`
	ArtefactID OptArtefactID           `json:"artefact_id"`
	Metrics    OptActivityWriteMetrics `json:"metrics"`
}

Записываемая игровая активность. Ref: #/components/schemas/ActivityWrite

func (*ActivityWrite) Decode

func (s *ActivityWrite) Decode(d *jx.Decoder) error

Decode decodes ActivityWrite from json.

func (*ActivityWrite) Encode

func (s *ActivityWrite) Encode(e *jx.Encoder)

Encode implements json.Marshaler.

func (*ActivityWrite) GetAppVersion

func (s *ActivityWrite) GetAppVersion() ActivityAppVersion

GetAppVersion returns the value of AppVersion.

func (*ActivityWrite) GetArtefactID

func (s *ActivityWrite) GetArtefactID() OptArtefactID

GetArtefactID returns the value of ArtefactID.

func (*ActivityWrite) GetContextID

func (s *ActivityWrite) GetContextID() ContextID

GetContextID returns the value of ContextID.

func (*ActivityWrite) GetMetrics

func (s *ActivityWrite) GetMetrics() OptActivityWriteMetrics

GetMetrics returns the value of Metrics.

func (*ActivityWrite) MarshalJSON

func (s *ActivityWrite) MarshalJSON() ([]byte, error)

MarshalJSON implements stdjson.Marshaler.

func (*ActivityWrite) SetAppVersion

func (s *ActivityWrite) SetAppVersion(val ActivityAppVersion)

SetAppVersion sets the value of AppVersion.

func (*ActivityWrite) SetArtefactID

func (s *ActivityWrite) SetArtefactID(val OptArtefactID)

SetArtefactID sets the value of ArtefactID.

func (*ActivityWrite) SetContextID

func (s *ActivityWrite) SetContextID(val ContextID)

SetContextID sets the value of ContextID.

func (*ActivityWrite) SetMetrics

func (s *ActivityWrite) SetMetrics(val OptActivityWriteMetrics)

SetMetrics sets the value of Metrics.

func (*ActivityWrite) UnmarshalJSON

func (s *ActivityWrite) UnmarshalJSON(data []byte) error

UnmarshalJSON implements stdjson.Unmarshaler.

func (*ActivityWrite) Validate

func (s *ActivityWrite) Validate() error

type ActivityWriteList

type ActivityWriteList []ActivityWrite

func (*ActivityWriteList) Decode

func (s *ActivityWriteList) Decode(d *jx.Decoder) error

Decode decodes ActivityWriteList from json.

func (ActivityWriteList) Encode

func (s ActivityWriteList) Encode(e *jx.Encoder)

Encode encodes ActivityWriteList as json.

func (ActivityWriteList) MarshalJSON

func (s ActivityWriteList) MarshalJSON() ([]byte, error)

MarshalJSON implements stdjson.Marshaler.

func (*ActivityWriteList) UnmarshalJSON

func (s *ActivityWriteList) UnmarshalJSON(data []byte) error

UnmarshalJSON implements stdjson.Unmarshaler.

func (ActivityWriteList) Validate

func (s ActivityWriteList) Validate() error

type ActivityWriteMetrics

type ActivityWriteMetrics map[string]float64

func (*ActivityWriteMetrics) Decode

func (s *ActivityWriteMetrics) Decode(d *jx.Decoder) error

Decode decodes ActivityWriteMetrics from json.

func (ActivityWriteMetrics) Encode

func (s ActivityWriteMetrics) Encode(e *jx.Encoder)

Encode implements json.Marshaler.

func (ActivityWriteMetrics) MarshalJSON

func (s ActivityWriteMetrics) MarshalJSON() ([]byte, error)

MarshalJSON implements stdjson.Marshaler.

func (*ActivityWriteMetrics) UnmarshalJSON

func (s *ActivityWriteMetrics) UnmarshalJSON(data []byte) error

UnmarshalJSON implements stdjson.Unmarshaler.

func (ActivityWriteMetrics) Validate

func (s ActivityWriteMetrics) Validate() error

type ActivityWriteObject

type ActivityWriteObject struct {
	Activities ActivityWriteList                  `json:"activities"`
	Artefacts  []ActivityWriteObjectArtefactsItem `json:"artefacts"`
}

Ref: #/components/schemas/ActivityWriteObject

func (*ActivityWriteObject) Decode

func (s *ActivityWriteObject) Decode(d *jx.Decoder) error

Decode decodes ActivityWriteObject from json.

func (*ActivityWriteObject) Encode

func (s *ActivityWriteObject) Encode(e *jx.Encoder)

Encode implements json.Marshaler.

func (*ActivityWriteObject) GetActivities

func (s *ActivityWriteObject) GetActivities() ActivityWriteList

GetActivities returns the value of Activities.

func (*ActivityWriteObject) GetArtefacts

GetArtefacts returns the value of Artefacts.

func (*ActivityWriteObject) MarshalJSON

func (s *ActivityWriteObject) MarshalJSON() ([]byte, error)

MarshalJSON implements stdjson.Marshaler.

func (*ActivityWriteObject) SetActivities

func (s *ActivityWriteObject) SetActivities(val ActivityWriteList)

SetActivities sets the value of Activities.

func (*ActivityWriteObject) SetArtefacts

SetArtefacts sets the value of Artefacts.

func (*ActivityWriteObject) UnmarshalJSON

func (s *ActivityWriteObject) UnmarshalJSON(data []byte) error

UnmarshalJSON implements stdjson.Unmarshaler.

func (*ActivityWriteObject) Validate

func (s *ActivityWriteObject) Validate() error

type ActivityWriteObjectArtefactsItem

type ActivityWriteObjectArtefactsItem struct {
	// ID артефакта, по которому на него ссылаются активности,
	//  переданные в том же запросе.
	ID uuid.UUID `json:"id"`
	// MIME-тип артефакта.
	ContentType string `json:"content_type"`
	// ID типа артефакта из [справочника](#operation/ArtefactTypesList).
	ArtefactTypeID int32 `json:"artefact_type_id"`
	// SHA-1 контрольная сумма.
	Checksum string `json:"checksum"`
}

func (*ActivityWriteObjectArtefactsItem) Decode

Decode decodes ActivityWriteObjectArtefactsItem from json.

func (*ActivityWriteObjectArtefactsItem) Encode

Encode implements json.Marshaler.

func (*ActivityWriteObjectArtefactsItem) GetArtefactTypeID

func (s *ActivityWriteObjectArtefactsItem) GetArtefactTypeID() int32

GetArtefactTypeID returns the value of ArtefactTypeID.

func (*ActivityWriteObjectArtefactsItem) GetChecksum

func (s *ActivityWriteObjectArtefactsItem) GetChecksum() string

GetChecksum returns the value of Checksum.

func (*ActivityWriteObjectArtefactsItem) GetContentType

func (s *ActivityWriteObjectArtefactsItem) GetContentType() string

GetContentType returns the value of ContentType.

func (*ActivityWriteObjectArtefactsItem) GetID

GetID returns the value of ID.

func (*ActivityWriteObjectArtefactsItem) MarshalJSON

func (s *ActivityWriteObjectArtefactsItem) MarshalJSON() ([]byte, error)

MarshalJSON implements stdjson.Marshaler.

func (*ActivityWriteObjectArtefactsItem) SetArtefactTypeID

func (s *ActivityWriteObjectArtefactsItem) SetArtefactTypeID(val int32)

SetArtefactTypeID sets the value of ArtefactTypeID.

func (*ActivityWriteObjectArtefactsItem) SetChecksum

func (s *ActivityWriteObjectArtefactsItem) SetChecksum(val string)

SetChecksum sets the value of Checksum.

func (*ActivityWriteObjectArtefactsItem) SetContentType

func (s *ActivityWriteObjectArtefactsItem) SetContentType(val string)

SetContentType sets the value of ContentType.

func (*ActivityWriteObjectArtefactsItem) SetID

SetID sets the value of ID.

func (*ActivityWriteObjectArtefactsItem) UnmarshalJSON

func (s *ActivityWriteObjectArtefactsItem) UnmarshalJSON(data []byte) error

UnmarshalJSON implements stdjson.Unmarshaler.

type ArtefactID

type ArtefactID uuid.UUID

func (*ArtefactID) Decode

func (s *ArtefactID) Decode(d *jx.Decoder) error

Decode decodes ArtefactID from json.

func (ArtefactID) Encode

func (s ArtefactID) Encode(e *jx.Encoder)

Encode encodes ArtefactID as json.

func (ArtefactID) MarshalJSON

func (s ArtefactID) MarshalJSON() ([]byte, error)

MarshalJSON implements stdjson.Marshaler.

func (*ArtefactID) UnmarshalJSON

func (s *ArtefactID) UnmarshalJSON(data []byte) error

UnmarshalJSON implements stdjson.Unmarshaler.

type ArtefactSetUploadedNotFound

type ArtefactSetUploadedNotFound Error

func (*ArtefactSetUploadedNotFound) Decode

Decode decodes ArtefactSetUploadedNotFound from json.

func (*ArtefactSetUploadedNotFound) Encode

func (s *ArtefactSetUploadedNotFound) Encode(e *jx.Encoder)

Encode encodes ArtefactSetUploadedNotFound as json.

func (*ArtefactSetUploadedNotFound) MarshalJSON

func (s *ArtefactSetUploadedNotFound) MarshalJSON() ([]byte, error)

MarshalJSON implements stdjson.Marshaler.

func (*ArtefactSetUploadedNotFound) UnmarshalJSON

func (s *ArtefactSetUploadedNotFound) UnmarshalJSON(data []byte) error

UnmarshalJSON implements stdjson.Unmarshaler.

type ArtefactSetUploadedOK

type ArtefactSetUploadedOK struct{}

ArtefactSetUploadedOK is response for ArtefactSetUploaded operation.

type ArtefactSetUploadedParams

type ArtefactSetUploadedParams struct {
	ArtefactID ArtefactID
}

ArtefactSetUploadedParams is parameters of ArtefactSetUploaded operation.

type ArtefactSetUploadedRes

type ArtefactSetUploadedRes interface {
	// contains filtered or unexported methods
}

type ArtefactSetUploadedUnprocessableEntity

type ArtefactSetUploadedUnprocessableEntity Error

func (*ArtefactSetUploadedUnprocessableEntity) Decode

Decode decodes ArtefactSetUploadedUnprocessableEntity from json.

func (*ArtefactSetUploadedUnprocessableEntity) Encode

Encode encodes ArtefactSetUploadedUnprocessableEntity as json.

func (*ArtefactSetUploadedUnprocessableEntity) MarshalJSON

func (s *ArtefactSetUploadedUnprocessableEntity) MarshalJSON() ([]byte, error)

MarshalJSON implements stdjson.Marshaler.

func (*ArtefactSetUploadedUnprocessableEntity) UnmarshalJSON

func (s *ArtefactSetUploadedUnprocessableEntity) UnmarshalJSON(data []byte) error

UnmarshalJSON implements stdjson.Unmarshaler.

type ArtefactTypesListOKItem

type ArtefactTypesListOKItem struct {
	// Идентификатор типа артефактов.
	ID int32 `json:"id"`
	// Название типа артефактов.
	Name string `json:"name"`
}

func (*ArtefactTypesListOKItem) Decode

func (s *ArtefactTypesListOKItem) Decode(d *jx.Decoder) error

Decode decodes ArtefactTypesListOKItem from json.

func (*ArtefactTypesListOKItem) Encode

func (s *ArtefactTypesListOKItem) Encode(e *jx.Encoder)

Encode implements json.Marshaler.

func (*ArtefactTypesListOKItem) GetID

func (s *ArtefactTypesListOKItem) GetID() int32

GetID returns the value of ID.

func (*ArtefactTypesListOKItem) GetName

func (s *ArtefactTypesListOKItem) GetName() string

GetName returns the value of Name.

func (*ArtefactTypesListOKItem) MarshalJSON

func (s *ArtefactTypesListOKItem) MarshalJSON() ([]byte, error)

MarshalJSON implements stdjson.Marshaler.

func (*ArtefactTypesListOKItem) SetID

func (s *ArtefactTypesListOKItem) SetID(val int32)

SetID sets the value of ID.

func (*ArtefactTypesListOKItem) SetName

func (s *ArtefactTypesListOKItem) SetName(val string)

SetName sets the value of Name.

func (*ArtefactTypesListOKItem) UnmarshalJSON

func (s *ArtefactTypesListOKItem) UnmarshalJSON(data []byte) error

UnmarshalJSON implements stdjson.Unmarshaler.

type ArtefactUploadURLNotFound

type ArtefactUploadURLNotFound Error

func (*ArtefactUploadURLNotFound) Decode

func (s *ArtefactUploadURLNotFound) Decode(d *jx.Decoder) error

Decode decodes ArtefactUploadURLNotFound from json.

func (*ArtefactUploadURLNotFound) Encode

func (s *ArtefactUploadURLNotFound) Encode(e *jx.Encoder)

Encode encodes ArtefactUploadURLNotFound as json.

func (*ArtefactUploadURLNotFound) MarshalJSON

func (s *ArtefactUploadURLNotFound) MarshalJSON() ([]byte, error)

MarshalJSON implements stdjson.Marshaler.

func (*ArtefactUploadURLNotFound) UnmarshalJSON

func (s *ArtefactUploadURLNotFound) UnmarshalJSON(data []byte) error

UnmarshalJSON implements stdjson.Unmarshaler.

type ArtefactUploadURLOKApplicationJSON

type ArtefactUploadURLOKApplicationJSON string

func (*ArtefactUploadURLOKApplicationJSON) Decode

Decode decodes ArtefactUploadURLOKApplicationJSON from json.

func (ArtefactUploadURLOKApplicationJSON) Encode

Encode encodes ArtefactUploadURLOKApplicationJSON as json.

func (ArtefactUploadURLOKApplicationJSON) MarshalJSON

func (s ArtefactUploadURLOKApplicationJSON) MarshalJSON() ([]byte, error)

MarshalJSON implements stdjson.Marshaler.

func (*ArtefactUploadURLOKApplicationJSON) UnmarshalJSON

func (s *ArtefactUploadURLOKApplicationJSON) UnmarshalJSON(data []byte) error

UnmarshalJSON implements stdjson.Unmarshaler.

type ArtefactUploadURLParams

type ArtefactUploadURLParams struct {
	ArtefactID ArtefactID
}

ArtefactUploadURLParams is parameters of ArtefactUploadURL operation.

type ArtefactUploadURLRes

type ArtefactUploadURLRes interface {
	// contains filtered or unexported methods
}

type ArtefactUploadURLUnprocessableEntity

type ArtefactUploadURLUnprocessableEntity Error

func (*ArtefactUploadURLUnprocessableEntity) Decode

Decode decodes ArtefactUploadURLUnprocessableEntity from json.

func (*ArtefactUploadURLUnprocessableEntity) Encode

Encode encodes ArtefactUploadURLUnprocessableEntity as json.

func (*ArtefactUploadURLUnprocessableEntity) MarshalJSON

func (s *ArtefactUploadURLUnprocessableEntity) MarshalJSON() ([]byte, error)

MarshalJSON implements stdjson.Marshaler.

func (*ArtefactUploadURLUnprocessableEntity) UnmarshalJSON

func (s *ArtefactUploadURLUnprocessableEntity) UnmarshalJSON(data []byte) error

UnmarshalJSON implements stdjson.Unmarshaler.

type ArtefactsCreateCreatedApplicationJSON

type ArtefactsCreateCreatedApplicationJSON uuid.UUID

func (*ArtefactsCreateCreatedApplicationJSON) Decode

Decode decodes ArtefactsCreateCreatedApplicationJSON from json.

func (ArtefactsCreateCreatedApplicationJSON) Encode

Encode encodes ArtefactsCreateCreatedApplicationJSON as json.

func (ArtefactsCreateCreatedApplicationJSON) MarshalJSON

func (s ArtefactsCreateCreatedApplicationJSON) MarshalJSON() ([]byte, error)

MarshalJSON implements stdjson.Marshaler.

func (*ArtefactsCreateCreatedApplicationJSON) UnmarshalJSON

func (s *ArtefactsCreateCreatedApplicationJSON) UnmarshalJSON(data []byte) error

UnmarshalJSON implements stdjson.Unmarshaler.

type ArtefactsCreateParams

type ArtefactsCreateParams struct {
	// ID типа артефакта из [справочника](#operation/ArtefactTypesList).
	XArtefactType int32
	// SHA-1 контрольная сумма.
	XChecksum string
}

ArtefactsCreateParams is parameters of ArtefactsCreate operation.

type ArtefactsCreateReq

type ArtefactsCreateReq struct {
	Data io.Reader
}

func (ArtefactsCreateReq) Read

func (s ArtefactsCreateReq) Read(p []byte) (n int, err error)

Read reads data from the Data reader.

Kept to satisfy the io.Reader interface.

type ArtefactsCreateReqWithContentType

type ArtefactsCreateReqWithContentType struct {
	ContentType string
	Content     ArtefactsCreateReq
}

ArtefactsCreateReqWithContentType wraps ArtefactsCreateReq with Content-Type.

func (*ArtefactsCreateReqWithContentType) GetContent

GetContent returns the value of Content.

func (*ArtefactsCreateReqWithContentType) GetContentType

func (s *ArtefactsCreateReqWithContentType) GetContentType() string

GetContentType returns the value of ContentType.

func (*ArtefactsCreateReqWithContentType) SetContent

SetContent sets the value of Content.

func (*ArtefactsCreateReqWithContentType) SetContentType

func (s *ArtefactsCreateReqWithContentType) SetContentType(val string)

SetContentType sets the value of ContentType.

type ArtefactsCreateRes

type ArtefactsCreateRes interface {
	// contains filtered or unexported methods
}

type BerlogaJWT

type BerlogaJWT struct {
	APIKey string
}

func (*BerlogaJWT) GetAPIKey

func (s *BerlogaJWT) GetAPIKey() string

GetAPIKey returns the value of APIKey.

func (*BerlogaJWT) SetAPIKey

func (s *BerlogaJWT) SetAPIKey(val string)

SetAPIKey sets the value of APIKey.

type Client

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

Client implements OAS client.

func NewClient

func NewClient(serverURL string, sec SecuritySource, opts ...ClientOption) (*Client, error)

NewClient initializes new Client defined by OAS.

func (*Client) ActivitiesCreate

func (c *Client) ActivitiesCreate(ctx context.Context, request ActivitiesCreateReq) (ActivitiesCreateRes, error)

ActivitiesCreate invokes ActivitiesCreate operation.

Каждая из активностей опционально может иметь метрики и артефакт. Запись активностей доступна в коротком и расширенном форматах. #### Короткий формат Передается только массив активностей. Если они ссылаются на артефакты, эти артефакты должны быть предварительно [загружены](#operation/ArtefactsCreate). Ответ на такой запрос тоже включает в себя только массив с активностями. #### Расширенный формат В этом формате передается объект, который должен содержать активности в массиве, аналогичном короткому формату, и опционально может включать в себя еще артефакты для создания. В ответе на такой запрос, аналогично, возвращается объект, содержащий те же ключи. В возвращаемом массиве артефактов будут ссылки, по которым эти артефакты должны быть загружены. > Ссылки имеют ограниченный срок жизни. Если данные артефакта не были загружены в рамках этого периода, то нужно [запросить новую ссылку](#operation/ArtefactUploadURL). > До тех пор, пока указанные в активности артефакты не будут загружены, эта активность с ее баллами не будет учитываться в прогрессе традиции игрока. После загрузки данных артефакта по полученной ссылке,

нужно [подтвердить что загрузка

завершена](#operation/ArtefactSetUploaded).

POST /activities

func (*Client) ActivitiesList

func (c *Client) ActivitiesList(ctx context.Context, params ActivitiesListParams) ([]Activity, error)

ActivitiesList invokes ActivitiesList operation.

Если какие-то из указанных активностей не будут найдены, то они просто будут отсутствовать в ответе.

GET /activities

func (*Client) ActivitiesMetricsList

func (c *Client) ActivitiesMetricsList(ctx context.Context, params ActivitiesMetricsListParams) (ActivitiesMetricsListRes, error)

ActivitiesMetricsList invokes ActivitiesMetricsList operation.

Необходимо указать параметры выбора контекстов. Это могут быть либо идентификаторы конкретных контекстов `context_ids`. Либо набор фильтров `context_property` и/или ID приложения `application_id`.

GET /activities/metrics

func (*Client) ActivitiesScores

func (c *Client) ActivitiesScores(ctx context.Context, params ActivitiesScoresParams) (ActivitiesScoresRes, error)

ActivitiesScores invokes ActivitiesScores operation.

**Обязательно** указание либо `tradition_id`, либо `context_ids`; эти параметры взаимоисключающие.

GET /activities/scores

func (*Client) ActivitiesScoresByTraditions

func (c *Client) ActivitiesScoresByTraditions(ctx context.Context, params ActivitiesScoresByTraditionsParams) (ActivitiesScoresByTraditionsRes, error)

ActivitiesScoresByTraditions invokes ActivitiesScoresByTraditions operation.

Баллы сгруппированные по традициям.

GET /activities/scores/traditions

func (*Client) ActivityRead

func (c *Client) ActivityRead(ctx context.Context, params ActivityReadParams) (ActivityReadRes, error)

ActivityRead invokes ActivityRead operation.

Чтение активности.

GET /activities/{activity_id}

func (*Client) ArtefactSetUploaded

func (c *Client) ArtefactSetUploaded(ctx context.Context, params ArtefactSetUploadedParams) (ArtefactSetUploadedRes, error)

ArtefactSetUploaded invokes ArtefactSetUploaded operation.

Подтверждение загрузки артефакта.

POST /artefacts/{artefact_id}/set-uploaded

func (*Client) ArtefactTypesList

func (c *Client) ArtefactTypesList(ctx context.Context) ([]ArtefactTypesListOKItem, error)

ArtefactTypesList invokes ArtefactTypesList operation.

Справочник типов артефактов.

GET /artefact-types

func (*Client) ArtefactUploadURL

func (c *Client) ArtefactUploadURL(ctx context.Context, params ArtefactUploadURLParams) (ArtefactUploadURLRes, error)

ArtefactUploadURL invokes ArtefactUploadURL operation.

Ссылка для загрузки данных артефактом имеет ограниченный срок жизни. После его завершения, если данные артефакта еще не были успешно загружены, нужно запрашивать новую ссылку. Загрузку данных по ссылке нужно выполнять методом PUT.

GET /artefacts/{artefact_id}/upload-url

func (*Client) ArtefactsCreate

ArtefactsCreate invokes ArtefactsCreate operation.

Артефакт предварительно загружается для передачи его в активности.

POST /artefacts

func (*Client) ContextIDsList

func (c *Client) ContextIDsList(ctx context.Context, params ContextIDsListParams) (ContextIDsListRes, error)

ContextIDsList invokes ContextIDsList operation.

Идентификаторы контекстов выбранные по тому же принципу что и в ActivitiesMetricsList. Обязательно указание либо `application_id`, либо `property`. Допускаются оба параметра.

GET /contexts/id

func (*Client) ContextTraditionID

func (c *Client) ContextTraditionID(ctx context.Context, params ContextTraditionIDParams) (ContextTraditionIDRes, error)

ContextTraditionID invokes ContextTraditionID operation.

Традиция контекста.

GET /contexts/{context_id}/tradition-id

func (*Client) ContextsImport

func (c *Client) ContextsImport(ctx context.Context, request ContextsImportReq, params ContextsImportParams) (ContextsImportRes, error)

ContextsImport invokes ContextsImport operation.

Импортируемая таблица должна содержать колонки `id` и `description`. Содержащие в ячейках идентификатор (UUID) и описание контекста соответственно. Оставшиеся колонки таблицы будут восприняты как свойства контекстов. Тип значения для свойства определяется на основе значений в ячейках колонки. Если все значения можно интерпретировать как числовые, то тип значения у свойства будет числовой. Если хоть одно значение не приводится к числу, то тип значения определяется как строковый. В заголовках запроса так же необходимо указать ID приложения с контекстами которого будет выполнятся работа.

POST /contexts/import

func (*Client) ContextsList

func (c *Client) ContextsList(ctx context.Context, params ContextsListParams) (ContextsListRes, error)

ContextsList invokes ContextsList operation.

Список контекстов.

GET /contexts

type ClientOption

type ClientOption interface {
	// contains filtered or unexported methods
}

ClientOption is client config option.

func WithClient

func WithClient(client ht.Client) ClientOption

WithClient specifies http client to use.

type Context

type Context struct {
	ID             ContextID `json:"id"`
	ApplicationID  uuid.UUID `json:"application_id"`
	TraditionID    int32     `json:"tradition_id"`
	ActivityTypeID int32     `json:"activity_type_id"`
	Description    string    `json:"description"`
}

Контекст активностей. Ref: #/components/schemas/Context

func (*Context) Decode

func (s *Context) Decode(d *jx.Decoder) error

Decode decodes Context from json.

func (*Context) Encode

func (s *Context) Encode(e *jx.Encoder)

Encode implements json.Marshaler.

func (*Context) GetActivityTypeID

func (s *Context) GetActivityTypeID() int32

GetActivityTypeID returns the value of ActivityTypeID.

func (*Context) GetApplicationID

func (s *Context) GetApplicationID() uuid.UUID

GetApplicationID returns the value of ApplicationID.

func (*Context) GetDescription

func (s *Context) GetDescription() string

GetDescription returns the value of Description.

func (*Context) GetID

func (s *Context) GetID() ContextID

GetID returns the value of ID.

func (*Context) GetTraditionID

func (s *Context) GetTraditionID() int32

GetTraditionID returns the value of TraditionID.

func (*Context) MarshalJSON

func (s *Context) MarshalJSON() ([]byte, error)

MarshalJSON implements stdjson.Marshaler.

func (*Context) SetActivityTypeID

func (s *Context) SetActivityTypeID(val int32)

SetActivityTypeID sets the value of ActivityTypeID.

func (*Context) SetApplicationID

func (s *Context) SetApplicationID(val uuid.UUID)

SetApplicationID sets the value of ApplicationID.

func (*Context) SetDescription

func (s *Context) SetDescription(val string)

SetDescription sets the value of Description.

func (*Context) SetID

func (s *Context) SetID(val ContextID)

SetID sets the value of ID.

func (*Context) SetTraditionID

func (s *Context) SetTraditionID(val int32)

SetTraditionID sets the value of TraditionID.

func (*Context) UnmarshalJSON

func (s *Context) UnmarshalJSON(data []byte) error

UnmarshalJSON implements stdjson.Unmarshaler.

type ContextID

type ContextID uuid.UUID

func (*ContextID) Decode

func (s *ContextID) Decode(d *jx.Decoder) error

Decode decodes ContextID from json.

func (ContextID) Encode

func (s ContextID) Encode(e *jx.Encoder)

Encode encodes ContextID as json.

func (ContextID) MarshalJSON

func (s ContextID) MarshalJSON() ([]byte, error)

MarshalJSON implements stdjson.Marshaler.

func (*ContextID) UnmarshalJSON

func (s *ContextID) UnmarshalJSON(data []byte) error

UnmarshalJSON implements stdjson.Unmarshaler.

type ContextIDsListOKApplicationJSON

type ContextIDsListOKApplicationJSON []ContextID

func (*ContextIDsListOKApplicationJSON) Decode

Decode decodes ContextIDsListOKApplicationJSON from json.

func (ContextIDsListOKApplicationJSON) Encode

Encode encodes ContextIDsListOKApplicationJSON as json.

func (ContextIDsListOKApplicationJSON) MarshalJSON

func (s ContextIDsListOKApplicationJSON) MarshalJSON() ([]byte, error)

MarshalJSON implements stdjson.Marshaler.

func (*ContextIDsListOKApplicationJSON) UnmarshalJSON

func (s *ContextIDsListOKApplicationJSON) UnmarshalJSON(data []byte) error

UnmarshalJSON implements stdjson.Unmarshaler.

func (ContextIDsListOKApplicationJSON) Validate

type ContextIDsListParams

type ContextIDsListParams struct {
	// Фильтрация по ID приложения.
	ApplicationID OptUUID
	// Фильтрация контекстов по свойствам.
	// Свойство и его значение разделяются пробелом (`+` или
	// `%20`).
	// В качестве значения допускается указание до пяти
	// вариантов разделенных символом `|`.
	Property []string
}

ContextIDsListParams is parameters of ContextIDsList operation.

type ContextIDsListRes

type ContextIDsListRes interface {
	// contains filtered or unexported methods
}

type ContextTraditionIDOKApplicationJSON

type ContextTraditionIDOKApplicationJSON int32

func (*ContextTraditionIDOKApplicationJSON) Decode

Decode decodes ContextTraditionIDOKApplicationJSON from json.

func (ContextTraditionIDOKApplicationJSON) Encode

Encode encodes ContextTraditionIDOKApplicationJSON as json.

func (ContextTraditionIDOKApplicationJSON) MarshalJSON

func (s ContextTraditionIDOKApplicationJSON) MarshalJSON() ([]byte, error)

MarshalJSON implements stdjson.Marshaler.

func (*ContextTraditionIDOKApplicationJSON) UnmarshalJSON

func (s *ContextTraditionIDOKApplicationJSON) UnmarshalJSON(data []byte) error

UnmarshalJSON implements stdjson.Unmarshaler.

type ContextTraditionIDParams

type ContextTraditionIDParams struct {
	ContextID ContextID
}

ContextTraditionIDParams is parameters of ContextTraditionID operation.

type ContextTraditionIDRes

type ContextTraditionIDRes interface {
	// contains filtered or unexported methods
}

type ContextsImportBadRequest

type ContextsImportBadRequest Error

func (*ContextsImportBadRequest) Decode

func (s *ContextsImportBadRequest) Decode(d *jx.Decoder) error

Decode decodes ContextsImportBadRequest from json.

func (*ContextsImportBadRequest) Encode

func (s *ContextsImportBadRequest) Encode(e *jx.Encoder)

Encode encodes ContextsImportBadRequest as json.

func (*ContextsImportBadRequest) MarshalJSON

func (s *ContextsImportBadRequest) MarshalJSON() ([]byte, error)

MarshalJSON implements stdjson.Marshaler.

func (*ContextsImportBadRequest) UnmarshalJSON

func (s *ContextsImportBadRequest) UnmarshalJSON(data []byte) error

UnmarshalJSON implements stdjson.Unmarshaler.

type ContextsImportCreated

type ContextsImportCreated struct{}

ContextsImportCreated is response for ContextsImport operation.

type ContextsImportForbidden

type ContextsImportForbidden Error

func (*ContextsImportForbidden) Decode

func (s *ContextsImportForbidden) Decode(d *jx.Decoder) error

Decode decodes ContextsImportForbidden from json.

func (*ContextsImportForbidden) Encode

func (s *ContextsImportForbidden) Encode(e *jx.Encoder)

Encode encodes ContextsImportForbidden as json.

func (*ContextsImportForbidden) MarshalJSON

func (s *ContextsImportForbidden) MarshalJSON() ([]byte, error)

MarshalJSON implements stdjson.Marshaler.

func (*ContextsImportForbidden) UnmarshalJSON

func (s *ContextsImportForbidden) UnmarshalJSON(data []byte) error

UnmarshalJSON implements stdjson.Unmarshaler.

type ContextsImportParams

type ContextsImportParams struct {
	// ID приложения, для которого импортируются контексты.
	XApplication uuid.UUID
}

ContextsImportParams is parameters of ContextsImport operation.

type ContextsImportReq

type ContextsImportReq interface {
	// contains filtered or unexported methods
}

type ContextsImportReqTextCsv

type ContextsImportReqTextCsv struct {
	Data io.Reader
}

func (ContextsImportReqTextCsv) Read

func (s ContextsImportReqTextCsv) Read(p []byte) (n int, err error)

Read reads data from the Data reader.

Kept to satisfy the io.Reader interface.

type ContextsImportReqTextTsv

type ContextsImportReqTextTsv struct {
	Data io.Reader
}

func (ContextsImportReqTextTsv) Read

func (s ContextsImportReqTextTsv) Read(p []byte) (n int, err error)

Read reads data from the Data reader.

Kept to satisfy the io.Reader interface.

type ContextsImportRes

type ContextsImportRes interface {
	// contains filtered or unexported methods
}

type ContextsImportUnprocessableEntityApplicationJSON

type ContextsImportUnprocessableEntityApplicationJSON []ContextsImportUnprocessableEntityItem

func (*ContextsImportUnprocessableEntityApplicationJSON) Decode

Decode decodes ContextsImportUnprocessableEntityApplicationJSON from json.

func (ContextsImportUnprocessableEntityApplicationJSON) Encode

Encode encodes ContextsImportUnprocessableEntityApplicationJSON as json.

func (ContextsImportUnprocessableEntityApplicationJSON) MarshalJSON

MarshalJSON implements stdjson.Marshaler.

func (*ContextsImportUnprocessableEntityApplicationJSON) UnmarshalJSON

UnmarshalJSON implements stdjson.Unmarshaler.

func (ContextsImportUnprocessableEntityApplicationJSON) Validate

type ContextsImportUnprocessableEntityItem

type ContextsImportUnprocessableEntityItem struct {
	// Индекс строки в таблице за исключением строки
	// заголовка.
	Index int `json:"index"`
	// Данные импортируемые строкой таблицы.
	Row ContextsImportUnprocessableEntityItemRow `json:"row"`
	// Ошибки валидации строки.
	Errors []string `json:"errors"`
}

func (*ContextsImportUnprocessableEntityItem) Decode

Decode decodes ContextsImportUnprocessableEntityItem from json.

func (*ContextsImportUnprocessableEntityItem) Encode

Encode implements json.Marshaler.

func (*ContextsImportUnprocessableEntityItem) GetErrors

GetErrors returns the value of Errors.

func (*ContextsImportUnprocessableEntityItem) GetIndex

GetIndex returns the value of Index.

func (*ContextsImportUnprocessableEntityItem) GetRow

GetRow returns the value of Row.

func (*ContextsImportUnprocessableEntityItem) MarshalJSON

func (s *ContextsImportUnprocessableEntityItem) MarshalJSON() ([]byte, error)

MarshalJSON implements stdjson.Marshaler.

func (*ContextsImportUnprocessableEntityItem) SetErrors

func (s *ContextsImportUnprocessableEntityItem) SetErrors(val []string)

SetErrors sets the value of Errors.

func (*ContextsImportUnprocessableEntityItem) SetIndex

func (s *ContextsImportUnprocessableEntityItem) SetIndex(val int)

SetIndex sets the value of Index.

func (*ContextsImportUnprocessableEntityItem) SetRow

SetRow sets the value of Row.

func (*ContextsImportUnprocessableEntityItem) UnmarshalJSON

func (s *ContextsImportUnprocessableEntityItem) UnmarshalJSON(data []byte) error

UnmarshalJSON implements stdjson.Unmarshaler.

type ContextsImportUnprocessableEntityItemRow

type ContextsImportUnprocessableEntityItemRow map[string]string

Данные импортируемые строкой таблицы.

func (*ContextsImportUnprocessableEntityItemRow) Decode

Decode decodes ContextsImportUnprocessableEntityItemRow from json.

func (ContextsImportUnprocessableEntityItemRow) Encode

Encode implements json.Marshaler.

func (ContextsImportUnprocessableEntityItemRow) MarshalJSON

MarshalJSON implements stdjson.Marshaler.

func (*ContextsImportUnprocessableEntityItemRow) UnmarshalJSON

func (s *ContextsImportUnprocessableEntityItemRow) UnmarshalJSON(data []byte) error

UnmarshalJSON implements stdjson.Unmarshaler.

type ContextsListOKHeaders

type ContextsListOKHeaders struct {
	XCount   int64
	Response []Context
}

ContextsListOKHeaders wraps []Context with response headers.

func (*ContextsListOKHeaders) GetResponse

func (s *ContextsListOKHeaders) GetResponse() []Context

GetResponse returns the value of Response.

func (*ContextsListOKHeaders) GetXCount

func (s *ContextsListOKHeaders) GetXCount() int64

GetXCount returns the value of XCount.

func (*ContextsListOKHeaders) SetResponse

func (s *ContextsListOKHeaders) SetResponse(val []Context)

SetResponse sets the value of Response.

func (*ContextsListOKHeaders) SetXCount

func (s *ContextsListOKHeaders) SetXCount(val int64)

SetXCount sets the value of XCount.

func (*ContextsListOKHeaders) Validate

func (s *ContextsListOKHeaders) Validate() error

type ContextsListParams

type ContextsListParams struct {
	Offset OptInt32
	Limit  OptInt32
	// Фильтрация по ID контекстов.
	ID []uuid.UUID
	// Фильтрация по ID традиций.
	TID []int32
	// Фильтрация по ID приложения.
	AppID []uuid.UUID
	// Фильтрация по вхождению подстроки в описание
	// контекста.
	Desc OptString
}

ContextsListParams is parameters of ContextsList operation.

type ContextsListRes

type ContextsListRes interface {
	// contains filtered or unexported methods
}

type Error

type Error struct {
	// Описание ошибки.
	ErrorMessage string `json:"error_message"`
}

Ref: #/components/schemas/Error

func (*Error) Decode

func (s *Error) Decode(d *jx.Decoder) error

Decode decodes Error from json.

func (*Error) Encode

func (s *Error) Encode(e *jx.Encoder)

Encode implements json.Marshaler.

func (*Error) GetErrorMessage

func (s *Error) GetErrorMessage() string

GetErrorMessage returns the value of ErrorMessage.

func (*Error) MarshalJSON

func (s *Error) MarshalJSON() ([]byte, error)

MarshalJSON implements stdjson.Marshaler.

func (*Error) SetErrorMessage

func (s *Error) SetErrorMessage(val string)

SetErrorMessage sets the value of ErrorMessage.

func (*Error) UnmarshalJSON

func (s *Error) UnmarshalJSON(data []byte) error

UnmarshalJSON implements stdjson.Unmarshaler.

type Invoker

type Invoker interface {
	// ActivitiesCreate invokes ActivitiesCreate operation.
	//
	// Каждая из активностей опционально может иметь
	// метрики и артефакт.
	// Запись активностей доступна в коротком и расширенном
	// форматах.
	// #### Короткий формат
	// Передается только массив активностей. Если они
	// ссылаются на артефакты, эти артефакты должны быть
	// предварительно [загружены](#operation/ArtefactsCreate). Ответ на
	// такой запрос тоже включает в себя только массив с
	// активностями.
	// #### Расширенный формат
	// В этом формате передается объект, который должен
	// содержать активности в массиве, аналогичном
	// короткому формату, и опционально может включать в
	// себя еще артефакты для создания. В ответе на такой
	// запрос, аналогично, возвращается объект, содержащий
	// те же ключи. В возвращаемом массиве артефактов будут
	// ссылки, по которым эти артефакты должны быть
	// загружены.
	// > Ссылки имеют ограниченный срок жизни. Если данные
	// артефакта не были загружены в рамках этого периода,
	// то нужно [запросить новую ссылку](#operation/ArtefactUploadURL).
	// > До тех пор, пока указанные в активности артефакты не
	// будут загружены, эта активность с ее баллами не будет
	// учитываться в прогрессе традиции игрока.
	// После загрузки данных артефакта по полученной ссылке,
	//  нужно [подтвердить что загрузка
	// завершена](#operation/ArtefactSetUploaded).
	//
	// POST /activities
	ActivitiesCreate(ctx context.Context, request ActivitiesCreateReq) (ActivitiesCreateRes, error)
	// ActivitiesList invokes ActivitiesList operation.
	//
	// Если какие-то из указанных активностей не будут
	// найдены, то они просто будут отсутствовать в ответе.
	//
	// GET /activities
	ActivitiesList(ctx context.Context, params ActivitiesListParams) ([]Activity, error)
	// ActivitiesMetricsList invokes ActivitiesMetricsList operation.
	//
	// Необходимо указать параметры выбора контекстов.
	// Это могут быть либо идентификаторы конкретных
	// контекстов `context_ids`.
	// Либо набор фильтров `context_property` и/или ID приложения
	// `application_id`.
	//
	// GET /activities/metrics
	ActivitiesMetricsList(ctx context.Context, params ActivitiesMetricsListParams) (ActivitiesMetricsListRes, error)
	// ActivitiesScores invokes ActivitiesScores operation.
	//
	// **Обязательно** указание либо `tradition_id`, либо `context_ids`;
	// эти параметры взаимоисключающие.
	//
	// GET /activities/scores
	ActivitiesScores(ctx context.Context, params ActivitiesScoresParams) (ActivitiesScoresRes, error)
	// ActivitiesScoresByTraditions invokes ActivitiesScoresByTraditions operation.
	//
	// Баллы сгруппированные по традициям.
	//
	// GET /activities/scores/traditions
	ActivitiesScoresByTraditions(ctx context.Context, params ActivitiesScoresByTraditionsParams) (ActivitiesScoresByTraditionsRes, error)
	// ActivityRead invokes ActivityRead operation.
	//
	// Чтение активности.
	//
	// GET /activities/{activity_id}
	ActivityRead(ctx context.Context, params ActivityReadParams) (ActivityReadRes, error)
	// ArtefactSetUploaded invokes ArtefactSetUploaded operation.
	//
	// Подтверждение загрузки артефакта.
	//
	// POST /artefacts/{artefact_id}/set-uploaded
	ArtefactSetUploaded(ctx context.Context, params ArtefactSetUploadedParams) (ArtefactSetUploadedRes, error)
	// ArtefactTypesList invokes ArtefactTypesList operation.
	//
	// Справочник типов артефактов.
	//
	// GET /artefact-types
	ArtefactTypesList(ctx context.Context) ([]ArtefactTypesListOKItem, error)
	// ArtefactUploadURL invokes ArtefactUploadURL operation.
	//
	// Ссылка для загрузки данных артефактом имеет
	// ограниченный срок жизни. После его завершения, если
	// данные артефакта еще не были успешно загружены, нужно
	// запрашивать новую ссылку. Загрузку данных по ссылке
	// нужно выполнять методом PUT.
	//
	// GET /artefacts/{artefact_id}/upload-url
	ArtefactUploadURL(ctx context.Context, params ArtefactUploadURLParams) (ArtefactUploadURLRes, error)
	// ArtefactsCreate invokes ArtefactsCreate operation.
	//
	// Артефакт предварительно загружается для передачи
	// его в активности.
	//
	// POST /artefacts
	ArtefactsCreate(ctx context.Context, request *ArtefactsCreateReqWithContentType, params ArtefactsCreateParams) (ArtefactsCreateRes, error)
	// ContextIDsList invokes ContextIDsList operation.
	//
	// Идентификаторы контекстов выбранные по тому же
	// принципу что и в ActivitiesMetricsList.
	// Обязательно указание либо `application_id`, либо `property`.
	// Допускаются оба параметра.
	//
	// GET /contexts/id
	ContextIDsList(ctx context.Context, params ContextIDsListParams) (ContextIDsListRes, error)
	// ContextTraditionID invokes ContextTraditionID operation.
	//
	// Традиция контекста.
	//
	// GET /contexts/{context_id}/tradition-id
	ContextTraditionID(ctx context.Context, params ContextTraditionIDParams) (ContextTraditionIDRes, error)
	// ContextsImport invokes ContextsImport operation.
	//
	// Импортируемая таблица должна содержать колонки `id` и
	// `description`.
	// Содержащие в ячейках идентификатор (UUID) и описание
	// контекста соответственно.
	// Оставшиеся колонки таблицы будут восприняты как
	// свойства контекстов.
	// Тип значения для свойства определяется на основе
	// значений в ячейках колонки.
	// Если все значения можно интерпретировать как
	// числовые, то тип значения у свойства будет числовой.
	// Если хоть одно значение не приводится к числу, то тип
	// значения определяется как строковый.
	// В заголовках запроса так же необходимо указать ID
	// приложения с контекстами которого будет выполнятся
	// работа.
	//
	// POST /contexts/import
	ContextsImport(ctx context.Context, request ContextsImportReq, params ContextsImportParams) (ContextsImportRes, error)
	// ContextsList invokes ContextsList operation.
	//
	// Список контекстов.
	//
	// GET /contexts
	ContextsList(ctx context.Context, params ContextsListParams) (ContextsListRes, error)
}

Invoker invokes operations described by OpenAPI v3 specification.

type NilActivityQuarantine

type NilActivityQuarantine struct {
	Value ActivityQuarantine
	Null  bool
}

NilActivityQuarantine is nullable ActivityQuarantine.

func NewNilActivityQuarantine

func NewNilActivityQuarantine(v ActivityQuarantine) NilActivityQuarantine

NewNilActivityQuarantine returns new NilActivityQuarantine with value set to v.

func (*NilActivityQuarantine) Decode

func (o *NilActivityQuarantine) Decode(d *jx.Decoder) error

Decode decodes ActivityQuarantine from json.

func (NilActivityQuarantine) Encode

func (o NilActivityQuarantine) Encode(e *jx.Encoder)

Encode encodes ActivityQuarantine as json.

func (NilActivityQuarantine) Get

Get returns value and boolean that denotes whether value was set.

func (NilActivityQuarantine) IsNull

func (o NilActivityQuarantine) IsNull() bool

IsSet returns true if value is Null.

func (NilActivityQuarantine) MarshalJSON

func (s NilActivityQuarantine) MarshalJSON() ([]byte, error)

MarshalJSON implements stdjson.Marshaler.

func (NilActivityQuarantine) Or

Or returns value if set, or given parameter if does not.

func (*NilActivityQuarantine) SetTo

SetTo sets value to v.

func (*NilActivityQuarantine) SetToNull

func (o *NilActivityQuarantine) SetToNull()

SetNull sets value to null.

func (*NilActivityQuarantine) UnmarshalJSON

func (s *NilActivityQuarantine) UnmarshalJSON(data []byte) error

UnmarshalJSON implements stdjson.Unmarshaler.

type NilActivityReadOKQuarantine

type NilActivityReadOKQuarantine struct {
	Value ActivityReadOKQuarantine
	Null  bool
}

NilActivityReadOKQuarantine is nullable ActivityReadOKQuarantine.

func NewNilActivityReadOKQuarantine

func NewNilActivityReadOKQuarantine(v ActivityReadOKQuarantine) NilActivityReadOKQuarantine

NewNilActivityReadOKQuarantine returns new NilActivityReadOKQuarantine with value set to v.

func (*NilActivityReadOKQuarantine) Decode

Decode decodes ActivityReadOKQuarantine from json.

func (NilActivityReadOKQuarantine) Encode

func (o NilActivityReadOKQuarantine) Encode(e *jx.Encoder)

Encode encodes ActivityReadOKQuarantine as json.

func (NilActivityReadOKQuarantine) Get

Get returns value and boolean that denotes whether value was set.

func (NilActivityReadOKQuarantine) IsNull

func (o NilActivityReadOKQuarantine) IsNull() bool

IsSet returns true if value is Null.

func (NilActivityReadOKQuarantine) MarshalJSON

func (s NilActivityReadOKQuarantine) MarshalJSON() ([]byte, error)

MarshalJSON implements stdjson.Marshaler.

func (NilActivityReadOKQuarantine) Or

Or returns value if set, or given parameter if does not.

func (*NilActivityReadOKQuarantine) SetTo

SetTo sets value to v.

func (*NilActivityReadOKQuarantine) SetToNull

func (o *NilActivityReadOKQuarantine) SetToNull()

SetNull sets value to null.

func (*NilActivityReadOKQuarantine) UnmarshalJSON

func (s *NilActivityReadOKQuarantine) UnmarshalJSON(data []byte) error

UnmarshalJSON implements stdjson.Unmarshaler.

type NilActivityScores

type NilActivityScores struct {
	Value ActivityScores
	Null  bool
}

NilActivityScores is nullable ActivityScores.

func NewNilActivityScores

func NewNilActivityScores(v ActivityScores) NilActivityScores

NewNilActivityScores returns new NilActivityScores with value set to v.

func (*NilActivityScores) Decode

func (o *NilActivityScores) Decode(d *jx.Decoder) error

Decode decodes ActivityScores from json.

func (NilActivityScores) Encode

func (o NilActivityScores) Encode(e *jx.Encoder)

Encode encodes ActivityScores as json.

func (NilActivityScores) Get

func (o NilActivityScores) Get() (v ActivityScores, ok bool)

Get returns value and boolean that denotes whether value was set.

func (NilActivityScores) IsNull

func (o NilActivityScores) IsNull() bool

IsSet returns true if value is Null.

func (NilActivityScores) MarshalJSON

func (s NilActivityScores) MarshalJSON() ([]byte, error)

MarshalJSON implements stdjson.Marshaler.

func (NilActivityScores) Or

Or returns value if set, or given parameter if does not.

func (*NilActivityScores) SetTo

func (o *NilActivityScores) SetTo(v ActivityScores)

SetTo sets value to v.

func (*NilActivityScores) SetToNull

func (o *NilActivityScores) SetToNull()

SetNull sets value to null.

func (*NilActivityScores) UnmarshalJSON

func (s *NilActivityScores) UnmarshalJSON(data []byte) error

UnmarshalJSON implements stdjson.Unmarshaler.

type NilFloat64

type NilFloat64 struct {
	Value float64
	Null  bool
}

NilFloat64 is nullable float64.

func NewNilFloat64

func NewNilFloat64(v float64) NilFloat64

NewNilFloat64 returns new NilFloat64 with value set to v.

func (*NilFloat64) Decode

func (o *NilFloat64) Decode(d *jx.Decoder) error

Decode decodes float64 from json.

func (NilFloat64) Encode

func (o NilFloat64) Encode(e *jx.Encoder)

Encode encodes float64 as json.

func (NilFloat64) Get

func (o NilFloat64) Get() (v float64, ok bool)

Get returns value and boolean that denotes whether value was set.

func (NilFloat64) IsNull

func (o NilFloat64) IsNull() bool

IsSet returns true if value is Null.

func (NilFloat64) MarshalJSON

func (s NilFloat64) MarshalJSON() ([]byte, error)

MarshalJSON implements stdjson.Marshaler.

func (NilFloat64) Or

func (o NilFloat64) Or(d float64) float64

Or returns value if set, or given parameter if does not.

func (*NilFloat64) SetTo

func (o *NilFloat64) SetTo(v float64)

SetTo sets value to v.

func (*NilFloat64) SetToNull

func (o *NilFloat64) SetToNull()

SetNull sets value to null.

func (*NilFloat64) UnmarshalJSON

func (s *NilFloat64) UnmarshalJSON(data []byte) error

UnmarshalJSON implements stdjson.Unmarshaler.

type NilString

type NilString struct {
	Value string
	Null  bool
}

NilString is nullable string.

func NewNilString

func NewNilString(v string) NilString

NewNilString returns new NilString with value set to v.

func (*NilString) Decode

func (o *NilString) Decode(d *jx.Decoder) error

Decode decodes string from json.

func (NilString) Encode

func (o NilString) Encode(e *jx.Encoder)

Encode encodes string as json.

func (NilString) Get

func (o NilString) Get() (v string, ok bool)

Get returns value and boolean that denotes whether value was set.

func (NilString) IsNull

func (o NilString) IsNull() bool

IsSet returns true if value is Null.

func (NilString) MarshalJSON

func (s NilString) MarshalJSON() ([]byte, error)

MarshalJSON implements stdjson.Marshaler.

func (NilString) Or

func (o NilString) Or(d string) string

Or returns value if set, or given parameter if does not.

func (*NilString) SetTo

func (o *NilString) SetTo(v string)

SetTo sets value to v.

func (*NilString) SetToNull

func (o *NilString) SetToNull()

SetNull sets value to null.

func (*NilString) UnmarshalJSON

func (s *NilString) UnmarshalJSON(data []byte) error

UnmarshalJSON implements stdjson.Unmarshaler.

type NilUUID

type NilUUID struct {
	Value uuid.UUID
	Null  bool
}

NilUUID is nullable uuid.UUID.

func NewNilUUID

func NewNilUUID(v uuid.UUID) NilUUID

NewNilUUID returns new NilUUID with value set to v.

func (*NilUUID) Decode

func (o *NilUUID) Decode(d *jx.Decoder) error

Decode decodes uuid.UUID from json.

func (NilUUID) Encode

func (o NilUUID) Encode(e *jx.Encoder)

Encode encodes uuid.UUID as json.

func (NilUUID) Get

func (o NilUUID) Get() (v uuid.UUID, ok bool)

Get returns value and boolean that denotes whether value was set.

func (NilUUID) IsNull

func (o NilUUID) IsNull() bool

IsSet returns true if value is Null.

func (NilUUID) MarshalJSON

func (s NilUUID) MarshalJSON() ([]byte, error)

MarshalJSON implements stdjson.Marshaler.

func (NilUUID) Or

func (o NilUUID) Or(d uuid.UUID) uuid.UUID

Or returns value if set, or given parameter if does not.

func (*NilUUID) SetTo

func (o *NilUUID) SetTo(v uuid.UUID)

SetTo sets value to v.

func (*NilUUID) SetToNull

func (o *NilUUID) SetToNull()

SetNull sets value to null.

func (*NilUUID) UnmarshalJSON

func (s *NilUUID) UnmarshalJSON(data []byte) error

UnmarshalJSON implements stdjson.Unmarshaler.

type OptActivityWriteMetrics

type OptActivityWriteMetrics struct {
	Value ActivityWriteMetrics
	Set   bool
}

OptActivityWriteMetrics is optional ActivityWriteMetrics.

func NewOptActivityWriteMetrics

func NewOptActivityWriteMetrics(v ActivityWriteMetrics) OptActivityWriteMetrics

NewOptActivityWriteMetrics returns new OptActivityWriteMetrics with value set to v.

func (*OptActivityWriteMetrics) Decode

func (o *OptActivityWriteMetrics) Decode(d *jx.Decoder) error

Decode decodes ActivityWriteMetrics from json.

func (OptActivityWriteMetrics) Encode

func (o OptActivityWriteMetrics) Encode(e *jx.Encoder)

Encode encodes ActivityWriteMetrics as json.

func (OptActivityWriteMetrics) Get

Get returns value and boolean that denotes whether value was set.

func (OptActivityWriteMetrics) IsSet

func (o OptActivityWriteMetrics) IsSet() bool

IsSet returns true if OptActivityWriteMetrics was set.

func (OptActivityWriteMetrics) MarshalJSON

func (s OptActivityWriteMetrics) MarshalJSON() ([]byte, error)

MarshalJSON implements stdjson.Marshaler.

func (OptActivityWriteMetrics) Or

Or returns value if set, or given parameter if does not.

func (*OptActivityWriteMetrics) Reset

func (o *OptActivityWriteMetrics) Reset()

Reset unsets value.

func (*OptActivityWriteMetrics) SetTo

SetTo sets value to v.

func (*OptActivityWriteMetrics) UnmarshalJSON

func (s *OptActivityWriteMetrics) UnmarshalJSON(data []byte) error

UnmarshalJSON implements stdjson.Unmarshaler.

type OptArtefactID

type OptArtefactID struct {
	Value ArtefactID
	Set   bool
}

OptArtefactID is optional ArtefactID.

func NewOptArtefactID

func NewOptArtefactID(v ArtefactID) OptArtefactID

NewOptArtefactID returns new OptArtefactID with value set to v.

func (*OptArtefactID) Decode

func (o *OptArtefactID) Decode(d *jx.Decoder) error

Decode decodes ArtefactID from json.

func (OptArtefactID) Encode

func (o OptArtefactID) Encode(e *jx.Encoder)

Encode encodes ArtefactID as json.

func (OptArtefactID) Get

func (o OptArtefactID) Get() (v ArtefactID, ok bool)

Get returns value and boolean that denotes whether value was set.

func (OptArtefactID) IsSet

func (o OptArtefactID) IsSet() bool

IsSet returns true if OptArtefactID was set.

func (OptArtefactID) MarshalJSON

func (s OptArtefactID) MarshalJSON() ([]byte, error)

MarshalJSON implements stdjson.Marshaler.

func (OptArtefactID) Or

Or returns value if set, or given parameter if does not.

func (*OptArtefactID) Reset

func (o *OptArtefactID) Reset()

Reset unsets value.

func (*OptArtefactID) SetTo

func (o *OptArtefactID) SetTo(v ArtefactID)

SetTo sets value to v.

func (*OptArtefactID) UnmarshalJSON

func (s *OptArtefactID) UnmarshalJSON(data []byte) error

UnmarshalJSON implements stdjson.Unmarshaler.

type OptDateTime

type OptDateTime struct {
	Value time.Time
	Set   bool
}

OptDateTime is optional time.Time.

func NewOptDateTime

func NewOptDateTime(v time.Time) OptDateTime

NewOptDateTime returns new OptDateTime with value set to v.

func (OptDateTime) Get

func (o OptDateTime) Get() (v time.Time, ok bool)

Get returns value and boolean that denotes whether value was set.

func (OptDateTime) IsSet

func (o OptDateTime) IsSet() bool

IsSet returns true if OptDateTime was set.

func (OptDateTime) Or

func (o OptDateTime) Or(d time.Time) time.Time

Or returns value if set, or given parameter if does not.

func (*OptDateTime) Reset

func (o *OptDateTime) Reset()

Reset unsets value.

func (*OptDateTime) SetTo

func (o *OptDateTime) SetTo(v time.Time)

SetTo sets value to v.

type OptInt32

type OptInt32 struct {
	Value int32
	Set   bool
}

OptInt32 is optional int32.

func NewOptInt32

func NewOptInt32(v int32) OptInt32

NewOptInt32 returns new OptInt32 with value set to v.

func (OptInt32) Get

func (o OptInt32) Get() (v int32, ok bool)

Get returns value and boolean that denotes whether value was set.

func (OptInt32) IsSet

func (o OptInt32) IsSet() bool

IsSet returns true if OptInt32 was set.

func (OptInt32) Or

func (o OptInt32) Or(d int32) int32

Or returns value if set, or given parameter if does not.

func (*OptInt32) Reset

func (o *OptInt32) Reset()

Reset unsets value.

func (*OptInt32) SetTo

func (o *OptInt32) SetTo(v int32)

SetTo sets value to v.

type OptString

type OptString struct {
	Value string
	Set   bool
}

OptString is optional string.

func NewOptString

func NewOptString(v string) OptString

NewOptString returns new OptString with value set to v.

func (OptString) Get

func (o OptString) Get() (v string, ok bool)

Get returns value and boolean that denotes whether value was set.

func (OptString) IsSet

func (o OptString) IsSet() bool

IsSet returns true if OptString was set.

func (OptString) Or

func (o OptString) Or(d string) string

Or returns value if set, or given parameter if does not.

func (*OptString) Reset

func (o *OptString) Reset()

Reset unsets value.

func (*OptString) SetTo

func (o *OptString) SetTo(v string)

SetTo sets value to v.

type OptUUID

type OptUUID struct {
	Value uuid.UUID
	Set   bool
}

OptUUID is optional uuid.UUID.

func NewOptUUID

func NewOptUUID(v uuid.UUID) OptUUID

NewOptUUID returns new OptUUID with value set to v.

func (OptUUID) Get

func (o OptUUID) Get() (v uuid.UUID, ok bool)

Get returns value and boolean that denotes whether value was set.

func (OptUUID) IsSet

func (o OptUUID) IsSet() bool

IsSet returns true if OptUUID was set.

func (OptUUID) Or

func (o OptUUID) Or(d uuid.UUID) uuid.UUID

Or returns value if set, or given parameter if does not.

func (*OptUUID) Reset

func (o *OptUUID) Reset()

Reset unsets value.

func (*OptUUID) SetTo

func (o *OptUUID) SetTo(v uuid.UUID)

SetTo sets value to v.

type Option

type Option interface {
	ClientOption
}

Option is config option.

func WithMeterProvider

func WithMeterProvider(provider metric.MeterProvider) Option

WithMeterProvider specifies a meter provider to use for creating a meter.

If none is specified, the otel.GetMeterProvider() is used.

func WithTracerProvider

func WithTracerProvider(provider trace.TracerProvider) Option

WithTracerProvider specifies a tracer provider to use for creating a tracer.

If none is specified, the global provider is used.

type PlayerID

type PlayerID uuid.UUID

func (*PlayerID) Decode

func (s *PlayerID) Decode(d *jx.Decoder) error

Decode decodes PlayerID from json.

func (PlayerID) Encode

func (s PlayerID) Encode(e *jx.Encoder)

Encode encodes PlayerID as json.

func (PlayerID) MarshalJSON

func (s PlayerID) MarshalJSON() ([]byte, error)

MarshalJSON implements stdjson.Marshaler.

func (*PlayerID) UnmarshalJSON

func (s *PlayerID) UnmarshalJSON(data []byte) error

UnmarshalJSON implements stdjson.Unmarshaler.

type SecuritySource

type SecuritySource interface {
	// BerlogaJWT provides BerlogaJWT security value.
	// JWT, полученный эндпоинтом
	// [issue-token](/berloga-idp/docs/#operation/IssueToken).
	BerlogaJWT(ctx context.Context, operationName string) (BerlogaJWT, error)
	// ServiceKey provides ServiceKey security value.
	ServiceKey(ctx context.Context, operationName string) (ServiceKey, error)
	// TalentOAuth provides TalentOAuth security value.
	// JWT, полученный OAuth провайдером платформы Талант.
	TalentOAuth(ctx context.Context, operationName string) (TalentOAuth, error)
}

SecuritySource is provider of security values (tokens, passwords, etc.).

type ServiceKey

type ServiceKey struct {
	APIKey string
}

func (*ServiceKey) GetAPIKey

func (s *ServiceKey) GetAPIKey() string

GetAPIKey returns the value of APIKey.

func (*ServiceKey) SetAPIKey

func (s *ServiceKey) SetAPIKey(val string)

SetAPIKey sets the value of APIKey.

type TalentOAuth

type TalentOAuth struct {
	Token string
}

func (*TalentOAuth) GetToken

func (s *TalentOAuth) GetToken() string

GetToken returns the value of Token.

func (*TalentOAuth) SetToken

func (s *TalentOAuth) SetToken(val string)

SetToken sets the value of Token.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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