Using Xalan-Java and XSLT, I am trying to convert date from an input xml that has it expressed as a single number (in milliseconds) e.g. the input xml has 1088499889000 that corresponds to the date 2004-06-29 09:04:49.000GMT.

To try and do this within XSLT, I looked up extensions like XSLT-SL and EXSLT - but they do not seem to have functions for this. Are there any extensions available that I could use for this conversion?

Since doing this conversion using java api is simpleand since Xalan-J allows calls to java functions from XSL, so an alternative option is to convert the numeric date by calls to Java api from within xsl. But restrictions on numeric parameter-types in such calls prevent me from making all java calls from xsl - instead I need to write my own java method for those calls and then call that function from xsl. Since I am using Xalan-J, I am hoping that the performance impact of making Java calls from XSL should not be too bad.

Is there any other/better/easier way to do this?


- Vishwajit.


Reply via email to