MCPcopy Index your code
hub / github.com/ChimeraCoder/gojson / readFile

Function readFile

json-to-struct.go:191–198  ·  view source on GitHub ↗
(input io.Reader)

Source from the content-addressed store, hash-verified

189}
190
191func readFile(input io.Reader) ([]byte, error) {
192 buf := bytes.NewBuffer(nil)
193 _, err := io.Copy(buf, input)
194 if err != nil {
195 return []byte{}, nil
196 }
197 return buf.Bytes(), nil
198}
199
200// Generate a struct definition given a JSON string representation of an object and a name structName.
201func Generate(input io.Reader, parser Parser, structName, pkgName string, tags []string, subStruct bool, convertFloats bool) ([]byte, error) {

Callers 1

ParseYamlFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected