XML Editor
Sign up for a WebBoard account Sign Up Keyword Search Search More Options... Options
Chat Rooms Chat Help Help News News Log in to WebBoard Log in Not Logged in
Conferences Close Tree View
+ Stylus Studio Feature Requests (1192)
- Stylus Studio Technical Forum (14621)
-> - Stylus Studio - Registrar en o... (1)
-> + Stylus Studio - Registrar en o... (2)
-> + Can a pipeline send a file by ... (2)
-> + After Updateing WIN10 to WIN11... (12)
-> + Where do I add the custom java... (3)
-> + Where is the Diagram tab? (5)
-> + Applying XSLT to Word DOCX/XML (2)
-> - CSV conversion via ConvertToXM... (1)
-> + Text symbols in SS not same as... (4)
-> + Exposing xquery as webservice ... (6)
-> + Syntax Identifier (2)
-> + Saving a Converted XML as an X... (5)
-> + Output document cannot be pars... (4)
-> - Archiving output from conversi... (1)
-> + EDIFACT guideline from Stylus ... (3)
-> + CSV file putting all the data ... (5)
-> + Can't install Home version 64b... (5)
-> + presale - Can I covers this sc... (5)
-> + Problem with UNB (5)
-> + Splitting EDIFACT files pipeli... (4)
-- [1-20] [21-40] [41-60] Next
+ Website Feedback (249)
+ XSLT Help and Discussion (7625)
+ XQuery Help and Discussion (2016)
+ Stylus Studio FAQs (159)
+ Stylus Studio Code Samples & Utilities (364)
+ Stylus Studio Announcements (113)
Topic  
Postnext
mark russoSubject: Java Execution
Author: mark russo
Date: 25 Oct 2005 12:13 PM
I am using the Stylus Pro 6 enterprise edition and j2e 1.4x. When I generate java code within stylus and compile/run it, it works fine within stylus. When I go to run the code from the command line, however, it gives me numerous errors (36). Do I need to put the saxon information in the classpath with the java information or how do I make the java code work outside of stylus (as a stand alone application)? Any help would be helpful.

thanks.
mark

Postnext
Ivan PedruzziSubject: Java Execution
Author: Ivan Pedruzzi
Date: 25 Oct 2005 12:42 PM
Hi Mark,

Could you post the errors you are getting?

To verify which jars you need in the Classpath click Project -> Set Classpath...

Hope this helps
Ivan Pedruzzi
Stylus Studio Team

Postnext
mark russoSubject: Java Execution
Author: mark russo
Date: 25 Oct 2005 02:12 PM
I will post the error messages when I return home this evening. However, I guess the question I still have is do I have to put the stylus classpath (for saxon) into my environmental variable classpath for it to work outside of stylus? Thanks and will post when I return home.

Postnext
Ivan PedruzziSubject: Java Execution
Author: Ivan Pedruzzi
Date: 25 Oct 2005 03:46 PM


Only if you you are using the Stylus Studio URI resolver.


Ivan

Postnext
mark russoSubject: Java Execution
Author: mark russo
Date: 28 Oct 2005 02:10 PM
HERE IS THE ERROR STRING WHEN I RUN THE CODE OUTSIDE OF STYLUS.
any help would be greatly appreciated. thanks again.

mark

C:\Program Files\Stylus Studio 6 XML Enterprise Edition\sources>javac test.java
test.java:24: package com.exln.stylus.io does not exist
import com.exln.stylus.io.StylusFileFactory;
^
test.java:26: package net.sf.saxon does not exist
import net.sf.saxon.Configuration;
^
test.java:27: package net.sf.saxon.om does not exist
import net.sf.saxon.om.Item;
^
test.java:28: package net.sf.saxon.om does not exist
import net.sf.saxon.om.SequenceIterator;
^
test.java:29: package net.sf.saxon.query does not exist
import net.sf.saxon.query.DynamicQueryContext;
^
test.java:30: package net.sf.saxon.query does not exist
import net.sf.saxon.query.StaticQueryContext;
^
test.java:31: package net.sf.saxon.query does not exist
import net.sf.saxon.query.XQueryExpression;
^
test.java:32: package net.sf.saxon.value does not exist
import net.sf.saxon.value.AtomicValue;
^
test.java:33: package net.sf.saxon.value does not exist
import net.sf.saxon.value.SequenceExtent;
^
test.java:34: package net.sf.saxon.value does not exist
import net.sf.saxon.value.UntypedAtomicValue;
^
test.java:35: package net.sf.saxon.value does not exist
import net.sf.saxon.value.Value;
^
test.java:62: cannot resolve symbol
symbol : class Configuration
location: class test
Configuration m_cfg = null;
^
test.java:63: cannot resolve symbol
symbol : class StaticQueryContext
location: class test
StaticQueryContext m_sqc = null;
^
test.java:64: cannot resolve symbol
symbol : class DynamicQueryContext
location: class test
DynamicQueryContext m_dqc = null;
^
test.java:190: cannot resolve symbol
symbol : class Configuration
location: class test
public void parseParametersSaxon(Configuration cfg, String[] paramNames,
String[] paramValues, String uri, DynamicQueryContext globalDQC)
^
test.java:190: cannot resolve symbol
symbol : class DynamicQueryContext
location: class test
public void parseParametersSaxon(Configuration cfg, String[] paramNames,
String[] paramValues, String uri, DynamicQueryContext globalDQC)

^
test.java:104: cannot resolve symbol
symbol : variable StylusFileFactory
location: class test
StylusFileFactory.unlockAPI("315146-185340461");
^
test.java:166: cannot resolve symbol
symbol : class Configuration
location: class test
m_cfg = new Configuration();
^
test.java:168: cannot resolve symbol
symbol : variable StylusFileFactory
location: class test
if (m_useResolver) m_cfg.setURIResolver(StylusFileFactory.getFac
tory());
^
test.java:170: cannot resolve symbol
symbol : class StaticQueryContext
location: class test
m_sqc = new StaticQueryContext(m_cfg);
^
test.java:173: cannot resolve symbol
symbol : class DynamicQueryContext
location: class test
m_dqc = new DynamicQueryContext(m_cfg);
^
test.java:186: cannot resolve symbol
symbol : class XQueryExpression
location: class test
XQueryExpression exp = m_sqc.compileQuery(m_queryReader);
^
test.java:199: cannot resolve symbol
symbol : class Value
location: class test
Value xvalue=null;
^
test.java:201: cannot resolve symbol
symbol : class StaticQueryContext
location: class test
StaticQueryContext sqc = new StaticQueryContext(
cfg);
^
test.java:201: cannot resolve symbol
symbol : class StaticQueryContext
location: class test
StaticQueryContext sqc = new StaticQueryContext(
cfg);
^
test.java:203: cannot resolve symbol
symbol : class DynamicQueryContext
location: class test
DynamicQueryContext localDQC = new DynamicQueryC
ontext(cfg);
^
test.java:203: cannot resolve symbol
symbol : class DynamicQueryContext
location: class test
DynamicQueryContext localDQC = new DynamicQueryC
ontext(cfg);
^
test.java:206: cannot resolve symbol
symbol : class XQueryExpression
location: class test
XQueryExpression xqe = sqc.compileQuery(sr);
^
test.java:207: cannot resolve symbol
symbol : class SequenceIterator
location: class test
SequenceIterator si = xqe.iterator(localDQC).get
Another();
^
test.java:208: cannot resolve symbol
symbol : class Item
location: class test
Item item = si.next();
^
test.java:209: cannot resolve symbol
symbol : class AtomicValue
location: class test
if (item != null && si.next() == null && item in
stanceof AtomicValue) {

^
test.java:210: cannot resolve symbol
symbol : class AtomicValue
location: class test
xvalue = (AtomicValue)item;
^
test.java:212: cannot resolve symbol
symbol : class SequenceExtent
location: class test
xvalue = new SequenceExtent(xqe.iterator
(localDQC));
^
test.java:215: cannot resolve symbol
symbol : class UntypedAtomicValue
location: class test
xvalue = new UntypedAtomicValue(svalue);
^
test.java:337: cannot resolve symbol
symbol : variable StylusFileFactory
location: class test.ResolverSource
setInputStream(StylusFileFactory.createInputStream(urlSt
ring, null));
^
test.java:346: cannot resolve symbol
symbol : variable StylusFileFactory
location: class test.ResolverResult
setOutputStream(StylusFileFactory.createOutputStream(url
String, null));

Postnext
Ivan PedruzziSubject: Java Execution
Author: Ivan Pedruzzi
Date: 28 Oct 2005 03:05 PM
Mark,

From the errors it seems like you didn't configure the classpath correctly


Ivan Pedruzzi
Stylus Studio Team

Postnext
mark russoSubject: Java Execution
Author: mark russo
Date: 28 Oct 2005 03:43 PM
thanks - I figured it was something like that - however, I am unsure how to fix it.

In my stylus classpath - it looks like this -
$(classpath),C:\Program Files\Stylus Studio 6 XML Enterprise Edition\bin\CustomFileSystem.jar;C:\Program Files\Stylus Studio 6 XML Enterprise Edition\bin\saxon8.jar

is that what it is supposed to say?

secondly, should I add this to my windows classpath as well (I know you said no, earlier...).

thanks again.

mark

Postnext
Ivan PedruzziSubject: Java Execution
Author: Ivan Pedruzzi
Date: 28 Oct 2005 04:42 PM
What you are trying to do requires a minimal understanding of Java programming.

Set the CLASSPATH in the DOS console using the following command

SET CLASSPATH=C:\progra~1\stylus~1\bin\CustomFileSystem.jar;C:\Program Files\stylus~1\bin\saxon8.jar;.


Notice the short path notation to make javac happy.
You can get short notation using the following command

C:\Program Files>dir stylus* /X
Volume in drive C has no label.
Volume Serial Number is 6CA5-7DB2

Directory of C:\Program Files

09/01/2005 01:35 AM <DIR> STYLUS~1 Stylus Studio 6 XML Enterprise Edition
0 File(s) 0 bytes
9 Dir(s) 9,533,489,152 bytes free


Hope this helps
Ivan Pedruzzi
Stylus Studio Team

Postnext
mark russoSubject: Java Execution
Author: mark russo
Date: 17 Nov 2005 11:40 AM
Okay, I have entered this classpath in the c:\ window.
C:\>SET CLASSPATH=C:\progra~1\stylus~1\bin\CustomFileSystem.jar; c:\Program Files\stylus~1\bin\saxon8.jar

When I javac the java code created by stylus, I still get the 36 errors that I sent earlier. It works fine from inside stylus but not on the outside. Any help (again) would be appreciated.

thanks in advance.

mark

Posttop
Ivan PedruzziSubject: Java Execution
Author: Ivan Pedruzzi
Date: 17 Nov 2005 12:15 PM

C:\>SET CLASSPATH=C:\progra~1\stylus~1\bin\CustomFileSystem.jar; c:\Program Files\stylus~1\bin\saxon8.jar

It seems there is space after CustomFileSystem.jar; and the last path should be C:\progra~1\stylus~1\bin\saxon8.jar


Hope this helps
Ivan Pedruzzi
Stylus Studio Team

   
Download A Free Trial of Stylus Studio 6 XML Professional Edition Today! Powered by Stylus Studio, the world's leading XML IDE for XML, XSLT, XQuery, XML Schema, DTD, XPath, WSDL, XHTML, SQL/XML, and XML Mapping!  
go

Log In Options

Site Map | Privacy Policy | Terms of Use | Trademarks
Stylus Scoop XML Newsletter:
W3C Member
Stylus Studio® and DataDirect XQuery ™are from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2016 All Rights Reserved.