Hi, wguttmn!
This error occurred at (JClassRegistry.java:467) when substring based on the logs below
Caused by: java.lang.StringIndexOutOfBoundsException: String index out of range: -1
at java.lang.String.substring(String.java:1911)
at org.exolab.castor.builder.JClassRegistry.ofTheSameType(JClassRegistry.java:467)
at org.exolab.castor.builder.JClassRegistry.printStatistics(JClassRegistry.java:424)
at org.exolab.castor.builder.SourceGenerator.generateSource(SourceGenerator.java:753)
at org.exolab.castor.builder.SourceGenerator.generateSource(SourceGenerator.java:690)
at org.exolab.castor.builder.SourceGenerator.generateSource(SourceGenerator.java:587)
at org.codehaus.mojo.castor.GenerateMojo.processFile(GenerateMojo.java:530)
I do not know much about the castor.But, the xPath`s value may have many diffrent types, such as
1.normal
a[bcdefg]h
2.only have [
a[bcdefgh
3.only have ]
abcde]fgh
4.none
abcdefgh
5.strange
ab]cde[fgh
From these types, type 1 and 4 offen appear in xPath.But the method ofTheSameType does not handle type 4.
Hi, wguttmn! This error occurred at (JClassRegistry.java:467) when substring based on the logs below
Here is the source code
I do not know much about the castor.But, the xPath`s value may have many diffrent types, such as 1.normal a[bcdefg]h 2.only have [ a[bcdefgh 3.only have ] abcde]fgh 4.none abcdefgh 5.strange ab]cde[fgh
From these types, type 1 and 4 offen appear in xPath.But the method ofTheSameType does not handle type 4.
The above is my analysis, please refer to.