Documentation
¶
Index ¶
- func MustIndent(src []byte, prefix, indent string) []byte
- func MustIndentDefault(src []byte) []byte
- func MustIndentDefaultString(src []byte) string
- func MustIndentString(src []byte, prefix, indent string) string
- func MustMarshal(v interface{}) []byte
- func MustMarshalIndent(v interface{}, prefix, indent string) []byte
- func MustMarshalIndentDefault(v interface{}) []byte
- func MustMarshalIndentDefaultString(v interface{}) string
- func MustMarshalIndentString(v interface{}, prefix, indent string) string
- func MustMarshalString(v interface{}) string
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func MustIndent ¶ added in v1.1.0
MustIndent is like json.Indent but panics on error.
func MustIndentDefault ¶ added in v1.4.0
MustIndentDefault is like MustIndent with prefix = "" and indent = " ".
func MustIndentDefaultString ¶ added in v1.4.0
MustIndentDefaultString is like MustIndentString with prefix = "" and indent = " ".
func MustIndentString ¶ added in v1.4.0
MustIndentString is like MustIndent but returns a string.
func MustMarshal ¶
func MustMarshal(v interface{}) []byte
MustMarshal is like json.Marshal but panics on error.
func MustMarshalIndent ¶
MustMarshalIndent is like json.MarshalIndent but panics on error.
func MustMarshalIndentDefault ¶ added in v1.4.0
func MustMarshalIndentDefault(v interface{}) []byte
MustMarshalIndentDefault is like MustMarshalIndent with prefix = "" and indent = " ".
func MustMarshalIndentDefaultString ¶ added in v1.4.0
func MustMarshalIndentDefaultString(v interface{}) string
MustMarshalIndentDefaultString is like MustMarshalIndentDefault with prefix = "" and indent = " ".
func MustMarshalIndentString ¶ added in v1.4.0
MustMarshalIndentString is like MustMarshalIndent but returns a string.
func MustMarshalString ¶ added in v1.4.0
func MustMarshalString(v interface{}) string
MustMarshalString is like MustMarshal but returns a string.
Types ¶
This section is empty.