Ok, that solved both problems. Thank you very much!
Wing Yew Poon escribió:
Diego,
1.
If you do
scomp -src <srcdir> -srconly -d <bindir> <schema>
then the java files are generated in the srcdir you specify and the
binary files,
including the TypeSystemHolder.class, are generated in the bindir you
specify.
When you compile and use the java files, make sure you include the files
in the
bindir in your classpath.
2.
The xsdconfig works for me (except I had a different namespace for xb).
You can also use
<xb:config xmlns:xb="http://www.bea.com/2004/02/xbean/config">
<xb:namespace>
<xb:package>es.tid.websemantica.buscador.querySchema</xb:package>
</xb:namespace>
</xb:config>
Are you doing
scomp <xsdfile> <xsdconfigfile>
?
Or are you using ant? if you're using ant, a common problem is not
having the
config file included with the fileset(s) of the *.xsd files.
- Wing Yew
-----Original Message-----
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
Sent: Thursday, March 29, 2007 8:39 AM
To: [email protected]
Subject: Two newbie questions
Hi, I'm new to XMLbeans and I've got some questions about it:
* Is there a way to use scomp for obtaining .java source files which I
could use in my application?. I mean, not obtaining a .jar, but only the
source files. I know there's a -srconly option, but I can't use those
source files in my application because I get a
java.lang.RuntimeException: "Cannot load SchemaTypeSystem. Unable to
load class with name
schemaorg_apache_xmlbeans.system.s43B4BB6513DB8C25ACC914901C0C8C83.TypeS
ystemHolder.
Make sure the generated binary files are on the classpath", so I suppose
the .java files are not enough.
* I've got an XSD with no namespaceTarget:
<?xml version="1.0" encoding="UTF-8"?>
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema">
...
and I want to compile it and obtain a package different from the
default "noNamespace" one. I've tried using this .xsdconfig file, but it
doesn't work:
<xb:config xmlns:xb="http://www.bea.com/2002/09/xbean/config">
<xb:namespace uri="##any">
<xb:package>es.tid.websemantica.buscador.querySchema</xb:package>
</xb:namespace>
</xb:config>
What's wrong with it?
Thank you very much.
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
Notice: This email message, together with any attachments, may contain
information of BEA Systems, Inc., its subsidiaries and affiliated
entities, that may be confidential, proprietary, copyrighted and/or legally
privileged, and is intended solely for the use of the individual or entity
named in this message. If you are not the intended recipient, and have received
this message in error, please immediately return this by email and then delete
it.
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]