codes

package
v2.2.0-getDeviceByIP Latest Latest
Warning

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

Go to latest
Published: Jul 6, 2021 License: Apache-2.0 Imports: 2 Imported by: 48

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Code

type Code uint16

A Code is an unsigned 16-bit coap code as defined in the coap spec.

const (
	GET    Code = 1
	POST   Code = 2
	PUT    Code = 3
	DELETE Code = 4
)

Request Codes

const (
	Empty                   Code = 0
	Created                 Code = 65
	Deleted                 Code = 66
	Valid                   Code = 67
	Changed                 Code = 68
	Content                 Code = 69
	Continue                Code = 95
	BadRequest              Code = 128
	Unauthorized            Code = 129
	BadOption               Code = 130
	Forbidden               Code = 131
	NotFound                Code = 132
	MethodNotAllowed        Code = 133
	NotAcceptable           Code = 134
	RequestEntityIncomplete Code = 136
	PreconditionFailed      Code = 140
	RequestEntityTooLarge   Code = 141
	UnsupportedMediaType    Code = 143
	InternalServerError     Code = 160
	NotImplemented          Code = 161
	BadGateway              Code = 162
	ServiceUnavailable      Code = 163
	GatewayTimeout          Code = 164
	ProxyingNotSupported    Code = 165
)

Response Codes

const (
	CSM     Code = 225
	Ping    Code = 226
	Pong    Code = 227
	Release Code = 228
	Abort   Code = 229
)

Signaling Codes for TCP

func ToCode

func ToCode(v string) (Code, error)

func (Code) String

func (c Code) String() string

func (*Code) UnmarshalJSON

func (c *Code) UnmarshalJSON(b []byte) error

UnmarshalJSON unmarshals b into the Code.

Jump to

Keyboard shortcuts

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