request

package
v1.0.0-rc.1 Latest Latest
Warning

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

Go to latest
Published: Jul 6, 2020 License: MIT Imports: 5 Imported by: 0

Documentation

Overview

Package request provides interface for handling REST API requests.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Response

type Response struct {
	//RefID       string      `json:"refID,omitempty"` // TODO: implement
	StatusCode    int         `json:"statusCode,omitempty"`
	StatusMessage string      `json:"statusMessage,omitempty"`
	Error         interface{} `json:"error,omitempty"`
	ErrorLog      error       `json:"-"`
	DebugLog      string      `json:"-"`
}

Response represents an HTTP response instance.

func (*Response) Reply

func (resp *Response) Reply(c *gin.Context, by interface{})

Reply replies an HTTP request by using the response instance.

Jump to

Keyboard shortcuts

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