[squeak-dev] Json simple example?
Lawson English
lenglish5 at cox.net
Thu Jul 21 19:16:11 UTC 2011
How can I use the Json class?
I've tried various permutations and combinations of:
r := (WebClient httpGet: 'http://localhost' )content.
r := MultiByteBinaryOrTextStream on: r encoding: nil.
Json readFrom: r.
where localhost/index.html is:
{ "glossary": { "title": "example glossary", "GlossDiv": { "title": "S",
"GlossList": { "GlossEntry": { "ID": "SGML", "SortAs": "SGML",
"GlossTerm": "Standard Generalized Markup Language", "Acronym": "SGML",
"Abbrev": "ISO 8879:1986", "GlossDef": { "para": "A meta-markup
language, used to create markup languages such as DocBook.",
"GlossSeeAlso": ["GML", "XML"] }, "GlossSee": "markup" } } } } }
taken from http://json.org/example.html
I get MNU: undefonedObject>>isSeparator.
Help?
Thanks.
Lawson
More information about the Squeak-dev
mailing list
|