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 2009/06/18 22:39:53 UTC

svn commit: r786255 [3/13] - in /incubator/uima/sandbox/trunk/ConfigurableFeatureExtractor: ./ src/ src/main/ src/main/java/ src/main/java/org/ src/main/java/org/apache/ src/main/java/org/apache/uima/ src/main/java/org/apache/uima/tools/ src/main/java/...

Added: incubator/uima/sandbox/trunk/ConfigurableFeatureExtractor/src/main/java/org/apache/uima/tools/cfe/SenseAnnotation_Type.java
URL: http://svn.apache.org/viewvc/incubator/uima/sandbox/trunk/ConfigurableFeatureExtractor/src/main/java/org/apache/uima/tools/cfe/SenseAnnotation_Type.java?rev=786255&view=auto
==============================================================================
--- incubator/uima/sandbox/trunk/ConfigurableFeatureExtractor/src/main/java/org/apache/uima/tools/cfe/SenseAnnotation_Type.java (added)
+++ incubator/uima/sandbox/trunk/ConfigurableFeatureExtractor/src/main/java/org/apache/uima/tools/cfe/SenseAnnotation_Type.java Thu Jun 18 20:39:50 2009
@@ -0,0 +1,79 @@
+
+/* First created by JCasGen Fri Mar 07 11:37:18 EST 2008 */
+package org.apache.uima.tools.cfe;
+
+import org.apache.uima.jcas.JCas;
+import org.apache.uima.jcas.JCasRegistry;
+import org.apache.uima.cas.impl.CASImpl;
+import org.apache.uima.cas.impl.FSGenerator;
+import org.apache.uima.cas.FeatureStructure;
+import org.apache.uima.cas.impl.TypeImpl;
+import org.apache.uima.cas.Type;
+import org.apache.uima.cas.impl.FeatureImpl;
+import org.apache.uima.cas.Feature;
+import org.apache.uima.jcas.tcas.Annotation_Type;
+
+/** contains manually preannotated sense, you can derive this with your own type, that might have additional information
+ * Updated by JCasGen Tue Mar 18 14:49:11 EDT 2008
+ * @generated */
+public class SenseAnnotation_Type extends Annotation_Type {
+  /** @generated */
+  protected FSGenerator getFSGenerator() {return fsGenerator;}
+  /** @generated */
+  private final FSGenerator fsGenerator = 
+    new FSGenerator() {
+      public FeatureStructure createFS(int addr, CASImpl cas) {
+  			 if (SenseAnnotation_Type.this.useExistingInstance) {
+  			   // Return eq fs instance if already created
+  		     FeatureStructure fs = SenseAnnotation_Type.this.jcas.getJfsFromCaddr(addr);
+  		     if (null == fs) {
+  		       fs = new SenseAnnotation(addr, SenseAnnotation_Type.this);
+  			   SenseAnnotation_Type.this.jcas.putJfsFromCaddr(addr, fs);
+  			   return fs;
+  		     }
+  		     return fs;
+        } else return new SenseAnnotation(addr, SenseAnnotation_Type.this);
+  	  }
+    };
+  /** @generated */
+  public final static int typeIndexID = SenseAnnotation.typeIndexID;
+  /** @generated 
+     @modifiable */
+  public final static boolean featOkTst = JCasRegistry.getFeatOkTst("org.apache.uima.cfe.SenseAnnotation");
+ 
+  /** @generated */
+  final Feature casFeat_SENSE;
+  /** @generated */
+  final int     casFeatCode_SENSE;
+  /** @generated */ 
+  public String getSENSE(int addr) {
+        if (featOkTst && casFeat_SENSE == null)
+      jcas.throwFeatMissing("SENSE", "org.apache.uima.cfe.SenseAnnotation");
+    return ll_cas.ll_getStringValue(addr, casFeatCode_SENSE);
+  }
+  /** @generated */    
+  public void setSENSE(int addr, String v) {
+        if (featOkTst && casFeat_SENSE == null)
+      jcas.throwFeatMissing("SENSE", "org.apache.uima.cfe.SenseAnnotation");
+    ll_cas.ll_setStringValue(addr, casFeatCode_SENSE, v);}
+    
+  
+
+
+
+  /** initialize variables to correspond with Cas Type and Features
+	* @generated */
+  public SenseAnnotation_Type(JCas jcas, Type casType) {
+    super(jcas, casType);
+    casImpl.getFSClassRegistry().addGeneratorForType((TypeImpl)this.casType, getFSGenerator());
+
+ 
+    casFeat_SENSE = jcas.getRequiredFeatureDE(casType, "SENSE", "uima.cas.String", featOkTst);
+    casFeatCode_SENSE  = (null == casFeat_SENSE) ? JCas.INVALID_FEATURE_CODE : ((FeatureImpl)casFeat_SENSE).getCode();
+
+  }
+}
+
+
+
+    
\ No newline at end of file

Added: incubator/uima/sandbox/trunk/ConfigurableFeatureExtractor/src/main/java/org/apache/uima/tools/cfe/SingleFeatureMatcher.java
URL: http://svn.apache.org/viewvc/incubator/uima/sandbox/trunk/ConfigurableFeatureExtractor/src/main/java/org/apache/uima/tools/cfe/SingleFeatureMatcher.java?rev=786255&view=auto
==============================================================================
--- incubator/uima/sandbox/trunk/ConfigurableFeatureExtractor/src/main/java/org/apache/uima/tools/cfe/SingleFeatureMatcher.java (added)
+++ incubator/uima/sandbox/trunk/ConfigurableFeatureExtractor/src/main/java/org/apache/uima/tools/cfe/SingleFeatureMatcher.java Thu Jun 18 20:39:50 2009
@@ -0,0 +1,134 @@
+package org.apache.uima.tools.cfe;
+
+import java.io.IOException;
+import java.lang.reflect.InvocationTargetException;
+import java.util.Collection;
+import java.util.Iterator;
+import java.util.List;
+
+
+public class SingleFeatureMatcher
+{
+    TargetObjectMatcher m_feature_matcher;
+    FeatureValues       m_feature_values;
+    final boolean       m_exclude;
+    final boolean       m_quiet;
+    
+    public SingleFeatureMatcher (String         feat_class_name,
+                                 String         feat_full_path,
+                                 boolean        exclude,
+                                 boolean        quiet,
+                                 FeatureValues  fvals)
+    throws SecurityException, NoSuchMethodException, ClassNotFoundException
+    {
+        m_feature_matcher = new TargetObjectMatcher(feat_class_name, feat_full_path, true);
+        m_exclude = exclude;
+        m_feature_values = fvals;
+        m_quiet = quiet;
+    }
+
+    public SingleFeatureMatcher (String             feat_class_name,
+                                 String             full_feat_path,
+                                 boolean            exclude,
+                                 boolean            quiet,
+                                 Collection<String> values,
+                                 boolean            case_sensitive)
+    throws SecurityException, NoSuchMethodException, ClassNotFoundException
+    {
+        this(feat_class_name, full_feat_path, exclude, quiet, new EnumFeatureValues(values, case_sensitive));
+    }
+
+    public SingleFeatureMatcher (String     feat_class_name,
+                                 String     full_feat_path,
+                                 boolean    exclude,
+                                 boolean    quiet,
+                                 String     path,
+                                 boolean    case_sensitive)
+    throws SecurityException, NoSuchMethodException, ClassNotFoundException, IOException
+    {
+        this(feat_class_name, full_feat_path, exclude, quiet, new EnumFeatureValues(path, case_sensitive));
+    }
+
+    public SingleFeatureMatcher (String     feat_class_name,
+                                 String     full_feat_path, 
+                                 boolean    exclude, 
+                                 boolean    quiet,
+                                 Double     lb,
+                                 boolean    lbi,
+                                 Double     ub,
+                                 boolean    ubi)
+    throws SecurityException, NoSuchMethodException, ClassNotFoundException
+    {
+        this(feat_class_name, full_feat_path, exclude, quiet, new RangeFeatureValues(lb, lbi, ub, ubi));
+    }
+
+    public SingleFeatureMatcher (String     feat_class_name,
+                                 String     full_feat_path,
+                                 boolean    exclude,
+                                 boolean    quiet,
+                                 int        bitmask,
+                                 boolean    exact_match)
+    throws SecurityException, NoSuchMethodException, ClassNotFoundException
+    {
+        this(feat_class_name, full_feat_path, exclude, quiet, new BitsetFeatureValues(bitmask, exact_match));
+    }
+
+    public SingleFeatureMatcher (String     feat_class_name,
+                                 String     full_feat_path,
+                                 boolean    exclude,
+                                 boolean    quiet,
+                                 String     pattern)
+    throws SecurityException, NoSuchMethodException, ClassNotFoundException
+    {
+        this(feat_class_name, full_feat_path, exclude, quiet, new PatternFeatureValues(pattern));
+    }
+
+    public boolean equals(Object obj)
+    {
+        if (this == obj) {
+            return true;
+        }
+        if (!(obj instanceof SingleFeatureMatcher)) {
+            return false;
+        }
+        SingleFeatureMatcher other = (SingleFeatureMatcher)obj;
+        if (!m_feature_matcher.equals(other.m_feature_matcher) ||
+            ((null == m_feature_values) && (null != other.m_feature_values)) ||
+            ((null != m_feature_values) && !m_feature_values.equals(other.m_feature_values)) ||
+            (m_exclude != other.m_exclude)) {
+            return false;
+        }
+        return super.equals(obj);
+    }
+
+
+    public boolean matches (MatchedValue mv, List<MatchedValue> matchedValues)
+    throws IllegalArgumentException, IllegalAccessException, InvocationTargetException
+    {
+        List<MatchedValue> vals = m_feature_matcher.getFeatureValues(mv);
+        // if vals is empty that means the feature value is not present (not even null)
+        // null pointers will be added to the list
+        
+        matchedValues.addAll(vals);
+
+        for (Iterator<MatchedValue> it = vals.iterator(); it.hasNext();) {
+            if (m_feature_values.matches(it.next().m_matchedObject)) {
+                return !m_exclude;
+            }
+        }
+        return m_exclude;
+    }
+    
+    void update(Object source)
+    throws IllegalArgumentException,
+           SecurityException,
+           ClassNotFoundException,
+           IllegalAccessException,
+           NoSuchFieldException,
+           InvocationTargetException
+    {
+        if (m_feature_values instanceof ObjectPathFeatureValues) { 
+            ((ObjectPathFeatureValues)m_feature_values).update(source, null, null);
+        }
+    }
+}

Added: incubator/uima/sandbox/trunk/ConfigurableFeatureExtractor/src/main/java/org/apache/uima/tools/cfe/TargetAnnotationDescriptor.java
URL: http://svn.apache.org/viewvc/incubator/uima/sandbox/trunk/ConfigurableFeatureExtractor/src/main/java/org/apache/uima/tools/cfe/TargetAnnotationDescriptor.java?rev=786255&view=auto
==============================================================================
--- incubator/uima/sandbox/trunk/ConfigurableFeatureExtractor/src/main/java/org/apache/uima/tools/cfe/TargetAnnotationDescriptor.java (added)
+++ incubator/uima/sandbox/trunk/ConfigurableFeatureExtractor/src/main/java/org/apache/uima/tools/cfe/TargetAnnotationDescriptor.java Thu Jun 18 20:39:50 2009
@@ -0,0 +1,67 @@
+package org.apache.uima.tools.cfe;
+
+import java.util.Collection;
+
+
+public class TargetAnnotationDescriptor
+{
+    String                  m_class_name;
+    String                  m_enclosing_annotation_name;
+    
+    PartialObjectMatcher                m_target_annotation_matcher;
+    Collection<FeatureObjectMatcher>    m_feature_annotation_matchers;
+    
+    final int               m_priorityOrder;
+    
+    
+    public TargetAnnotationDescriptor(String                            class_name,
+                                      String                            enclosing_annotation_name,
+                                      PartialObjectMatcher              target_annotation_matcher,
+                                      Collection<FeatureObjectMatcher>  feature_annotation_matchers,
+                                      int                               priorityOrder)
+   {
+        m_class_name = class_name;
+        m_enclosing_annotation_name = enclosing_annotation_name;
+        m_target_annotation_matcher = target_annotation_matcher;
+        m_feature_annotation_matchers = feature_annotation_matchers;
+        m_priorityOrder = priorityOrder;
+   }
+    
+    public boolean equals(Object obj)
+    {
+        if (this == obj) {
+            return true;
+        }
+        if (!(obj instanceof TargetAnnotationDescriptor)) {
+            return false;
+        }
+        TargetAnnotationDescriptor other = (TargetAnnotationDescriptor)obj;
+        if (!m_class_name.equals(other.m_class_name) ||
+            !m_enclosing_annotation_name.equals(other.m_enclosing_annotation_name) ||
+            !m_target_annotation_matcher.equals(other.m_target_annotation_matcher) ||
+            !m_feature_annotation_matchers.equals(other.m_feature_annotation_matchers)) {
+            return false;
+        }
+        return super.equals(obj);
+    }
+
+    String getClassName ()
+    {
+        return m_class_name;
+    }
+    
+    String getEnclosingAnnotationName ()
+    {
+        return m_enclosing_annotation_name;
+    }
+    
+    PartialObjectMatcher getTargetAnnotationMatcher ()
+    {
+        return m_target_annotation_matcher;
+    }
+
+    Collection<FeatureObjectMatcher> getFeatureAnnotationMatchers ()
+    {
+        return m_feature_annotation_matchers;
+    }
+}

Added: incubator/uima/sandbox/trunk/ConfigurableFeatureExtractor/src/main/java/org/apache/uima/tools/cfe/TargetObjectMatcher.java
URL: http://svn.apache.org/viewvc/incubator/uima/sandbox/trunk/ConfigurableFeatureExtractor/src/main/java/org/apache/uima/tools/cfe/TargetObjectMatcher.java?rev=786255&view=auto
==============================================================================
--- incubator/uima/sandbox/trunk/ConfigurableFeatureExtractor/src/main/java/org/apache/uima/tools/cfe/TargetObjectMatcher.java (added)
+++ incubator/uima/sandbox/trunk/ConfigurableFeatureExtractor/src/main/java/org/apache/uima/tools/cfe/TargetObjectMatcher.java Thu Jun 18 20:39:50 2009
@@ -0,0 +1,462 @@
+package org.apache.uima.tools.cfe;
+
+import java.lang.reflect.InvocationTargetException;
+import java.lang.reflect.Method;
+import java.util.ArrayList;
+import java.util.Arrays;
+import java.util.Comparator;
+import java.util.Iterator;
+import java.util.List;
+import java.util.regex.Matcher;
+import java.util.regex.Pattern;
+
+import org.apache.commons.jxpath.JXPathContext;
+import org.apache.uima.jcas.tcas.Annotation;
+import org.apache.uima.tools.cfe.support.ArrayComparatorFinder;
+
+public class TargetObjectMatcher
+{
+    private Class<?>        m_root_class;
+    private Class<?>        m_target_class;
+    private String[]        m_target_path_tokens;
+    private final boolean   m_delimit_array_values;
+    
+    static private final String KEYWORD_SORT = "sort";
+    
+    
+    public boolean equals (Object obj)
+    {
+        if (this == obj) {
+            return true;
+        }
+        if (!(obj instanceof TargetObjectMatcher)) {
+            return false;
+        }
+        TargetObjectMatcher other = (TargetObjectMatcher)obj;
+        if (!m_root_class.equals(other.m_root_class) ||
+            !isTargetClassMatches(other.m_target_class, true) ||
+            !m_target_path_tokens.equals(other.m_target_path_tokens)) {
+            return false;
+        }
+        return super.equals(obj);
+    }
+    
+    private TargetObjectMatcher (Class<?> target_class, String[] full_target_path_tokens, boolean delimit_array_values)
+    throws ClassNotFoundException
+    {
+        m_delimit_array_values = delimit_array_values;
+        m_target_class = target_class;
+        m_root_class = Class.forName(full_target_path_tokens[0]);
+        m_target_path_tokens = new String[full_target_path_tokens.length - 1];
+        for (int i = 1; i < full_target_path_tokens.length; ++i) {
+            m_target_path_tokens[i - 1] = full_target_path_tokens[i];
+        }
+    }
+    
+    public TargetObjectMatcher (Class<? extends Object> target_class, String full_target_path, boolean delimit_array_values)
+    throws ClassNotFoundException
+    {
+        this(target_class, full_target_path.split("\\:"), delimit_array_values);
+    }
+
+    public TargetObjectMatcher (String trg_cls_name, String full_target_path, boolean delimit_array_values)
+    throws ClassNotFoundException
+    {
+        this((null == trg_cls_name) || (0 == trg_cls_name.length()) ? null : Class.forName(trg_cls_name),
+              full_target_path,
+              delimit_array_values);
+    }
+    
+//    private TargetObjectMatcher (PartialObjectMatcher pom, boolean delimit_array_values)
+//    throws ClassNotFoundException
+//    {
+//        this(pom.getMatcherClass(), pom.getObjectPath(), delimit_array_values);
+//    }
+
+    Class<?> getRootClass ()
+    {
+        return m_root_class;
+    }
+
+    Class<?> getTargetClass ()
+    {
+        return m_target_class;
+    }
+
+    boolean isTargetClassMatches (Class<?> cls, boolean exact)
+    {
+        if (null == m_target_class) {
+            return exact ? (null == cls) : true;
+        }
+        return exact ?  m_target_class.equals(cls) :  m_target_class.isAssignableFrom(cls);
+    }
+
+    String getFeaturePathImage ()
+    {
+        String result = "";
+        for (int i = 0; i < m_target_path_tokens.length; ++i) {
+            if (0 != i) {
+                result += "_";
+            }
+            result += m_target_path_tokens[i];
+        }
+        return result;
+    }
+
+    boolean isDetached()
+    {
+        return isTargetClassMatches(m_root_class, true);
+    }
+    
+    static private Method findGetMethod (Class<?>      obj_class,
+                                         String        method_name)
+    {
+        return findMethod(obj_class, method_name, (Class[])null, null);
+    }
+    
+    static private Method findMethod (Class<?>      obj_class,
+                                         String        method_name,
+                                         Class<?>[]    method_params,
+                                         Class<?>      method_return)
+    {
+        Method[] mtds = obj_class.getMethods();
+        for (int m_ind = 0; m_ind < mtds.length; ++m_ind) {
+            if (!mtds[m_ind].getName().equals(method_name)) {
+                continue;
+            }
+            if ((null == method_params) && (mtds[m_ind].getParameterTypes().length > 0)) {
+                continue;
+            }
+            else if ((null != method_params) && !Arrays.equals(method_params, mtds[m_ind].getParameterTypes())) {
+                continue;
+            }
+            if ((null != method_return) && !method_return.equals(mtds[m_ind].getReturnType())) {
+                continue;
+            }
+            return mtds[m_ind];
+        }
+        return null;
+    }
+    
+    
+    static private Pattern m_featname_pattern = Pattern.compile("([^\\[\\]]+)");
+    
+    static String parseFeatureName(String feature, List<String> postProcOps)
+    {
+        Matcher m = m_featname_pattern.matcher(feature);
+        
+        String result = null;
+        while (m.find()) {
+            String group = m.group();
+            if (null == result) {
+                result = group;
+                continue;
+            }
+            postProcOps.add(group);
+        }
+        if (null == result) {
+            return feature;
+        }
+        return result;
+    }
+    
+    static Object[] processPostProcOps (Object[] elements, List<String> postProcOps)
+    {
+        List<Object> new_elements = new ArrayList<Object>();
+        boolean use_new_elements = false;
+        
+        for (Iterator<String> it = postProcOps.iterator(); it.hasNext();) {
+            String op_name = it.next();
+            
+            if (op_name.matches("^\\d+")) {
+                use_new_elements = true;
+                int ind = Integer.parseInt(op_name);
+                if (ind < elements.length) {
+                    new_elements.add(elements[ind]);
+                }
+            }
+            else {
+                if (op_name.matches("\\d+..(-1|\\d+)")) {
+                    use_new_elements = true;
+                    String[] boundaries = op_name.split("\\.\\.");
+                    assert(2 == boundaries.length);
+                    int b = Integer.parseInt(boundaries[0]);
+                    int e = Integer.parseInt(boundaries[1]);
+                    e = (-1 == e) ? elements.length - 1 : Math.min(e, elements.length - 1);
+                    while (b <= e) {
+                        new_elements.add(elements[b++]);
+                    }
+                }
+                else if (op_name.equals(KEYWORD_SORT)) {
+                    if (use_new_elements) {
+                        elements = new_elements.toArray();
+                        new_elements.clear();
+                    }
+                    Comparator<Annotation> cmptr = ArrayComparatorFinder.find(elements);
+                    if (null != cmptr) {
+                        Arrays.sort((Annotation[])elements, cmptr);
+                    }
+                }
+            }
+        }
+        if (use_new_elements) {
+            elements = new_elements.toArray();
+            new_elements.clear();
+        }
+        return elements;
+    }
+/*
+    private void getMatchedValues (Object[]             objs,
+                                   String[]             features,
+                                   int                  feat_ind,
+                                   List<MatchedValue>   matchedValues,
+                                   int                  array_level,
+                                   List<Object>         orderedPath)
+    throws IllegalArgumentException, IllegalAccessException, InvocationTargetException
+    {        
+
+        String toks[] = features[feat_ind].split("\\|");
+
+        for (int i = 0; i < objs.length; ++i) {
+            if (null == objs[i]) {
+                continue;
+            }
+            Object result = null;
+            
+            List<String> postProcOps = new ArrayList<String>();
+            for (int tok_ind = 0; tok_ind < toks.length; ++tok_ind) {
+                postProcOps.clear();
+                String feat_name = parseFeatureName(toks[tok_ind], postProcOps);
+                Method get_feat_method = findGetMethod(objs[i].getClass(), feat_name);
+                if (null == get_feat_method) {
+                    feat_name = "get" + PrimitiveFeatureTransformer.capitalize(feat_name); 
+                    get_feat_method = findGetMethod(objs[i].getClass(), feat_name);
+                    if (null == get_feat_method) {
+                        // no such feature 
+                        System.err.println("Class \"" + objs[i].getClass().getName() +
+                                           "\": Feature:\"" + feat_name + "\" is not found");
+                        break;
+                    }
+                }
+                result = get_feat_method.invoke(objs[i], (Object[])null);
+                if (null != result) {
+                    break;
+                }
+            }
+            // increment the feature index now
+            int next_feat_ind = feat_ind + 1;
+            
+            if (null == result) {
+                matchedValues.add(new MatchedValue(null, orderedPath));
+                if (m_delimit_array_values && (i < (objs.length - 1))) {
+                    matchedValues.add(new MatchedValue(new ArrayDelimiterObject(array_level), orderedPath));
+                }
+                continue; // through the rest of obj
+            }
+            if (result.getClass().isArray()) {
+                Object[] elements = (Object[])result;
+                if (!postProcOps.isEmpty()) {
+                    elements = processPostProcOps(elements, postProcOps);
+                }
+                orderedPath.add(elements);
+                for (int j = 0; j < elements.length; ++j) {
+                    if (features.length == next_feat_ind) {
+                        if ((null == elements[j]) || isTargetClassMatches(elements[j].getClass(), false)) {
+                            matchedValues.add(new MatchedValue(elements[j], orderedPath));
+                            if (m_delimit_array_values && (j < (elements.length - 1))) {
+                                matchedValues.add(new MatchedValue(new ArrayDelimiterObject(array_level), orderedPath));
+                            }
+                        }
+                    }
+                }
+                if (features.length == next_feat_ind) {
+                    continue; // through the rest of obj
+                }
+                if (m_delimit_array_values) {
+                    MatchedValue mv = matchedValues.get(0);
+                    mv.m_matchedObject = new ArrayDelimiterObject(array_level + 1);
+                }
+                getMatchedValues(elements, features, next_feat_ind, matchedValues, array_level + 1, orderedPath);
+            }
+            else {
+                if (features.length == next_feat_ind) {
+                    if (isTargetClassMatches(result.getClass(), false)) {
+                        matchedValues.add(new MatchedValue(result, orderedPath));
+                        if (m_delimit_array_values && (i < (objs.length - 1))) {
+                            matchedValues.add(new MatchedValue(new ArrayDelimiterObject(array_level), orderedPath));
+                        }
+                    }
+                    continue; // through the rest of obj
+                }
+                orderedPath.add(result);
+                
+                getMatchedValues(new Object[] {result}, features, next_feat_ind, matchedValues, array_level, orderedPath);
+            }
+            if (m_delimit_array_values && (i < (objs.length - 1))) {
+                matchedValues.add(new MatchedValue(new ArrayDelimiterObject(array_level), orderedPath));
+            }
+        }
+    }
+  */  
+    
+    public List<MatchedValue> getFeatureValues (MatchedValue mv)
+    throws IllegalArgumentException, IllegalAccessException, InvocationTargetException
+    {
+        // allows derived classes to be processed
+        List<MatchedValue> result = new ArrayList<MatchedValue>();
+        if (m_delimit_array_values) {
+            // set max array level
+            result.add(new MatchedValue(new ArrayDelimiterObject(0), new ArrayList<Object>()));
+        }
+        
+        if (! m_root_class.isAssignableFrom(mv.m_matchedObject.getClass())) {
+            return result;
+        }
+        else if (0 == m_target_path_tokens.length) {
+            if (isTargetClassMatches(mv.m_matchedObject.getClass(), false)) {
+                result.add(mv);
+            }
+            return result;
+        }
+        
+        if ((1 == m_target_path_tokens.length) && m_target_path_tokens[0].contains("/")) {
+            // if the path is an xpath (separator is '/') then it will 
+            // be a single "token" as parsing only splits on ':'
+            // WARNING: JXPath is not supported!!! just experimenting
+            // the biggest issue so far is that elements of arrays are not separated
+            // by the objects containing them,
+            // so for the path:
+            //      array_feature1/regular_feature/array_feature2/regular_feature2
+            // all values for regular_feature2 are iterated by a single iterator
+            // and it is not clear to which element of array_feature1 a particular 
+            // regular_feature2 belongs
+            JXPathContext ctx = JXPathContext.newContext(mv.m_matchedObject);
+            ctx.setLenient(true);
+            for (Iterator<?> it = ctx.iterate(m_target_path_tokens[0]); it.hasNext();) {
+                // System.out.printf("%s=%s\n", m_target_path_tokens[0], it.next());
+                if (result.size() > 1 && m_delimit_array_values) {
+                    result.add(new MatchedValue(new ArrayDelimiterObject(0), new ArrayList<Object>()));                    
+                }
+                result.add(new MatchedValue(it.next(), new ArrayList<Object>()));
+            }
+        }
+        else {
+            getMatchedValues(new Object[] {mv.m_matchedObject}, mv.m_orderedPath, m_target_path_tokens, 0, result, new ArrayList<Object>(), -1);
+        }
+        return result;
+    }
+    
+    
+    private void getMatchedValues (Object[]             objs,
+                                   List<Object>         rootOrderedPath,
+                                   String[]             features,
+                                   int                  feat_ind,
+                                   List<MatchedValue>   matchedValues,
+                                   List<Object>         matchedOrderedPath,
+                                   int                  array_level)
+    throws IllegalArgumentException, IllegalAccessException, InvocationTargetException
+    {        
+
+        String operations[] = feat_ind < features.length ? features[feat_ind].split("\\|") : null;
+        
+        for (int i = 0; i < objs.length; ++i) {
+            if (feat_ind == features.length) {
+                if ((null == objs[i]) || isTargetClassMatches(objs[i].getClass(), false)) {
+                    matchedValues.add(new MatchedValue(objs[i], matchedOrderedPath));
+                }
+                continue;
+            }
+            if (null == objs[i]) {
+                continue;
+            }
+            matchedOrderedPath.add(objs[i]);
+            List<Object> mop = (1 == objs.length) ? matchedOrderedPath : new ArrayList<Object>(matchedOrderedPath);
+            getMatchedValues(objs[i], rootOrderedPath, features, feat_ind, matchedValues, mop, array_level, operations);
+            if (m_delimit_array_values && (i < (objs.length - 1))) {
+                matchedValues.add(new MatchedValue(new ArrayDelimiterObject(array_level), mop));
+            }
+        }
+    }
+
+    
+    static private Pattern m_parentPattern = Pattern.compile("__p([\\d]+)");
+    
+    Object getOperationResult (Object       obj,
+                               List<Object> rootOrderedPath,
+                               String []    operations,
+                               List<String> postProcOps)
+    throws IllegalArgumentException,
+           IllegalAccessException, 
+           InvocationTargetException
+    {
+        Object result = null;
+        for (int tok_ind = 0; tok_ind < operations.length; ++tok_ind) {
+            postProcOps.clear();
+            String feat_name = parseFeatureName(operations[tok_ind], postProcOps);
+            Matcher m = m_parentPattern.matcher(feat_name);
+            int parInd = Integer.MIN_VALUE;
+            if (m.find()) {
+                parInd = Integer.parseInt(m.group(1));
+                if (m.find()) {
+                    throw new IllegalArgumentException("malformed operation name");
+                }
+                // no check. an exception to be thrown in case of an error
+                result = rootOrderedPath.get(parInd);
+                break;
+            }
+            Method get_feat_method = findGetMethod(obj.getClass(), feat_name);
+            if (null == get_feat_method) {
+                feat_name = "get" + PrimitiveFeatureTransformer.capitalize(feat_name); 
+                get_feat_method = findGetMethod(obj.getClass(), feat_name);
+                if (null == get_feat_method) {
+                    // no such feature 
+                    System.err.println("Class \"" + obj.getClass().getName() +
+                                       "\": Feature:\"" + feat_name + "\" is not found");
+                    break;
+                }
+            }
+            result = get_feat_method.invoke(obj, (Object[])null);
+            if (null != result) {
+                break;
+            }
+        }
+        return result;
+    }
+    
+    private void getMatchedValues (Object               obj,
+                                   List<Object>         rootOrderedPath,
+                                   String[]             features,
+                                   int                  feat_ind,
+                                   List<MatchedValue>   matchedValues,
+                                   List<Object>         matchedOrderedPath,
+                                   int                  array_level,
+                                   String []            operations)
+    throws IllegalArgumentException, IllegalAccessException, InvocationTargetException
+    {
+        List<String> postProcOps = new ArrayList<String>();
+        Object result = getOperationResult(obj, rootOrderedPath, operations, postProcOps);
+        if (null == result) {
+            matchedValues.add(new MatchedValue(null, matchedOrderedPath));
+            return;
+        }
+        
+        // increment the feature index now
+        int next_feat_ind = feat_ind + 1;
+        
+        
+        if (result.getClass().isArray()) {
+            Object[] elements = (Object[])result;
+            if (!postProcOps.isEmpty()) {
+                elements = processPostProcOps(elements, postProcOps);
+            }
+            if (m_delimit_array_values) {
+                MatchedValue mv = matchedValues.get(0);
+                mv.m_matchedObject = new ArrayDelimiterObject(array_level + 1);
+            }
+            getMatchedValues(elements, rootOrderedPath, features, next_feat_ind, matchedValues, matchedOrderedPath, array_level + 1);
+        }
+        else {
+            getMatchedValues(new Object[] {result}, rootOrderedPath, features, next_feat_ind, matchedValues, matchedOrderedPath, array_level);
+        }
+    }
+}

Added: incubator/uima/sandbox/trunk/ConfigurableFeatureExtractor/src/main/java/org/apache/uima/tools/cfe/UIMAFeatureConsumer.java
URL: http://svn.apache.org/viewvc/incubator/uima/sandbox/trunk/ConfigurableFeatureExtractor/src/main/java/org/apache/uima/tools/cfe/UIMAFeatureConsumer.java?rev=786255&view=auto
==============================================================================
--- incubator/uima/sandbox/trunk/ConfigurableFeatureExtractor/src/main/java/org/apache/uima/tools/cfe/UIMAFeatureConsumer.java (added)
+++ incubator/uima/sandbox/trunk/ConfigurableFeatureExtractor/src/main/java/org/apache/uima/tools/cfe/UIMAFeatureConsumer.java Thu Jun 18 20:39:50 2009
@@ -0,0 +1,79 @@
+package org.apache.uima.tools.cfe;
+
+import java.io.File;
+import java.io.FileOutputStream;
+import java.util.Iterator;
+
+import org.apache.uima.cas.CAS;
+import org.apache.uima.collection.CasConsumer_ImplBase;
+import org.apache.uima.jcas.JCas;
+import org.apache.uima.resource.ResourceInitializationException;
+import org.apache.uima.resource.ResourceProcessException;
+import org.apache.uima.tools.cfe.support.ComparableArray;
+
+;
+
+public class UIMAFeatureConsumer
+    extends CasConsumer_ImplBase
+{
+    public static final String PARAM_OUTPUTDIRECTORY = "OutputDirectory";
+    
+
+    private String m_outdir;
+    private UIMAFeatureMatcher m_uimaFM;
+
+
+    public void initialize ()
+    throws ResourceInitializationException
+    {
+        super.initialize();
+        
+        try {
+            m_uimaFM = new UIMAFeatureMatcher(
+                    ((Boolean)getConfigParameterValue(CommonFeatureMatcher.PARAM_INCLUDETARGETID)).booleanValue());
+            
+            String cfgFile = (String)getConfigParameterValue(CommonFeatureMatcher.PARAM_CONFIGURATIONFILE);
+            if (null != cfgFile) {
+                Boolean isXMLBeansarser = (Boolean)getConfigParameterValue(CommonFeatureMatcher.PARAM_XMLBEANSPARSER);
+                m_uimaFM.initialize(cfgFile, null == isXMLBeansarser ? false : isXMLBeansarser.booleanValue());;
+            }
+
+            m_outdir = (String)getConfigParameterValue(PARAM_OUTPUTDIRECTORY);
+        }
+        catch (Exception e) {
+            e.printStackTrace();
+            throw new ResourceInitializationException(e);
+        }
+    }
+    
+    public void processCas (CAS cas)
+    throws ResourceProcessException
+    {
+        try {
+
+            JCas jcas = cas.getJCas();
+            
+            String docId = CommonFeatureMatcher.getDocumentId(jcas, null);
+            System.out.println("Processing " + docId);
+            
+            m_uimaFM.processJCas(jcas);
+            if (m_uimaFM.m_featureImages.isEmpty()) {
+                return;
+            }
+            
+            File f = new File(m_outdir);
+            if (!f.exists()) {
+                System.err.println("Directory " + m_outdir + " does not exist, creating");
+                f.mkdirs();
+            }
+            
+            FileOutputStream fos = new FileOutputStream(m_outdir + "/" + docId + ".fve");
+            for (Iterator<ComparableArray> it = m_uimaFM.m_featureImages.keySet().iterator(); it.hasNext();) {
+                fos.write((m_uimaFM.m_featureImages.get(it.next()) + "\n").getBytes());
+            }
+        } 
+        catch (Exception e) {
+            throw new ResourceProcessException(e);
+        }   
+    }
+}

Added: incubator/uima/sandbox/trunk/ConfigurableFeatureExtractor/src/main/java/org/apache/uima/tools/cfe/UIMAFeatureMatcher.java
URL: http://svn.apache.org/viewvc/incubator/uima/sandbox/trunk/ConfigurableFeatureExtractor/src/main/java/org/apache/uima/tools/cfe/UIMAFeatureMatcher.java?rev=786255&view=auto
==============================================================================
--- incubator/uima/sandbox/trunk/ConfigurableFeatureExtractor/src/main/java/org/apache/uima/tools/cfe/UIMAFeatureMatcher.java (added)
+++ incubator/uima/sandbox/trunk/ConfigurableFeatureExtractor/src/main/java/org/apache/uima/tools/cfe/UIMAFeatureMatcher.java Thu Jun 18 20:39:50 2009
@@ -0,0 +1,68 @@
+package org.apache.uima.tools.cfe;
+
+import java.lang.reflect.InvocationTargetException;
+import java.util.Collection;
+import java.util.Iterator;
+import java.util.Map;
+import java.util.TreeMap;
+
+import org.apache.uima.jcas.JCas;
+import org.apache.uima.jcas.tcas.Annotation;
+import org.apache.uima.tools.cfe.support.ComparableArray;
+
+
+public class UIMAFeatureMatcher extends CommonFeatureMatcher 
+{
+    Map<ComparableArray, String> m_featureImages;
+    
+    public UIMAFeatureMatcher (boolean includeTargetId)
+    {
+        super(includeTargetId, false, false, "|", new String[] {";", "^", "!", "%"});
+    }
+    
+    public void processJCas (JCas jcas)
+    throws IllegalArgumentException,
+           IllegalAccessException,
+           InvocationTargetException,
+           ClassNotFoundException,
+           SecurityException,
+           NoSuchFieldException
+    {
+        // to make features sorted by begin/end offsets
+        m_featureImages = new TreeMap<ComparableArray, String>();
+        super.processJCas(jcas);
+    }
+
+    protected void processFeatureGroup(JCas                                     jcas,
+                                       Annotation                               trg,
+                                       String                                   group_label,
+                                       Collection<MatchedAnnotationDescriptor>  features)
+    throws IllegalArgumentException, IllegalAccessException, InvocationTargetException
+    {
+        for (Iterator<MatchedAnnotationDescriptor> feat_it = features.iterator(); feat_it.hasNext();) {
+            MatchedAnnotationDescriptor mad = feat_it.next();
+            ComparableArray key = new ComparableArray(
+                new Integer[] {new Integer(mad.m_feature_mv.getAnnotation().getEnd()),
+                               new Integer(mad.m_feature_mv.getAnnotation().getBegin()),
+                               new Integer(mad.m_orderIndex),
+                               new Integer(m_featureImages.size())});
+            
+            String feature = make_UIMA_feature(mad, make_image(mad, trg));
+            m_featureImages.put(key, group_label + m_fieldSeparator + feature);
+        }
+    }
+    
+
+    
+    String make_UIMA_feature (MatchedAnnotationDescriptor   mad,
+                              String                        other_fields)
+    {
+        StringBuffer stBuff = new StringBuffer();
+        if (mad.m_feature_matcher.m_orientation || mad.m_feature_matcher.m_distance) {
+            stBuff.append(make_image_position(mad));
+            stBuff.append(m_fieldSeparator);
+        }
+        stBuff.append(other_fields);
+        return stBuff.toString(); 
+    }
+}

Added: incubator/uima/sandbox/trunk/ConfigurableFeatureExtractor/src/main/java/org/apache/uima/tools/cfe/UIMAFeatureTransformer.java
URL: http://svn.apache.org/viewvc/incubator/uima/sandbox/trunk/ConfigurableFeatureExtractor/src/main/java/org/apache/uima/tools/cfe/UIMAFeatureTransformer.java?rev=786255&view=auto
==============================================================================
--- incubator/uima/sandbox/trunk/ConfigurableFeatureExtractor/src/main/java/org/apache/uima/tools/cfe/UIMAFeatureTransformer.java (added)
+++ incubator/uima/sandbox/trunk/ConfigurableFeatureExtractor/src/main/java/org/apache/uima/tools/cfe/UIMAFeatureTransformer.java Thu Jun 18 20:39:50 2009
@@ -0,0 +1,24 @@
+package org.apache.uima.tools.cfe;
+
+import org.apache.uima.jcas.cas.FSArray;
+import org.apache.uima.jcas.tcas.Annotation;
+
+
+public class UIMAFeatureTransformer extends PrimitiveFeatureTransformer
+{
+    UIMAFeatureTransformer(boolean case_sensitive)
+    {
+        super(case_sensitive);
+    }
+    
+    public String convert (Object feature)
+    {
+        if (feature instanceof FSArray) {
+            return feature.getClass().getName() + "_" + ((FSArray)feature).size();  
+        }
+        else if (feature instanceof Annotation) {
+            return feature.getClass().getName(); 
+        }
+        return super.convert(feature);
+    }
+}

Added: incubator/uima/sandbox/trunk/ConfigurableFeatureExtractor/src/main/java/org/apache/uima/tools/cfe/config/BitsetFeatureValuesXML.java
URL: http://svn.apache.org/viewvc/incubator/uima/sandbox/trunk/ConfigurableFeatureExtractor/src/main/java/org/apache/uima/tools/cfe/config/BitsetFeatureValuesXML.java?rev=786255&view=auto
==============================================================================
--- incubator/uima/sandbox/trunk/ConfigurableFeatureExtractor/src/main/java/org/apache/uima/tools/cfe/config/BitsetFeatureValuesXML.java (added)
+++ incubator/uima/sandbox/trunk/ConfigurableFeatureExtractor/src/main/java/org/apache/uima/tools/cfe/config/BitsetFeatureValuesXML.java Thu Jun 18 20:39:50 2009
@@ -0,0 +1,112 @@
+/**
+ * <copyright>
+ * </copyright>
+ *
+ * $Id$
+ */
+package org.apache.uima.tools.cfe.config;
+
+import org.eclipse.emf.ecore.EObject;
+
+
+/**
+ * <!-- begin-user-doc -->
+ * A representation of the model object '<em><b>Bitset Feature Values XML</b></em>'.
+ * <!-- end-user-doc -->
+ *
+ * <p>
+ * The following features are supported:
+ * <ul>
+ *   <li>{@link org.apache.uima.tools.cfe.config.BitsetFeatureValuesXML#getBitmask <em>Bitmask</em>}</li>
+ *   <li>{@link org.apache.uima.tools.cfe.config.BitsetFeatureValuesXML#isExactMatch <em>Exact Match</em>}</li>
+ * </ul>
+ * </p>
+ *
+ * @see org.apache.uima.tools.cfe.config.ConfigPackage#getBitsetFeatureValuesXML()
+ * @model extendedMetaData="name='BitsetFeatureValuesXML' kind='empty'"
+ * @generated
+ */
+public interface BitsetFeatureValuesXML extends EObject
+{
+  /**
+     * Returns the value of the '<em><b>Bitmask</b></em>' attribute.
+     * <!-- begin-user-doc -->
+   * <p>
+   * If the meaning of the '<em>Bitmask</em>' attribute isn't clear,
+   * there really should be more of a description here...
+   * </p>
+   * <!-- end-user-doc -->
+     * @return the value of the '<em>Bitmask</em>' attribute.
+     * @see #setBitmask(String)
+     * @see org.apache.uima.tools.cfe.config.ConfigPackage#getBitsetFeatureValuesXML_Bitmask()
+     * @model dataType="org.eclipse.emf.ecore.xml.type.String" required="true"
+     *        extendedMetaData="kind='attribute' name='bitmask'"
+     * @generated
+     */
+  String getBitmask();
+
+  /**
+     * Sets the value of the '{@link org.apache.uima.tools.cfe.config.BitsetFeatureValuesXML#getBitmask <em>Bitmask</em>}' attribute.
+     * <!-- begin-user-doc -->
+   * <!-- end-user-doc -->
+     * @param value the new value of the '<em>Bitmask</em>' attribute.
+     * @see #getBitmask()
+     * @generated
+     */
+  void setBitmask(String value);
+
+  /**
+     * Returns the value of the '<em><b>Exact Match</b></em>' attribute.
+     * <!-- begin-user-doc -->
+   * <p>
+   * If the meaning of the '<em>Exact Match</em>' attribute isn't clear,
+   * there really should be more of a description here...
+   * </p>
+   * <!-- end-user-doc -->
+     * @return the value of the '<em>Exact Match</em>' attribute.
+     * @see #isSetExactMatch()
+     * @see #unsetExactMatch()
+     * @see #setExactMatch(boolean)
+     * @see org.apache.uima.tools.cfe.config.ConfigPackage#getBitsetFeatureValuesXML_ExactMatch()
+     * @model unsettable="true" dataType="org.eclipse.emf.ecore.xml.type.Boolean"
+     *        extendedMetaData="kind='attribute' name='exact_match'"
+     * @generated
+     */
+  boolean isExactMatch();
+
+  /**
+     * Sets the value of the '{@link org.apache.uima.tools.cfe.config.BitsetFeatureValuesXML#isExactMatch <em>Exact Match</em>}' attribute.
+     * <!-- begin-user-doc -->
+   * <!-- end-user-doc -->
+     * @param value the new value of the '<em>Exact Match</em>' attribute.
+     * @see #isSetExactMatch()
+     * @see #unsetExactMatch()
+     * @see #isExactMatch()
+     * @generated
+     */
+  void setExactMatch(boolean value);
+
+  /**
+     * Unsets the value of the '{@link org.apache.uima.tools.cfe.config.BitsetFeatureValuesXML#isExactMatch <em>Exact Match</em>}' attribute.
+     * <!-- begin-user-doc -->
+   * <!-- end-user-doc -->
+     * @see #isSetExactMatch()
+     * @see #isExactMatch()
+     * @see #setExactMatch(boolean)
+     * @generated
+     */
+  void unsetExactMatch();
+
+  /**
+     * Returns whether the value of the '{@link org.apache.uima.tools.cfe.config.BitsetFeatureValuesXML#isExactMatch <em>Exact Match</em>}' attribute is set.
+     * <!-- begin-user-doc -->
+   * <!-- end-user-doc -->
+     * @return whether the value of the '<em>Exact Match</em>' attribute is set.
+     * @see #unsetExactMatch()
+     * @see #isExactMatch()
+     * @see #setExactMatch(boolean)
+     * @generated
+     */
+  boolean isSetExactMatch();
+
+} // BitsetFeatureValuesXML
\ No newline at end of file

Added: incubator/uima/sandbox/trunk/ConfigurableFeatureExtractor/src/main/java/org/apache/uima/tools/cfe/config/CFEDescriptorXML.java
URL: http://svn.apache.org/viewvc/incubator/uima/sandbox/trunk/ConfigurableFeatureExtractor/src/main/java/org/apache/uima/tools/cfe/config/CFEDescriptorXML.java?rev=786255&view=auto
==============================================================================
--- incubator/uima/sandbox/trunk/ConfigurableFeatureExtractor/src/main/java/org/apache/uima/tools/cfe/config/CFEDescriptorXML.java (added)
+++ incubator/uima/sandbox/trunk/ConfigurableFeatureExtractor/src/main/java/org/apache/uima/tools/cfe/config/CFEDescriptorXML.java Thu Jun 18 20:39:50 2009
@@ -0,0 +1,76 @@
+/**
+ * <copyright>
+ * </copyright>
+ *
+ * $Id$
+ */
+package org.apache.uima.tools.cfe.config;
+
+import org.eclipse.emf.common.util.EList;
+import org.eclipse.emf.ecore.EObject;
+import java.util.List;
+
+/**
+ * <!-- begin-user-doc -->
+ * A representation of the model object '<em><b>CFE Descriptor XML</b></em>'.
+ * <!-- end-user-doc -->
+ *
+ * <p>
+ * The following features are supported:
+ * <ul>
+ *   <li>{@link org.apache.uima.tools.cfe.config.CFEDescriptorXML#getTargetAnnotations <em>Target Annotations</em>}</li>
+ *   <li>{@link org.apache.uima.tools.cfe.config.CFEDescriptorXML#getNullValueImage <em>Null Value Image</em>}</li>
+ * </ul>
+ * </p>
+ *
+ * @see org.apache.uima.tools.cfe.config.ConfigPackage#getCFEDescriptorXML()
+ * @model extendedMetaData="name='CFEDescriptorXML' kind='elementOnly'"
+ * @generated
+ */
+public interface CFEDescriptorXML extends EObject
+{
+  /**
+     * Returns the value of the '<em><b>Target Annotations</b></em>' containment reference list.
+     * The list contents are of type {@link org.apache.uima.tools.cfe.config.TargetAnnotationXML}.
+     * <!-- begin-user-doc -->
+   * <p>
+   * If the meaning of the '<em>Target Annotations</em>' containment reference list isn't clear,
+   * there really should be more of a description here...
+   * </p>
+   * <!-- end-user-doc -->
+     * @return the value of the '<em>Target Annotations</em>' containment reference list.
+     * @see org.apache.uima.tools.cfe.config.ConfigPackage#getCFEDescriptorXML_TargetAnnotations()
+     * @model containment="true" required="true"
+     *        extendedMetaData="kind='element' name='targetAnnotations' namespace='##targetNamespace'"
+     * @generated
+     */
+  EList<TargetAnnotationXML> getTargetAnnotations();
+
+  /**
+     * Returns the value of the '<em><b>Null Value Image</b></em>' attribute.
+     * <!-- begin-user-doc -->
+   * <p>
+   * If the meaning of the '<em>Null Value Image</em>' attribute isn't clear,
+   * there really should be more of a description here...
+   * </p>
+   * <!-- end-user-doc -->
+     * @return the value of the '<em>Null Value Image</em>' attribute.
+     * @see #setNullValueImage(String)
+     * @see org.apache.uima.tools.cfe.config.ConfigPackage#getCFEDescriptorXML_NullValueImage()
+     * @model dataType="org.eclipse.emf.ecore.xml.type.String"
+     *        extendedMetaData="kind='attribute' name='nullValueImage'"
+     * @generated
+     */
+  String getNullValueImage();
+
+  /**
+     * Sets the value of the '{@link org.apache.uima.tools.cfe.config.CFEDescriptorXML#getNullValueImage <em>Null Value Image</em>}' attribute.
+     * <!-- begin-user-doc -->
+   * <!-- end-user-doc -->
+     * @param value the new value of the '<em>Null Value Image</em>' attribute.
+     * @see #getNullValueImage()
+     * @generated
+     */
+  void setNullValueImage(String value);
+
+} // CFEDescriptorXML
\ No newline at end of file

Added: incubator/uima/sandbox/trunk/ConfigurableFeatureExtractor/src/main/java/org/apache/uima/tools/cfe/config/ConfigFactory.java
URL: http://svn.apache.org/viewvc/incubator/uima/sandbox/trunk/ConfigurableFeatureExtractor/src/main/java/org/apache/uima/tools/cfe/config/ConfigFactory.java?rev=786255&view=auto
==============================================================================
--- incubator/uima/sandbox/trunk/ConfigurableFeatureExtractor/src/main/java/org/apache/uima/tools/cfe/config/ConfigFactory.java (added)
+++ incubator/uima/sandbox/trunk/ConfigurableFeatureExtractor/src/main/java/org/apache/uima/tools/cfe/config/ConfigFactory.java Thu Jun 18 20:39:50 2009
@@ -0,0 +1,146 @@
+/**
+ * <copyright>
+ * </copyright>
+ *
+ * $Id$
+ */
+package org.apache.uima.tools.cfe.config;
+
+import org.eclipse.emf.ecore.EFactory;
+
+/**
+ * <!-- begin-user-doc -->
+ * The <b>Factory</b> for the model.
+ * It provides a create method for each non-abstract class of the model.
+ * <!-- end-user-doc -->
+ * @see org.apache.uima.tools.cfe.config.ConfigPackage
+ * @generated
+ */
+public interface ConfigFactory extends EFactory
+{
+  /**
+     * The singleton instance of the factory.
+     * <!-- begin-user-doc -->
+   * <!-- end-user-doc -->
+     * @generated
+     */
+  ConfigFactory eINSTANCE = org.apache.uima.tools.cfe.config.impl.ConfigFactoryImpl.init();
+
+  /**
+     * Returns a new object of class '<em>Bitset Feature Values XML</em>'.
+     * <!-- begin-user-doc -->
+   * <!-- end-user-doc -->
+     * @return a new object of class '<em>Bitset Feature Values XML</em>'.
+     * @generated
+     */
+  BitsetFeatureValuesXML createBitsetFeatureValuesXML();
+
+  /**
+     * Returns a new object of class '<em>CFE Descriptor XML</em>'.
+     * <!-- begin-user-doc -->
+   * <!-- end-user-doc -->
+     * @return a new object of class '<em>CFE Descriptor XML</em>'.
+     * @generated
+     */
+  CFEDescriptorXML createCFEDescriptorXML();
+
+  /**
+     * Returns a new object of class '<em>Document Root</em>'.
+     * <!-- begin-user-doc -->
+   * <!-- end-user-doc -->
+     * @return a new object of class '<em>Document Root</em>'.
+     * @generated
+     */
+  DocumentRoot createDocumentRoot();
+
+  /**
+     * Returns a new object of class '<em>Enum Feature Values XML</em>'.
+     * <!-- begin-user-doc -->
+   * <!-- end-user-doc -->
+     * @return a new object of class '<em>Enum Feature Values XML</em>'.
+     * @generated
+     */
+  EnumFeatureValuesXML createEnumFeatureValuesXML();
+
+  /**
+     * Returns a new object of class '<em>Feature Object Matcher XML</em>'.
+     * <!-- begin-user-doc -->
+   * <!-- end-user-doc -->
+     * @return a new object of class '<em>Feature Object Matcher XML</em>'.
+     * @generated
+     */
+  FeatureObjectMatcherXML createFeatureObjectMatcherXML();
+
+  /**
+     * Returns a new object of class '<em>Group Feature Matcher XML</em>'.
+     * <!-- begin-user-doc -->
+   * <!-- end-user-doc -->
+     * @return a new object of class '<em>Group Feature Matcher XML</em>'.
+     * @generated
+     */
+  GroupFeatureMatcherXML createGroupFeatureMatcherXML();
+
+  /**
+     * Returns a new object of class '<em>Object Path Feature Values XML</em>'.
+     * <!-- begin-user-doc -->
+   * <!-- end-user-doc -->
+     * @return a new object of class '<em>Object Path Feature Values XML</em>'.
+     * @generated
+     */
+  ObjectPathFeatureValuesXML createObjectPathFeatureValuesXML();
+
+  /**
+     * Returns a new object of class '<em>Partial Object Matcher XML</em>'.
+     * <!-- begin-user-doc -->
+   * <!-- end-user-doc -->
+     * @return a new object of class '<em>Partial Object Matcher XML</em>'.
+     * @generated
+     */
+  PartialObjectMatcherXML createPartialObjectMatcherXML();
+
+  /**
+     * Returns a new object of class '<em>Pattern Feature Values XML</em>'.
+     * <!-- begin-user-doc -->
+   * <!-- end-user-doc -->
+     * @return a new object of class '<em>Pattern Feature Values XML</em>'.
+     * @generated
+     */
+  PatternFeatureValuesXML createPatternFeatureValuesXML();
+
+  /**
+     * Returns a new object of class '<em>Range Feature Values XML</em>'.
+     * <!-- begin-user-doc -->
+   * <!-- end-user-doc -->
+     * @return a new object of class '<em>Range Feature Values XML</em>'.
+     * @generated
+     */
+  RangeFeatureValuesXML createRangeFeatureValuesXML();
+
+  /**
+     * Returns a new object of class '<em>Single Feature Matcher XML</em>'.
+     * <!-- begin-user-doc -->
+   * <!-- end-user-doc -->
+     * @return a new object of class '<em>Single Feature Matcher XML</em>'.
+     * @generated
+     */
+  SingleFeatureMatcherXML createSingleFeatureMatcherXML();
+
+  /**
+     * Returns a new object of class '<em>Target Annotation XML</em>'.
+     * <!-- begin-user-doc -->
+   * <!-- end-user-doc -->
+     * @return a new object of class '<em>Target Annotation XML</em>'.
+     * @generated
+     */
+  TargetAnnotationXML createTargetAnnotationXML();
+
+  /**
+     * Returns the package supported by this factory.
+     * <!-- begin-user-doc -->
+   * <!-- end-user-doc -->
+     * @return the package supported by this factory.
+     * @generated
+     */
+  ConfigPackage getConfigPackage();
+
+} //ConfigFactory