go-json/internal/encoder/option.go

36 lines
642 B
Go
Raw Normal View History

2021-05-31 16:25:33 +03:00
package encoder
type Option struct {
HTMLEscape bool
Indent bool
UnorderedMap bool
Debug bool
2021-05-31 18:46:42 +03:00
Colorize bool
ColorScheme *ColorScheme
2021-05-31 16:25:33 +03:00
}
2021-05-31 18:46:42 +03:00
type EncodeFormat struct {
Header string
Footer string
}
type EncodeFormatScheme struct {
Int EncodeFormat
Uint EncodeFormat
Float EncodeFormat
Bool EncodeFormat
String EncodeFormat
Binary EncodeFormat
ObjectStart EncodeFormat
ObjectEnd EncodeFormat
ArrayStart EncodeFormat
ArrayEnd EncodeFormat
Colon EncodeFormat
Comma EncodeFormat
}
type (
ColorScheme = EncodeFormatScheme
ColorFormat = EncodeFormat
)