aboutsummaryrefslogtreecommitdiffstats
path: root/src/com/itmill
diff options
context:
space:
mode:
authorJoonas Lehtinen <joonas.lehtinen@itmill.com>2007-01-23 12:27:26 +0000
committerJoonas Lehtinen <joonas.lehtinen@itmill.com>2007-01-23 12:27:26 +0000
commitc8ae00aed08faa535d13e5a4fe5b79c7f78e3354 (patch)
treee8afa115a4b590620ee3dde39f348b77b80898a7 /src/com/itmill
parentf6a1ec08ef633b17640b35cd75fb038d70cbdf27 (diff)
downloadvaadin-framework-c8ae00aed08faa535d13e5a4fe5b79c7f78e3354.tar.gz
vaadin-framework-c8ae00aed08faa535d13e5a4fe5b79c7f78e3354.zip
Supports both java:// and millstone:// prefixes for xsl java-calls
svn changeset:315/svn branch:toolkit
Diffstat (limited to 'src/com/itmill')
-rw-r--r--src/com/itmill/toolkit/terminal/web/XSLReader.java13
1 files changed, 7 insertions, 6 deletions
diff --git a/src/com/itmill/toolkit/terminal/web/XSLReader.java b/src/com/itmill/toolkit/terminal/web/XSLReader.java
index 60ba87b818..436886a095 100644
--- a/src/com/itmill/toolkit/terminal/web/XSLReader.java
+++ b/src/com/itmill/toolkit/terminal/web/XSLReader.java
@@ -101,7 +101,7 @@ public class XSLReader implements XMLReader, ContentHandler {
}
}
- private static final String JAVA_PREFIX = "java://";
+ private static final String[] JAVA_PREFIX = {"java://", "millstone://"};
private Collection streams;
private boolean startTagHandled = false;
private String xslNamespace = "";
@@ -421,29 +421,30 @@ public class XSLReader implements XMLReader, ContentHandler {
public String getURI(int index) {
String uri = original.getURI(index);
- if (uri != null && uri.startsWith(JAVA_PREFIX)) {
+ for (int i=0; i<JAVA_PREFIX.length; i++)
+ if (uri != null && uri.startsWith(JAVA_PREFIX[i])) {
System.out.print("DEBUG " + uri + " --> ");
switch (xsltProcessor) {
case XSLT_SAXON6 :
uri =
"saxon://"
- + uri.substring(JAVA_PREFIX.length());
+ + uri.substring(JAVA_PREFIX[i].length());
break;
case XSLT_SAXON7 :
uri =
"saxon://"
- + uri.substring(JAVA_PREFIX.length());
+ + uri.substring(JAVA_PREFIX[i].length());
break;
case XSLT_XALAN :
uri =
"xalan://"
- + uri.substring(JAVA_PREFIX.length());
+ + uri.substring(JAVA_PREFIX[i].length());
break;
default :
uri =
"xalan://"
- + uri.substring(JAVA_PREFIX.length());
+ + uri.substring(JAVA_PREFIX[i].length());
break;
}
System.out.println(uri);