response

package
v0.0.0-...-15b5fa4 Latest Latest
Warning

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

Go to latest
Published: Jun 2, 2024 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func WriteResponse

func WriteResponse(writer io.Writer, r encode.Marshaler) error

Types

type Code

type Code uint8
const (
	StatusError           Code = 1
	StatusCriticalError   Code = 2
	StatusUnknownCommand  Code = 3
	StatusOK              Code = 100
	StatusReadyToTransfer Code = 101
)

type Response

type Response struct {
	Data interface{}
	Info string
	Code Code
}

func (Response) MarshalBINN

func (r Response) MarshalBINN() ([]byte, error)

func (*Response) UnmarshalBINN

func (r *Response) UnmarshalBINN(bytes []byte) error

Jump to

Keyboard shortcuts

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