gojson

package
v0.0.0-...-00a7b0a Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 28, 2024 License: Apache-2.0 Imports: 12 Imported by: 0

Documentation

Overview

Package gojson ...

Description : json_tool ...

Author : go_developer@163.com<张德满>

Date : 2022-01-09 10:48 PM

Index

Constants

This section is empty.

Variables

View Source
var ForceFloats bool

Functions

func FmtFieldName

func FmtFieldName(s string) string

FmtFieldName formats a string as a struct key

Example:

FmtFieldName("foo_id")

Output: FooID

func Generate

func Generate(input io.Reader, parser Parser, structName, pkgName string, tags []string, subStruct bool, convertFloats bool) ([]byte, error)

Generate a struct definition given a JSON string representation of an object and a name structName.

func ParseJson

func ParseJson(input io.Reader) (interface{}, error)

func ParseYaml

func ParseYaml(input io.Reader) (interface{}, error)

Types

type Parser

type Parser func(io.Reader) (interface{}, error)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL