Description
The following Code (see attached proxy-red.zip)
ProxyFactory f = new ProxyFactory(); f.setTargetClass(JCas.class); f.getProxy(); JCas jCas1 = JCasFactory.createJCas(new String[] {}); jCas1.setDocumentText("test text"); // ==> ArrayIndexOutOfBoundsException
is throwing the following exception (see attached exception.txt)
java.lang.ArrayIndexOutOfBoundsException: -1
at ....FeatureStructureImplC._setIntValueCommon(FeatureStructureImplC.java:1636)
WORKAROUND (see attached proxy-green.zip)
Creating a regular JCas before fix the problem (without using the created JCas)
JCasFactory.createJCas(new String[] {}); ProxyFactory f = new ProxyFactory(); f.setTargetClass(JCas.class); f.getProxy(); JCas jCas1 = JCasFactory.createJCas(new String[] {}); jCas1.setDocumentText("test text"); // ==> No exception
EASYMOCK
The same problem occurs with EasyMock (see attached easymock.-red.zip and easymock-green.zip)
Attachments
Attachments
Issue Links
- links to