types

package
v0.0.0-...-9da5f0f Latest Latest
Warning

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

Go to latest
Published: Oct 16, 2019 License: MIT Imports: 3 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Adapter

type Adapter interface {
	BasePlugin
	Start()
}

type BasePlugin

type BasePlugin interface {
	GetManifest() Manifest
}

type BasicInfo

type BasicInfo struct {
	Name        string
	Version     string
	Author      string
	License     string
	URL         string
	Description string
}

type Buffer

type Buffer chan Packet

type BuildInfo

type BuildInfo struct {
	BuildTag      string
	BuildDate     string
	GitCommitSHA1 string
	GitTag        string
}

type Converter

type Converter interface {
	Adapter
	IsConvertible(from Format, to Format) bool
	Convert(packet Packet, to Format) (bool, []Packet)
}

type Format

type Format struct {
	API      string `json:"api"`
	Version  string `json:"version"`
	Method   string `json:"method"`
	Protocol string `json:"protocol"`
}

func (Format) String

func (f Format) String() string
type Head struct {
	UUID                   string `json:"uuid"`
	From                   string `json:"from"`
	To                     string `json:"to"`
	ReplyToUUID            string `json:"reply_to_uuid"`
	AcknowledgeChannelUUID string `json:"acknowledge_channel_uuid"`
	Format                 Format `json:"format"`
}

type Manifest

type Manifest struct {
	BasicInfo BasicInfo
	BuildInfo BuildInfo
}

type Packet

type Packet struct {
	Head Head            `json:"head"`
	Body json.RawMessage `json:"body"`
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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