[kepler-users] XSLT Actor xml input

Christopher Brooks cxh at eecs.berkeley.edu
Thu Apr 23 13:32:26 PDT 2009


Hi Chris,

I'm assuming that the XSLTActor to which you refer is 
kepler/util/src/org/sdm/spa/XSLTActor.java

Ptolemy has some XSLT actors, see
ptII/ptolemy/actor/lib/xslt/XSLTransformer.java
That directory also has XMLInclusion.java and some demos.

The Ptolemy II devel tree has ptolemy.actor.lib.convert.StringToXML

If you have an XMLToken input, then to convert it to a String, create an 
Expression actor with an input port and an expression:
   input.toString()

There could be a XMLToString actor, but the above should work.

The spa XSLTActor should probably be rewritten to use XMLToken.
For backward compatibility, we would probably need two versions,
one that used String and one that used XMLToken.

_Christopher

Chris Weed wrote:
> The XSLT Actor accepts XML on it's input port, but does not use a XMLToken.
> Several sample work-flows seem to pass it a StringToken,
> which does not seem intuitive when I connect my actor that outputs an
> XMLToken.
> 
> Additionally, I don't see an actor that would bridge this gap of turning
> a XMLToken into a StringToken for actors that accept XML, but as a
> StringToken.
> 
> Am I missing something? Is this a bug?
> 
> Chris
> _______________________________________________
> Kepler-users mailing list
> Kepler-users at kepler-project.org
> http://mercury.nceas.ucsb.edu/kepler/mailman/listinfo/kepler-users

-- 
Christopher Brooks (cxh at eecs berkeley edu) University of California
CHESS Executive Director                      US Mail: 337 Cory Hall
Programmer/Analyst CHESS/Ptolemy/Trust        Berkeley, CA 94720-1774
ph: 510.643.9841 fax:510.642.2718	      (Office: 545Q Cory)
home: (F-Tu) 707.665.0131 (W-F) 510.655.5480



More information about the Kepler-users mailing list