rest

package
v1.23.0 Latest Latest
Warning

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

Go to latest
Published: Feb 13, 2018 License: BSD-3-Clause Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewRequest

func NewRequest() *rest.Request

Types

type EncodeJsonOutput

type EncodeJsonOutput struct {
	Bytes []byte
	Error error
}

type ResponseWriter

type ResponseWriter struct {
	*test.Mock
	HeaderImpl             http.Header
	WriteJsonInvocations   int
	WriteJsonInputs        []interface{}
	WriteJsonOutputs       []error
	EncodeJsonInvocations  int
	EncodeJsonInputs       []interface{}
	EncodeJsonOutputs      []EncodeJsonOutput
	WriteHeaderInvocations int
	WriteHeaderInputs      []int
}

func NewResponseWriter

func NewResponseWriter() *ResponseWriter

func (*ResponseWriter) EncodeJson

func (r *ResponseWriter) EncodeJson(object interface{}) ([]byte, error)

func (*ResponseWriter) Expectations

func (r *ResponseWriter) Expectations()

func (*ResponseWriter) Header

func (r *ResponseWriter) Header() http.Header

func (*ResponseWriter) WriteHeader

func (r *ResponseWriter) WriteHeader(code int)

func (*ResponseWriter) WriteJson

func (r *ResponseWriter) WriteJson(object interface{}) error

Jump to

Keyboard shortcuts

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