Documentation ¶ Index ¶ func CORSMiddleware() gin.HandlerFunc func Logger() gin.HandlerFunc func Recovery(ctx *gin.Context) type Log func NewLog() *Log func (l *Log) Err(e error) *Log func (l *Log) ErrCode(code int) *Log func (l *Log) Logging(ctx *gin.Context) func (l *Log) Rsp(r []byte) *Log Constants ¶ This section is empty. Variables ¶ This section is empty. Functions ¶ func CORSMiddleware ¶ func CORSMiddleware() gin.HandlerFunc CORSMiddleware は、CORSの設定を行う func Logger ¶ func Logger() gin.HandlerFunc Logger は、ロギング処理 func Recovery ¶ func Recovery(ctx *gin.Context) Recovery は、リクエストのパニックを回復する Types ¶ type Log ¶ type Log struct { // contains filtered or unexported fields } func NewLog ¶ func NewLog() *Log ログに保存する構造体の作成 最後に登録するにはLoggingを呼ぶ必要あり func (*Log) Err ¶ func (l *Log) Err(e error) *Log func (*Log) ErrCode ¶ func (l *Log) ErrCode(code int) *Log func (*Log) Logging ¶ func (l *Log) Logging(ctx *gin.Context) ログ情報を登録 func (*Log) Rsp ¶ func (l *Log) Rsp(r []byte) *Log Source Files ¶ View all Source files cors.go logger.go recovery.go Click to show internal directories. Click to hide internal directories.