Version: v1.0.3 Latest Latest

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

Go to latest
Published: Aug 12, 2021 License: MIT Imports: 3 Imported by: 0




View Source
const (
	ActuatorPrefix           = "/actuator"
	CertFilePath             = "cert-file"
	CertFilePathDefaultValue = ""
	CertFilePathUsage        = "cert file path is the path of the certificate file"
	KeyFilePath              = "key-file"
	KeyFilePathDefaultValue  = ""
	KeyFilePathUsage         = "key file path is the path of the key file"
	MoxyPrefix               = "/moxy"
	PersistencePath          = "persistence-path"
	PersistenceDefaultValue  = "persistence.db"
	PersistenceUsage         = "persistence path is the path of the file which acts as the persistence layer for this application"
	Port                     = "port"
	PortDefaultValue         = 8080
	PortUsage                = "port is the port number on which the application is running"
	TLSEnabled               = "tls"
	TLSEnabledDefaultValue   = false
	TLSEnabledUsage          = "tls enabled tells whether the application is running on HTTPS or not"

Common Constants

View Source
const (
	TagHeader                  = "x-tag"
	URLHeader                  = "x-url"
	ApplicationJSONContentType = "application/json"
	TextStringContentType      = "text/string"

Response constants

View Source
const (
	MockEntityName = "mock"

MockEntityName is the mock entity name


View Source
var (
	BasePath           = "/"
	MockEndpointPath   = fmt.Sprintf("%smock", MoxyPrefix)
	UnMockEndpointPath = fmt.Sprintf("%sunMock", MoxyPrefix)

Endpoint Paths


func DecodeJSON

func DecodeJSON(b []byte, v interface{}) error

DecodeJSON is used to decode any type of data from byte array

func EncodeJSON

func EncodeJSON(v interface{}) ([]byte, error)

EncodeJSON is used to encode any type of data to byte array


This section is empty.

Jump to

Keyboard shortcuts

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