JSON parsing..

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

JSON parsing..

sergio_101-2
i am struggling with using the JSON parser at squeaksource,

here's what i have done..

pulled in my data... saved it to a string..

then did:

json stream: jData.

where json is a Json object..

when i do:

json readAny

i always get:

MessageNotUnderstood: ByteString>>peek

where peek looks like:

peek
       ^ self stream peek

any ideas?

thanks!


--

----
peace,
sergio
photographer, journalist, visionary

http://www.coffee-black.com
http://www.painlessfrugality.com
http://www.twitter.com/sergio_101
http://www.facebook.com/sergio101
_______________________________________________
Beginners mailing list
[hidden email]
http://lists.squeakfoundation.org/mailman/listinfo/beginners
Reply | Threaded
Open this post in threaded view
|

Re: JSON parsing..

Randal L. Schwartz
>>>>> "sergio" == sergio 101 <[hidden email]> writes:

sergio> pulled in my data... saved it to a string..

sergio> then did:

sergio> json stream: jData.

I think you want a Stream there, not a String.

easy enough:

json stream: jData readStream.

--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
<[hidden email]> <URL:http://www.stonehenge.com/merlyn/>
Smalltalk/Perl/Unix consulting, Technical writing, Comedy, etc. etc.
See http://methodsandmessages.vox.com/ for Smalltalk and Seaside discussion
_______________________________________________
Beginners mailing list
[hidden email]
http://lists.squeakfoundation.org/mailman/listinfo/beginners