messagebroker

package
v0.0.2 Latest Latest
Warning

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

Go to latest
Published: Nov 30, 2022 License: BSD-3-Clause Imports: 3 Imported by: 11

Documentation

Index

Constants

View Source
const TOPIC = "UNWINDIA_MATCH"

Variables

View Source
var EventsName = map[int]string{
	0: "UNWINDIA_MATCH_NEW",
	1: "UNWINDIA_MATCH_READY_A",
	2: "UNWINDIA_MATCH_READY_B",
	3: "UNWINDIA_MATCH_READY_ALL",
	4: "UNWINDIA_MATCH_FINISHED",
}
View Source
var EventsValue = map[string]MatchEvent{
	"UNWINDIA_MATCH_NEW":       UNWINDIA_MATCH_NEW,
	"UNWINDIA_MATCH_READY_A":   UNWINDIA_MATCH_READY_A,
	"UNWINDIA_MATCH_READY_B":   UNWINDIA_MATCH_READY_B,
	"UNWINDIA_MATCH_READY_ALL": UNWINDIA_MATCH_READY_ALL,
	"UNWINDIA_MATCH_FINISHED":  UNWINDIA_MATCH_FINISHED,
}
View Source
var MessageTypesName = map[int]string{
	0: "create",
	1: "update",
	2: "delete",
}
View Source
var PulsarAuthName = map[int]string{
	0: "simple",
	1: "oauth2",
}

Functions

This section is empty.

Types

type MatchEvent

type MatchEvent int
const (
	UNWINDIA_MATCH_NEW MatchEvent = iota
	UNWINDIA_MATCH_READY_A
	UNWINDIA_MATCH_READY_B
	UNWINDIA_MATCH_READY_ALL
	UNWINDIA_MATCH_FINISHED
)

func (MatchEvent) String

func (e MatchEvent) String() string

func (*MatchEvent) UnmarshalJSON

func (e *MatchEvent) UnmarshalJSON(b []byte) error

UnmarshalJSON unmarshals b into MatchEvent.

type MatchMessage

type MatchMessage struct {
	Message
	SubType MatchEvent `json:"subtype"`
	Data    *matchservice.MatchInfo
}

type Message

type Message struct {
	Type    MessageTypes `json:"type"`
	SubType string       `json:"subtype"`
	Data    interface{}  `json:"data,omitempty"`
}

type MessageTypes

type MessageTypes int
const (
	MessageTypeCreated MessageTypes = iota
	MessageTypeUpdated
	MessageTypeDeleted
)

func (MessageTypes) String

func (m MessageTypes) String() string

func (*MessageTypes) UnmarshalJSON

func (m *MessageTypes) UnmarshalJSON(b []byte) error

UnmarshalJSON unmarshals b into MessageTypes.

type NewContest

type NewContest struct {
}

type PulsarAuth

type PulsarAuth int
const (
	AUTH_SIMPLE PulsarAuth = iota
	AUTH_OAUTH2
)

func (PulsarAuth) String

func (p PulsarAuth) String() string

func (*PulsarAuth) Unmarshal

func (p *PulsarAuth) Unmarshal(data string) error

func (*PulsarAuth) UnmarshalJSON

func (p *PulsarAuth) UnmarshalJSON(b []byte) error

UnmarshalJSON unmarshals b into PulsarAuth.

func (*PulsarAuth) UnmarshalText

func (p *PulsarAuth) UnmarshalText(text []byte) error

type Response

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

Jump to

Keyboard shortcuts

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