notehub

package
v1.1.3 Latest Latest
Warning

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

Go to latest
Published: Oct 15, 2019 License: MIT Imports: 1 Imported by: 2

Documentation

Index

Constants

View Source
const DefaultAPIService = "api.notefile.net"

DefaultAPIService (golint)

View Source
const DefaultAPITopicReq = "/req"

DefaultAPITopicReq (golint)

View Source
const HubAppHandlers = "hub.app.handlers"

HubAppHandlers (golint)

View Source
const HubAppMonitor = "hub.app.monitor"

HubAppMonitor (golint)

View Source
const HubAppUpload = "hub.app.upload.add"

HubAppUpload (golint)

View Source
const HubAppUploadDelete = "hub.app.upload.delete"

HubAppUploadDelete (golint)

View Source
const HubAppUploadRead = "hub.app.upload.get"

HubAppUploadRead (golint)

View Source
const HubAppUploadSet = "hub.app.upload.set"

HubAppUploadSet (golint)

View Source
const HubAppUploads = "hub.app.upload.query"

HubAppUploads (golint)

View Source
const HubDeviceMonitor = "hub.device.monitor"

HubDeviceMonitor (golint)

View Source
const HubDeviceSignal = "hub.device.signal"

HubDeviceSignal (golint)

View Source
const HubFileTypeCardFirmware = "notecard"

HubFileTypeCardFirmware (golint)

View Source
const HubFileTypeUnknown = ""

HubFileTypeUnknown (golint)

View Source
const HubFileTypeUserFirmware = "firmware"

HubFileTypeUserFirmware (golint)

View Source
const HubQuery = "hub.app.data.query"

HubQuery (golint)

Variables

This section is empty.

Functions

This section is empty.

Types

type DbQuery

type DbQuery struct {
	Columns    string `json:"columns,omitempty"`
	Format     string `json:"format,omitempty"`
	Count      bool   `json:"count,omitempty"`
	Offset     int    `json:"offset,omitempty"`
	Limit      int    `json:"limit,omitempty"`
	NoHeader   bool   `json:"noheader,omitempty"`
	Where      string `json:"where,omitempty"`
	Last       string `json:"last,omitempty"`
	Order      string `json:"order,omitempty"`
	Descending bool   `json:"descending,omitempty"`
}

DbQuery is the structure for a database query

type HubRequest

type HubRequest struct {
	notecard.Request `json:",omitempty"`
	AppUID           string            `json:"app,omitempty"`
	FleetUID         string            `json:"fleet,omitempty"`
	DbQuery          *DbQuery          `json:"query,omitempty"`
	Uploads          *[]HubRequestFile `json:"uploads,omitempty"`
	Contains         string            `json:"contains,omitempty"`
	Handlers         *[]string         `json:"handlers,omitempty"`
	FileType         string            `json:"type,omitempty"`
}

HubRequest is is the core data structure for notehub-specific requests

type HubRequestFile

type HubRequestFile struct {
	Name     string                  `json:"name,omitempty"`
	Length   int                     `json:"length,omitempty"`
	MD5      string                  `json:"md5,omitempty"`
	CRC32    uint32                  `json:"crc32,omitempty"`
	Created  int64                   `json:"created,omitempty"`
	Modified int64                   `json:"modified,omitempty"`
	Source   string                  `json:"source,omitempty"`
	Contains string                  `json:"contains,omitempty"`
	Found    string                  `json:"found,omitempty"`
	FileType string                  `json:"type,omitempty"`
	Firmware *HubRequestFileFirmware `json:"firmware,omitempty"`
	// Arbitrary metadata that the user may define - we don't interpret the schema at all
	Info *map[string]interface{} `json:"info,omitempty"`
}

HubRequestFile is is the body of the object uploaded for each file

type HubRequestFileFirmware

type HubRequestFileFirmware struct {
	// The organization accountable for the firmware - a display string
	Organization string `json:"org,omitempty"`
	// A description of the firmware - a display string
	Description string `json:"description,omitempty"`
	// The name and model number of the product containing the firmware - a display string
	Product string `json:"product,omitempty"`
	// The identifier of the only firmware that will be acceptable and downloaded to this device
	Firmware string `json:"firmware,omitempty"`
	// The version number of the firmware, generally major.minor as a string
	Version string `json:"version,omitempty"`
	// The build number of the firmware, generally just a build number as a string
	Build string `json:"build,omitempty"`
	// The build number of the firmware, generally just a date and time
	Built string `json:"built,omitempty"`
	// The entity who built or is responsible for the firmware - a display string
	Builder string `json:"builder,omitempty"`
}

HubRequestFileFirmware is firmware-specific metadata

Jump to

Keyboard shortcuts

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