Menu

#2 Jing fails for large .rng files

open
nobody
None
5
2003-05-14
2003-05-14
navya
No

When I use a .rng file with a choice option with more
than 6000 values as choices then jing.jar fails and
displays the following error recursively

Exception in thread "main" java.lang.StackOverflowError
at
com.thaiopensource.relaxng.impl.ValidatorPatternBuilder
.getPatternMemo(Unknown Source)
at
com.thaiopensource.relaxng.impl.EndAttributesFunction.
memoApply(Unknown Source)
at
com.thaiopensource.relaxng.impl.EndAttributesFunction.
caseChoice(Unknown source)
at
com.thaiopensource.relaxng.impl.ValidatorPatternBuilder
.getPatternMemo(Unknown Source)
at com.thaiopensource.relaxng.impl.ChoicePattern.apply
(Unknown Source)
at
com.thaiopensource.relaxng.impl.Pattern.applyForPatter
n(Unknown Source)
at
com.thaiopensource.relaxng.impl.PatternMemo.applyFor
PatternMemo(Unknown Source)
at
com.thaiopensource.relaxng.impl.PatternMemo.endAttrib
utes(Unknown Source)
at
com.thaiopensource.relaxng.impl.EndAttributesFunction.
apply(Unknown Source)
at
com.thaiopensource.relaxng.impl.EndAttributesFunction.
memoApply(Unknown Source)

These errors appear recusively.If I reduce the number of
value choices in the .rng file jing works fine.

I am sending you a sample of the .rng file that works fine
<?xml version="1.0" encoding="UTF-8"?>
<grammar xmlns="http://relaxng.org/ns/structure/1.0"
datatypeLibrary="http://www.w3.org/2001/XMLSchema-
datatypes">
<define name="xxx" combine="choice">
<element name="xxx">
<choice>
<value>a</value>
<value>b</value>
<value>c</value>
<value>d</value>
<value>e</value>
<value>f</value>
</choice>
</element>
</define>
</grammar>

If the same file has more than 6000 values as choice the
jing fails.

Discussion


Log in to post a comment.