Project

Profile

Help

Feature #4952

closed

Add support for a JSON Source

Added by Norm Tovey-Walsh almost 3 years ago. Updated about 2 years ago.

Status:
Closed
Priority:
Low
Assignee:
-
Category:
-
Sprint/Milestone:
-
Start date:
2021-03-30
Due date:
% Done:

0%

Estimated time:
Legacy ID:
Applies to branch:
Fix Committed on Branch:
Fixed in Maintenance Release:
Platforms:

Description

From a discussion on the xml.com Slack, it looks like there would be value in providing some mechanism for loading JSON documents as a transformation source at the API level.

https://xmlcom.slack.com/archives/C011NLXE4DU/p1617028570195500

Actions #1

Updated by Michael Kay almost 3 years ago

Saxon 11 adds

XdmValue json = Processor.newJsonBuilder().parseJson(Reader|String);
Xslt30Transformer.setContextItem((XdmItem)json);

It's an XdmValue rather than an XdmItem because the Json input "null" delivers an Xdm empty sequence, which is a bit unfortunate.

Actions #2

Updated by Michael Kay almost 3 years ago

  • Tracker changed from Bug to Feature
  • Status changed from New to Resolved
Actions #3

Updated by Norm Tovey-Walsh about 2 years ago

  • Status changed from Resolved to Closed

No action required then, I think.

Please register to edit this issue

Also available in: Atom PDF