Created
December 10, 2012 02:12
-
-
Save mbeale/4247991 to your computer and use it in GitHub Desktop.
Dynamic JSON sample golang #5
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
func main(){ | |
dyn, err := MakeJSONContainer(rawData) | |
if err != nil { | |
fmt.Println("error:", err) | |
} else { | |
for _, v := range dyn.All() { | |
if val ,err := v.Get("payload.deeper_nesting.return_value");err == nil { | |
println(val) | |
} else { | |
fmt.Println("error:", err) | |
} | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment