Class DATACasUtils

java.lang.Object
org.apache.uima.collection.impl.cpm.vinci.DATACasUtils

public class DATACasUtils extends Object
The Class DATACasUtils.
  • Constructor Details

    • DATACasUtils

      public DATACasUtils()
  • Method Details

    • getXCASasString

      public static String getXCASasString(CasData aCasData, String[] keysToFilter) throws Exception
      Gets the XCA sas string.
      Parameters:
      aCasData - the a cas data
      keysToFilter - the keys to filter
      Returns:
      the XCA sas string
      Throws:
      Exception - the exception
    • addFeatureStructure

      public static void addFeatureStructure(CasData dataCas, String featureType, String featureName, String featureValue)
      Adds the feature structure.
      Parameters:
      dataCas - the data cas
      featureType - the feature type
      featureName - the feature name
      featureValue - the feature value
    • isCasEmpty

      public static boolean isCasEmpty(CasData aDataCas)
      Checks if is cas empty.
      Parameters:
      aDataCas - the a data cas
      Returns:
      true if the data cas is empty
    • addFeature

      public static void addFeature(CasData dataCas, String featureType, String featureName, String featureValue)
      Adds the feature.
      Parameters:
      dataCas - the data cas
      featureType - the feature type
      featureName - the feature name
      featureValue - the feature value
    • getByteCount

      public static long getByteCount(CasData aDataCas) throws Exception
      Gets the byte count.
      Parameters:
      aDataCas - the a data cas
      Returns:
      the byte count
      Throws:
      Exception - -
    • shouldAnalyzeCAS

      public static boolean shouldAnalyzeCAS(CasData aCAS, LinkedList aFilterList)
      Should analyze CAS.
      Parameters:
      aCAS - the a CAS
      aFilterList - the a filter list
      Returns:
      true if this cas should be analyzed
    • dropIt

      public static boolean dropIt(String aKey, String[] dropKeyList)
      Drop it.
      Parameters:
      aKey - the a key
      dropKeyList - the drop key list
      Returns:
      true if this key is in the dropKeyList
    • isValidType

      public static boolean isValidType(String aKey, String[] typeList)
      Checks if is valid type.
      Parameters:
      aKey - the a key
      typeList - the type list
      Returns:
      true if tbd
    • hasFeature

      public static boolean hasFeature(CasData aCAS, String featureName)
      Checks for feature.
      Parameters:
      aCAS - the a CAS
      featureName - the feature name
      Returns:
      true if
    • hasFeatureStructure

      public static boolean hasFeatureStructure(CasData aCAS, String aName)
      Checks for feature structure.
      Parameters:
      aCAS - the a CAS
      aName - the a name
      Returns:
      true if tbd
    • dumpFeatures

      public static void dumpFeatures(CasData aCAS)
      Dump features.
      Parameters:
      aCAS - the a CAS
    • getFeatureValueByType

      public static String getFeatureValueByType(CasData aCAS, String featureName)
      Gets the feature value by type.
      Parameters:
      aCAS - the a CAS
      featureName - the feature name
      Returns:
      true if tbd
    • getFeatureStructureValues

      public static String[] getFeatureStructureValues(CasData aCAS, String featureStructureName, String featureName)
      Gets the feature structure values.
      Parameters:
      aCAS - the a CAS
      featureStructureName - the feature structure name
      featureName - the feature name
      Returns:
      tbd
    • getFeatureValueByType

      public static String getFeatureValueByType(CasData aCAS, String aFeatureStructure, String featureName)
      Gets the feature value by type.
      Parameters:
      aCAS - the a CAS
      aFeatureStructure - the a feature structure
      featureName - the feature name
      Returns:
      tbd
    • remapFeatureTypes

      public static void remapFeatureTypes(CasData aDataCas, FeatureMap aFeatureMap)
      Remap feature types.
      Parameters:
      aDataCas - the a data cas
      aFeatureMap - the a feature map
    • getCasDataFeatures

      public static NameValuePair[] getCasDataFeatures(CasData aCasData, String aFeatureStructureName)
      Gets the cas data features.
      Parameters:
      aCasData - the a cas data
      aFeatureStructureName - the a feature structure name
      Returns:
      tbd