Documentation ¶
Index ¶
- Constants
- func AddCommonResponseHeader(apiContext *types.APIContext) error
- type EncodingResponseWriter
- func (j *EncodingResponseWriter) Body(apiContext *types.APIContext, writer io.Writer, obj interface{}) error
- func (j *EncodingResponseWriter) VersionBody(apiContext *types.APIContext, version *types.APIVersion, writer io.Writer, ...) error
- func (j *EncodingResponseWriter) Write(apiContext *types.APIContext, code int, obj interface{})
- type HTMLResponseWriter
- type StringGetter
Constants ¶
View Source
const ( JSURL = "https://releases.rancher.com/api-ui/%API_UI_VERSION%/ui.min.js" CSSURL = "https://releases.rancher.com/api-ui/%API_UI_VERSION%/ui.min.css" DefaultVersion = "1.1.6" )
Variables ¶
This section is empty.
Functions ¶
func AddCommonResponseHeader ¶
func AddCommonResponseHeader(apiContext *types.APIContext) error
Types ¶
type EncodingResponseWriter ¶
type EncodingResponseWriter struct { ContentType string Encoder func(io.Writer, interface{}) error }
func (*EncodingResponseWriter) Body ¶
func (j *EncodingResponseWriter) Body(apiContext *types.APIContext, writer io.Writer, obj interface{}) error
func (*EncodingResponseWriter) VersionBody ¶
func (j *EncodingResponseWriter) VersionBody(apiContext *types.APIContext, version *types.APIVersion, writer io.Writer, obj interface{}) error
func (*EncodingResponseWriter) Write ¶
func (j *EncodingResponseWriter) Write(apiContext *types.APIContext, code int, obj interface{})
type HTMLResponseWriter ¶
type HTMLResponseWriter struct { EncodingResponseWriter CSSURL StringGetter JSURL StringGetter APIUIVersion StringGetter }
func (*HTMLResponseWriter) Write ¶
func (h *HTMLResponseWriter) Write(apiContext *types.APIContext, code int, obj interface{})
type StringGetter ¶
type StringGetter func() string
Click to show internal directories.
Click to hide internal directories.