Skip to content

mattn/go-scan

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

64 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

go-scan

Build Status Coverage Status

Easily way to get the elements via xpath like string

Usage

var js = strings.NewReader(`
{
	"foo": {
		"bar": [
			{
				"faz": true,
				"moo": ["goo", "mar"]
			},
			{
				"maz": true,
				"moo": ["foo", "bar"]
			}
		]
	}
}
`)
var s []string
scan.ScanJSON(js, "/foo/bar[1]/moo", &s) // s should be ["foo", "bar"]

Install

go get github.com/mattn/go-scan

License

MIT: http://mattn.mit-license.org/2013

Author

Yasuhiro Matsumoto (mattn.jp@gmail.com)

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Sponsor this project

 

Packages

No packages published

Languages