|
|
|
[
Permlink
| « Hide
]
Werner Guttmann - 06/May/07 09:40 AM
No, it shouldn't, as you are referring to Configuration.java. In LocalConfiguration.java, the code your are looking for is actually implemented. To me it looks like you are putting your custom castor.properties to the wrong location. Have you made sure that it is available on the CLASSPATH ?
castor.properties is on my root directory and other properties apply nicely, exept features like:
org.exolab.castor.sax.features=http://xml.org/sax/features/validation,http://apache.org/xml/features/validation/schema Following code: Unmarshaller unmarshaller = new Unmarshaller(GameData.class); Leads to Unmarshaller.java: 697: Actually, sorry, there's a problem with this code. I think I know what's going wrong.
castor.properties is on my root directory and other properties apply nicely, exept features like:
org.exolab.castor.sax.features=http://xml.org/sax/features/validation,http://apache.org/xml/features/validation/schema Following code: Unmarshaller unmarshaller = new Unmarshaller(GameData.class); Leads to Unmarshaller.java: 697: which lead to Configuration class: which deals with props from my castor.properties, but then it goes to which returns features as null I have added following hack to get it done in my project: Configuration.getDefault().setProperty(Property.ParserFeatures,"http://xml.org/sax/features/validation,http://apache.org/xml/features/validation/schema Hi Werner,
I see you fixed the bug for "features" (to enable) but you didn't for "featuresToDisable". Am I seeing right? In "patch.c1964.20070506.txt" i find that "features" is set with Of course, my need is for "featuresToDisable"... Please keep in mind that a lot of code in this area has changed over the past few days ... and as such, things might work out of the box. Are you in a position to check out SVN trunk and build a JAR yourself ? The current XML configuration lives in XMLConfiguration.java, and not in (Local)Configuration anymore.
Marking this as resolved as the complete code to handle property files has been rewritten.
|
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||