You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@uima.apache.org by sc...@apache.org on 2016/11/08 16:44:18 UTC
svn commit: r1768732 - in /uima/uimaj/branches/experiment-v3-jcas: ./
javascripts/ unused-saved/src/org/apache/uima/cas/impl/
unused-saved/src/org/apache/uima/fs_generation/impl/
unused-saved/src/org/apache/uima/jcas/cas/ unused-saved/src/org/apache/ui...
Author: schor
Date: Tue Nov 8 16:44:18 2016
New Revision: 1768732
URL: http://svn.apache.org/viewvc?rev=1768732&view=rev
Log:
[UIMA-5172] remove some unused support for javascripts in earlier v3 html doc. Update rat exclude for new uimaj-v3migration-jcas project. update saved code snippets not part of project
Added:
uima/uimaj/branches/experiment-v3-jcas/unused-saved/src/org/apache/uima/jcas/cas/
uima/uimaj/branches/experiment-v3-jcas/unused-saved/src/org/apache/uima/jcas/cas/JavaObjectArray.java
Removed:
uima/uimaj/branches/experiment-v3-jcas/javascripts/
Modified:
uima/uimaj/branches/experiment-v3-jcas/pom.xml
uima/uimaj/branches/experiment-v3-jcas/unused-saved/src/org/apache/uima/cas/impl/JCasCoverClassFactoryTest.java
uima/uimaj/branches/experiment-v3-jcas/unused-saved/src/org/apache/uima/cas/impl/XXXdont_use_JCasCoverClassFactory.java
uima/uimaj/branches/experiment-v3-jcas/unused-saved/src/org/apache/uima/fs_generation/impl/JCasCoverClassFactoryTest.java
uima/uimaj/branches/experiment-v3-jcas/unused-saved/src/org/apache/uima/jcas/impl/JCasCoverClassFactory.java
uima/uimaj/branches/experiment-v3-jcas/unused-saved/src/org/apache/uima/jcas/impl/JCasCoverClassFactoryTest.java
uima/uimaj/branches/experiment-v3-jcas/unused-saved/src/org/apache/uima/jcasgen/impl/JCasClassConversion.java
uima/uimaj/branches/experiment-v3-jcas/unused-saved/src/study/asm/decompiled/AnnotationDumpV3.java
Modified: uima/uimaj/branches/experiment-v3-jcas/pom.xml
URL: http://svn.apache.org/viewvc/uima/uimaj/branches/experiment-v3-jcas/pom.xml?rev=1768732&r1=1768731&r2=1768732&view=diff
==============================================================================
--- uima/uimaj/branches/experiment-v3-jcas/pom.xml (original)
+++ uima/uimaj/branches/experiment-v3-jcas/pom.xml Tue Nov 8 16:44:18 2016
@@ -268,7 +268,8 @@
<exclude>uimaj-bootstrap/**</exclude>
<exclude>uimaj-internal-tools/**</exclude>
<exclude>uimaj-json/**</exclude>
- <exclude>src/main/readme/NOTICE-without-jackson</exclude>
+ <exclude>uimaj-v3migration-jcas/**</exclude>
+ <exclude>src/main/bin_distr_license_notices/NOTICE-without-jackson</exclude>
</excludes>
</configuration>
</execution>
Modified: uima/uimaj/branches/experiment-v3-jcas/unused-saved/src/org/apache/uima/cas/impl/JCasCoverClassFactoryTest.java
URL: http://svn.apache.org/viewvc/uima/uimaj/branches/experiment-v3-jcas/unused-saved/src/org/apache/uima/cas/impl/JCasCoverClassFactoryTest.java?rev=1768732&r1=1768731&r2=1768732&view=diff
==============================================================================
--- uima/uimaj/branches/experiment-v3-jcas/unused-saved/src/org/apache/uima/cas/impl/JCasCoverClassFactoryTest.java (original)
+++ uima/uimaj/branches/experiment-v3-jcas/unused-saved/src/org/apache/uima/cas/impl/JCasCoverClassFactoryTest.java Tue Nov 8 16:44:18 2016
@@ -1,3 +1,21 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
package org.apache.uima.cas.impl;
import static org.junit.Assert.*;
Modified: uima/uimaj/branches/experiment-v3-jcas/unused-saved/src/org/apache/uima/cas/impl/XXXdont_use_JCasCoverClassFactory.java
URL: http://svn.apache.org/viewvc/uima/uimaj/branches/experiment-v3-jcas/unused-saved/src/org/apache/uima/cas/impl/XXXdont_use_JCasCoverClassFactory.java?rev=1768732&r1=1768731&r2=1768732&view=diff
==============================================================================
--- uima/uimaj/branches/experiment-v3-jcas/unused-saved/src/org/apache/uima/cas/impl/XXXdont_use_JCasCoverClassFactory.java (original)
+++ uima/uimaj/branches/experiment-v3-jcas/unused-saved/src/org/apache/uima/cas/impl/XXXdont_use_JCasCoverClassFactory.java Tue Nov 8 16:44:18 2016
@@ -1,3 +1,21 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
/** New Name: FeatureStructureClassGen */
Modified: uima/uimaj/branches/experiment-v3-jcas/unused-saved/src/org/apache/uima/fs_generation/impl/JCasCoverClassFactoryTest.java
URL: http://svn.apache.org/viewvc/uima/uimaj/branches/experiment-v3-jcas/unused-saved/src/org/apache/uima/fs_generation/impl/JCasCoverClassFactoryTest.java?rev=1768732&r1=1768731&r2=1768732&view=diff
==============================================================================
--- uima/uimaj/branches/experiment-v3-jcas/unused-saved/src/org/apache/uima/fs_generation/impl/JCasCoverClassFactoryTest.java (original)
+++ uima/uimaj/branches/experiment-v3-jcas/unused-saved/src/org/apache/uima/fs_generation/impl/JCasCoverClassFactoryTest.java Tue Nov 8 16:44:18 2016
@@ -1,3 +1,21 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
package org.apache.uima.fs_generation.impl;
import java.io.ByteArrayOutputStream;
Added: uima/uimaj/branches/experiment-v3-jcas/unused-saved/src/org/apache/uima/jcas/cas/JavaObjectArray.java
URL: http://svn.apache.org/viewvc/uima/uimaj/branches/experiment-v3-jcas/unused-saved/src/org/apache/uima/jcas/cas/JavaObjectArray.java?rev=1768732&view=auto
==============================================================================
--- uima/uimaj/branches/experiment-v3-jcas/unused-saved/src/org/apache/uima/jcas/cas/JavaObjectArray.java (added)
+++ uima/uimaj/branches/experiment-v3-jcas/unused-saved/src/org/apache/uima/jcas/cas/JavaObjectArray.java Tue Nov 8 16:44:18 2016
@@ -0,0 +1,193 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.uima.jcas.cas;
+
+import org.apache.uima.cas.FeatureStructure;
+import org.apache.uima.cas.impl.CASImpl;
+import org.apache.uima.cas.impl.FeatureStructureImplC;
+import org.apache.uima.cas.impl.TypeImpl;
+import org.apache.uima.jcas.JCas;
+import org.apache.uima.jcas.JCasRegistry;
+
+/** Java Class model for Cas FSArray type */
+public final class JavaObjectArray extends TOP implements CommonPrimitiveArray {
+
+ /**
+ * each cover class when loaded sets an index. used in the JCas typeArray to go from the cover
+ * class or class instance to the corresponding instance of the _Type class
+ */
+ public final static int typeIndexID = JCasRegistry.register(JavaObjectArray.class);
+
+ public final static int type = typeIndexID;
+
+ /**
+ * used to obtain reference to the _Type instance
+ *
+ * @return the type array index
+ */
+ // can't be factored - refs locally defined field
+ public int getTypeIndexID() {
+ return typeIndexID;
+ }
+
+ private final Object[] theArray;
+
+ // never called. Here to disable default constructor
+ @SuppressWarnings("unused")
+ private JavaObjectArray() {
+ theArray = null;
+ }
+
+ /**
+ * Make a new FSArray of given size
+ * @param jcas The JCas
+ * @param length The number of elements in the new array
+ */
+ public JavaObjectArray(JCas jcas, int length) {
+ super(jcas);
+ theArray = new Object[length];
+ if (CASImpl.traceFSs) { // tracing done after array setting, skipped in super class
+ _casView.traceFSCreate(this);
+ }
+ if (CASImpl.IS_USE_V2_IDS) {
+ _casView.adjustLastFsV2size(length);
+ }
+ }
+
+ /**
+ * used by generator
+ * Make a new FSArray of given size
+ * @param c -
+ * @param t -
+ * @param length the length of the array
+ */
+ public JavaObjectArray(TypeImpl t, CASImpl c, int length) {
+ super(t, c);
+ theArray = new Object[length];
+ if (CASImpl.traceFSs) { // tracing done after array setting, skipped in super class
+ _casView.traceFSCreate(this);
+ }
+ if (CASImpl.IS_USE_V2_IDS) {
+ _casView.adjustLastFsV2size(length);
+ }
+ }
+
+
+ /** return the indexed value from the corresponding Cas FSArray as a Java Model object. */
+ public Object get(int i) {
+ return theArray[i];
+ }
+
+ /** updates the Cas, setting the indexed value with the corresponding Cas FeatureStructure. */
+ public void set(int i, Object v) {
+ theArray[i] = v;
+ _casView.maybeLogArrayUpdate(this, null, i);
+ }
+
+ /** return the size of the array. */
+ public int size() {
+ return theArray.length;
+ }
+
+ /**
+ * @see org.apache.uima.cas.ArrayFS#copyFromArray(FeatureStructure[], int, int, int)
+ */
+ public void copyFromArray(FeatureStructure[] src, int srcPos, int destPos, int length) {
+ System.arraycopy(src, srcPos, theArray, destPos, length);
+ }
+
+ /**
+ * @see org.apache.uima.cas.ArrayFS#copyToArray(int, FeatureStructure[], int, int)
+ */
+ public void copyToArray(int srcPos, FeatureStructure[] dest, int destPos, int length) {
+ System.arraycopy(theArray, srcPos, dest, destPos, length);
+ }
+
+ /**
+ * @see org.apache.uima.cas.ArrayFS#toArray()
+ */
+ public Object[] toArray() {
+ return theArray.clone();
+ }
+
+ /**
+ * Not supported, will throw UnsupportedOperationException
+ */
+ public void copyFromArray(String[] src, int srcPos, int destPos, int length) {
+ throw new UnsupportedOperationException();
+ }
+
+ /**
+ * Copies an array of Feature Structures to an Array of Strings.
+ * The strings are the "toString()" representation of the feature structures,
+ *
+ * @param srcPos
+ * The index of the first element to copy.
+ * @param dest
+ * The array to copy to.
+ * @param destPos
+ * Where to start copying into <code>dest</code>.
+ * @param length
+ * The number of elements to copy.
+ * @exception ArrayIndexOutOfBoundsException
+ * If <code>srcPos < 0</code> or
+ * <code>length > size()</code> or
+ * <code>destPos + length > destArray.length</code>.
+ */
+ public void copyToArray(int srcPos, String[] dest, int destPos, int length) {
+ _casView.checkArrayBounds(theArray.length, srcPos, length);
+ for (int i = 0; i < length; i++) {
+ dest[i + destPos] = theArray[i + srcPos].toString();
+ }
+ }
+
+ public String[] toStringArray() {
+ final int size = size();
+ String[] strArray = new String[size];
+ copyToArray(0, strArray, 0, size);
+ return strArray;
+ }
+
+ // internal use
+ public Object[] _getTheArray() {
+ return theArray;
+ }
+
+ /* (non-Javadoc)
+ * @see org.apache.uima.jcas.cas.CommonArray#copyValuesFrom(org.apache.uima.jcas.cas.CommonArray)
+ */
+ @Override
+ public void copyValuesFrom(CommonArray v) {
+ JavaObjectArray bv = (JavaObjectArray) v;
+ System.arraycopy(bv.theArray, 0, theArray, 0, theArray.length);
+ }
+
+ /* (non-Javadoc)
+ * @see org.apache.uima.jcas.cas.CommonPrimitiveArray#setArrayValueFromString(int, java.lang.String)
+ */
+ @Override
+ public void setArrayValueFromString(int i, String v) {
+// set(i, -- insert code for general string -> java object here
+// for use by XCAS, XMI);
+ throw new UnsupportedOperationException("Java Object deserialization not yet supported");
+ }
+
+
+}
Modified: uima/uimaj/branches/experiment-v3-jcas/unused-saved/src/org/apache/uima/jcas/impl/JCasCoverClassFactory.java
URL: http://svn.apache.org/viewvc/uima/uimaj/branches/experiment-v3-jcas/unused-saved/src/org/apache/uima/jcas/impl/JCasCoverClassFactory.java?rev=1768732&r1=1768731&r2=1768732&view=diff
==============================================================================
--- uima/uimaj/branches/experiment-v3-jcas/unused-saved/src/org/apache/uima/jcas/impl/JCasCoverClassFactory.java (original)
+++ uima/uimaj/branches/experiment-v3-jcas/unused-saved/src/org/apache/uima/jcas/impl/JCasCoverClassFactory.java Tue Nov 8 16:44:18 2016
@@ -1,3 +1,21 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
package org.apache.uima.cas.impl;
import java.util.List;
Modified: uima/uimaj/branches/experiment-v3-jcas/unused-saved/src/org/apache/uima/jcas/impl/JCasCoverClassFactoryTest.java
URL: http://svn.apache.org/viewvc/uima/uimaj/branches/experiment-v3-jcas/unused-saved/src/org/apache/uima/jcas/impl/JCasCoverClassFactoryTest.java?rev=1768732&r1=1768731&r2=1768732&view=diff
==============================================================================
--- uima/uimaj/branches/experiment-v3-jcas/unused-saved/src/org/apache/uima/jcas/impl/JCasCoverClassFactoryTest.java (original)
+++ uima/uimaj/branches/experiment-v3-jcas/unused-saved/src/org/apache/uima/jcas/impl/JCasCoverClassFactoryTest.java Tue Nov 8 16:44:18 2016
@@ -1,3 +1,21 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
package org.apache.uima.cas.impl;
import static org.junit.Assert.*;
Modified: uima/uimaj/branches/experiment-v3-jcas/unused-saved/src/org/apache/uima/jcasgen/impl/JCasClassConversion.java
URL: http://svn.apache.org/viewvc/uima/uimaj/branches/experiment-v3-jcas/unused-saved/src/org/apache/uima/jcasgen/impl/JCasClassConversion.java?rev=1768732&r1=1768731&r2=1768732&view=diff
==============================================================================
--- uima/uimaj/branches/experiment-v3-jcas/unused-saved/src/org/apache/uima/jcasgen/impl/JCasClassConversion.java (original)
+++ uima/uimaj/branches/experiment-v3-jcas/unused-saved/src/org/apache/uima/jcasgen/impl/JCasClassConversion.java Tue Nov 8 16:44:18 2016
@@ -1,3 +1,21 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
package org.apache.uima.jcasgen.impl;
import java.util.List;
Modified: uima/uimaj/branches/experiment-v3-jcas/unused-saved/src/study/asm/decompiled/AnnotationDumpV3.java
URL: http://svn.apache.org/viewvc/uima/uimaj/branches/experiment-v3-jcas/unused-saved/src/study/asm/decompiled/AnnotationDumpV3.java?rev=1768732&r1=1768731&r2=1768732&view=diff
==============================================================================
--- uima/uimaj/branches/experiment-v3-jcas/unused-saved/src/study/asm/decompiled/AnnotationDumpV3.java (original)
+++ uima/uimaj/branches/experiment-v3-jcas/unused-saved/src/study/asm/decompiled/AnnotationDumpV3.java Tue Nov 8 16:44:18 2016
@@ -1,3 +1,21 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
package asm.decompiled;
import java.util.*;