jsonProvider been deprecated
As it says in documentation %ZEN.Auxiliary.jsonProvider been deprecated. We been using it's functions like %ConvertJSONToObject, WriteJSONFromObject etc. Is there any replacement?
Product version: IRIS 2021.1
As it says in documentation %ZEN.Auxiliary.jsonProvider been deprecated. We been using it's functions like %ConvertJSONToObject, WriteJSONFromObject etc. Is there any replacement?
Do the methods in %JSON.Adaptor meet your needs?
Roman,
You can look at the %JSON.Adaptor class which provides this functionality for a particular class. Here is the class reference and relevant documentation.
%JSON.Adaptor Class Reference
%JSON.Adaptor documentation
What do you do if your API calls a SOAP Internal and you get back a response SOAP Client Classes generated from WSDL .
You have to change those classes to extend %JSON.Adaptor, Would have been nice not to change generated classes.
For this reason it would be nice to be able to use %ZEN.Auxiliary.jsonProvider or then a replacement .
Or is there any other way of handling this?
Thomas,
That does present a problem. At this time I don't believe we have a function for function replacement for that %ZEN.Auxilliary class. There are issues with how that object to JSON mapping was done that could result in exceedingly large blocks of JSON. I would encourage you to raise this issue with your Sales Engineer who would be in a good position to present a feature request in the proper context to Product Development.
In the meantime, I can suggest a couple of ways to deal with this.
To use Python Libraries in ObjectScript you import the Python libraries and then just call the methods. Here is a small example of using the Python standard 'os' library.
If you wish to try option 2 here is a documentation link to help you get started.
Introduction to Embedded Python