Welcome!

Welcome to the Official BlackBerry Support Community Forums. This is your resource to discuss support topics with your peers, and learn from each other. New to the forum? Please visit the ‘Getting Started’ link below.
inside custom component

Native Development

Reply
Trusted Contributor
gdev001
Posts: 163
Registered: ‎01-30-2013

Automatically converting JSON response to C++ objects

[ Edited ]

Hi,

 

Imagine I have some JSON response. And I also have some custom classes MyCustomClass1 and MyCustomClass2.

I know we have a JSON parser on BB 10 SDK (JsonDataAccess). I am curious if BlackBerry 10 has a way (maybe a class? or a library?) that also allows to automatically convert this JSON response to objects of my custom classes? (e.g., MyCustomClass1 and MyCustomClass2).

 

I found some library which is supposed to do this: http://fossil.wanderinghorse.net/repos/nosjob/index.cgi/index

(it's description says: "Easy parsing of JSON string data (from arbitrary input iterators) into C++ objects.") -- but I was curious if there is a BlackBerry way to do this? Plus I am not sure yet if I can use this library on BB 10.

 

Thanks for your input.

Please use plain text.
New Contributor
adampigg
Posts: 6
Registered: ‎02-06-2013
My Carrier: Three UK

Re: Automatically converting JSON response to C++ objects

Have you considered using QJSon?
Please use plain text.
Trusted Contributor
gdev001
Posts: 163
Registered: ‎01-30-2013

Re: Automatically converting JSON response to C++ objects

Please use plain text.