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 2015/11/09 20:41:45 UTC
svn commit: r1713521 -
/uima/uimaj/branches/experiment-v3-jcas/uimaj-core/src/main/java/org/apache/uima/cas/impl/TypeImpl.java
Author: schor
Date: Mon Nov 9 19:41:45 2015
New Revision: 1713521
URL: http://svn.apache.org/viewvc?rev=1713521&view=rev
Log:
[UIMA-4674] add accessor returning featureimpls
Modified:
uima/uimaj/branches/experiment-v3-jcas/uimaj-core/src/main/java/org/apache/uima/cas/impl/TypeImpl.java
Modified: uima/uimaj/branches/experiment-v3-jcas/uimaj-core/src/main/java/org/apache/uima/cas/impl/TypeImpl.java
URL: http://svn.apache.org/viewvc/uima/uimaj/branches/experiment-v3-jcas/uimaj-core/src/main/java/org/apache/uima/cas/impl/TypeImpl.java?rev=1713521&r1=1713520&r2=1713521&view=diff
==============================================================================
--- uima/uimaj/branches/experiment-v3-jcas/uimaj-core/src/main/java/org/apache/uima/cas/impl/TypeImpl.java (original)
+++ uima/uimaj/branches/experiment-v3-jcas/uimaj-core/src/main/java/org/apache/uima/cas/impl/TypeImpl.java Mon Nov 9 19:41:45 2015
@@ -21,6 +21,7 @@ package org.apache.uima.cas.impl;
import java.util.ArrayList;
import java.util.Arrays;
+import java.util.Collection;
import java.util.HashMap;
import java.util.Iterator;
import java.util.List;
@@ -98,6 +99,9 @@ public class TypeImpl implements Type, C
*/
protected final boolean isCreatableAndNotBuiltinArray;
+ /**
+ * false for primitives, strings, string subtypes, and JavaObjects
+ */
protected final boolean isRefType; // not a primitive, can be a FeatureStructure in the CAS, added to indexes etc.
@@ -130,7 +134,6 @@ public class TypeImpl implements Type, C
}
TypeImpl(String name, TypeSystemImpl tsi, final TypeImpl supertype, Class<?> javaClass) {
-
if (isStringSubtype() && supertype == tsi.stringType) {
tsi.newTypeCheckNoInheritanceFinalCheck(name, supertype);
} else {
@@ -273,7 +276,7 @@ public class TypeImpl implements Type, C
* particular order.
*
* @return The vector.
- * @deprecated
+ * @deprecated use getFeatures()
*/
@Override
@Deprecated
@@ -403,6 +406,10 @@ public class TypeImpl implements Type, C
return new ArrayList<>(staticMergedFeatures.values());
}
+ Collection<FeatureImpl> getFeatureImpls() {
+ return staticMergedFeatures.values();
+ }
+
Stream<FeatureImpl> getFeaturesAsStream() {
return staticMergedFeatures.values().stream();
}