Hi Gayan,
You can use conversion syntax(<json>) to achieve this. Ex -
function main(string[] args) {
string ss = "{'ab':'ddd'}";
json jsonVal;
jsonVal, _ = <json> ss;
println(jsonVal);
}
Thanks,
On 30 October 2017 at 16:39, Gayan Chamara <[email protected]> wrote:
> Hi,
> Is there a way to convert JSON string into ballerina json type in
> ballerina 0.89? I couldn't find a suitable method in the docs.
>
> Thanks,
> Gayan.
>
> --
> Regards,
>
> *Gayan Chamara*
>
> *Software Engineering Intern*
> *WSO2 Inc.*
>
>
> *Email: [email protected] <[email protected]> *
> *Mobile : **+94 71 728 5827 <071%20728%205827>*
> <http://wso2.com/signature>
>
--
Rajith Vitharana
Senior Software Engineer,
WSO2 Inc. : wso2.com
Mobile : +94715883223
Blog : http://lankavitharana.blogspot.com/
<http://wso2.com/signature>
_______________________________________________
Dev mailing list
[email protected]
http://wso2.org/cgi-bin/mailman/listinfo/dev