Documentation ¶
Index ¶
- func Logger() gin.HandlerFunc
- func ShowAsciiJSON() error
- func ShowBindDataRequestWithCustomStruct() error
- func ShowBindHtmlCheckBoxes() error
- func ShowBindQueryStringOrPostData() error
- func ShowBindUri() error
- func ShowBuildSingleBinaryWithAssertTemplate() error
- func ShowControlLogOutputColor() error
- func ShowCustomHttpConfiguration() error
- func ShowCustomLogFile() error
- func ShowCustomMiddleware() error
- func ShowCustomValidators() error
- func ShowDefineRoutesLogFormat() error
- func ShowGoroutinesInsideAMiddleware() error
- func ShowGracefulRestartOrStop() error
- func ShowGroupingRoutes() error
- func ShowHowToWriteLogFile() error
- func ShowHtmlRendering() error
- func ShowJsonPadding() error
- func ShowMapAsQueryStringOrPostFormParams() error
- func ShowServingStaticFiles() error
- func ShowUploadFile() error
- type Booking
- type MyForm
- type Person
- type PersonUri
- type StructA
- type StructB
- type StructC
- type StructD
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Logger ¶
func Logger() gin.HandlerFunc
func ShowAsciiJSON ¶
func ShowAsciiJSON() error
func ShowBindDataRequestWithCustomStruct ¶
func ShowBindDataRequestWithCustomStruct() error
func ShowBindHtmlCheckBoxes ¶
func ShowBindHtmlCheckBoxes() error
func ShowBindQueryStringOrPostData ¶
func ShowBindQueryStringOrPostData() error
func ShowBindUri ¶
func ShowBindUri() error
func ShowBuildSingleBinaryWithAssertTemplate ¶
func ShowBuildSingleBinaryWithAssertTemplate() error
func ShowControlLogOutputColor ¶
func ShowControlLogOutputColor() error
ShowControlLogOutputColor By default, logs output on console should be colorized depending on the detected TTY.
func ShowCustomHttpConfiguration ¶
func ShowCustomHttpConfiguration() error
ShowCustomHttpConfiguration Use http.ListenAndServe() directly.
func ShowCustomLogFile ¶
func ShowCustomLogFile() error
func ShowCustomMiddleware ¶
func ShowCustomMiddleware() error
func ShowCustomValidators ¶
func ShowCustomValidators() error
func ShowDefineRoutesLogFormat ¶
func ShowDefineRoutesLogFormat() error
ShowDefineRoutesLogFormat
The default log of routes is: [GIN-debug] POST /foo --> main.main.func1 (3 handlers)
Use gin.DebugPrintRouteFunc to custom this information in given format.
func ShowGoroutinesInsideAMiddleware ¶
func ShowGoroutinesInsideAMiddleware() error
func ShowGracefulRestartOrStop ¶
func ShowGracefulRestartOrStop() error
func ShowGroupingRoutes ¶
func ShowGroupingRoutes() error
func ShowHowToWriteLogFile ¶
func ShowHowToWriteLogFile() error
func ShowHtmlRendering ¶
func ShowHtmlRendering() error
func ShowJsonPadding ¶
func ShowJsonPadding() error
ShowJsonPadding Solve Ajax not allowed to fetch cross-domain data issue.
func ShowMapAsQueryStringOrPostFormParams ¶
func ShowMapAsQueryStringOrPostFormParams() error
func ShowServingStaticFiles ¶
func ShowServingStaticFiles() error
go run . --static_dir=/Users/litong.deng/Downloads
func ShowUploadFile ¶
func ShowUploadFile() error
go run . --upload_dir=/Users/litong.deng/Downloads
Types ¶
type Booking ¶
type Booking struct { // validation: today < checkIn < CheckOut CheckIn time.Time `form:"check_in" binding:"required,bookabledate" time_format:"2006-01-02"` CheckOut time.Time `form:"check_out" binding:"required,gtfield=CheckIn,bookabledate" time_format:"2006-01-02"` Cost float64 `form:"cost" binding:"required,costable"` }
Source Files ¶
- asciijson.go
- bind_data_request_with_struct.go
- bind_html_checkboxes.go
- bind_query_string_or_post_data.go
- bind_uri.go
- build_single_binary_with_templates.go
- control_log_output_color.go
- custom_http_configuration.go
- custom_log_file.go
- custom_validators.go
- custome_middleware.go
- define_format_for_routes_log.go
- goroutines-inside-a-middleware.go
- graceful-restart-or-stop.go
- grouping-routes.go
- how_to_write_log_file.go
- html_rendering.go
- jsonp.go
- map_as_querystring_or_postform_params.go
- serving_static_files.go
- upload_file.go
Click to show internal directories.
Click to hide internal directories.