response

package
v0.13.3 Latest Latest
Warning

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

Go to latest
Published: May 9, 2023 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type MessageText

type MessageText string
var (
	MessageOK    MessageText = "OK"
	MessageError MessageText = "ERROR"
)

type Response

type Response struct {
	Status  StatusCode  `json:"status" yaml:"status"`
	Message MessageText `json:"message" yaml:"message"`
	Log     string      `json:"log" yaml:"log"`
}

func New

func New(status StatusCode, message MessageText, log string) *Response

func (*Response) Print

func (r *Response) Print(format string)

type StatusCode

type StatusCode int
var (
	StatusOK    StatusCode = 0
	StatusError StatusCode = 1
)

Jump to

Keyboard shortcuts

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