Project

Profile

Help

Feature #4736

Add syntax for an external JavaScript object type

Added by Debbie Lockett about 1 month ago. Updated about 1 month ago.

Status:
New
Priority:
Low
Assignee:
Category:
-
Sprint/Milestone:
-
Start date:
2020-09-14
Due date:
% Done:

0%

Estimated time:
Applies to JS Branch:
2.0
Fix Committed on JS Branch:
Fixed in JS Release:
SEF Generated with:
Company:
-
Contact person:
-
Additional contact persons:
-

Description

We should add a new XPath ItemType for external JavaScript objects, so that type information for variables, etc. can be more specific than just item(). e.g. for storing JavaScript objects returned from calling IXSL extension functions, and global JS functions. (And to avoid conversion to XDM types, where this would otherwise happen.)

History

#1 Updated by Debbie Lockett about 1 month ago

  • Description updated (diff)

#2 Updated by Debbie Lockett about 1 month ago

  • Assignee changed from Debbie Lockett to Michael Kay

#3 Updated by Michael Kay about 1 month ago

For Java, the type of an external object of class org.package.ClassName is

Q{http://saxon.sf.net/java-type}org.package.ClassName

(It can of course be written as a lexical QName with a prefix if preferred.)

For JavaScript, I think we should use a single QName for all external objects, and suggest the name

Q{http://saxon.sf.net/javascript-type}Object

The alphacode for an external Java object type is "X norg.package.ClassName". For JavaScript I think it can simply be "X".

Please register to edit this issue

Also available in: Atom PDF Tracking page