Tabnine Logo
org.apache.uima.resource.metadata
Code IndexAdd Tabnine to your IDE (free)

How to use org.apache.uima.resource.metadata

Best Java code snippets using org.apache.uima.resource.metadata (Showing top 20 results out of 324)

origin: org.apache.uima/uimaj-cpe

@Override
public void setConfigParameterValue(String aParamName, Object aValue) {
 configParams.setParameterValue(aParamName, aValue);
}
origin: apache/uima-uimaj

private static AllowedValue[] getAllowedValues(TypeDescription type) {
 AllowedValue[] r = type.getAllowedValues();
 if (r == null) {
  return new AllowedValue[0];
 }
 return r;
}
origin: apache/uima-uimaj

/**
 * @see org.apache.uima.analysis_engine.metadata.AnalysisEngineMetaData#getFsIndexes()
 */
public FsIndexDescription[] getFsIndexes() {
 return mFsIndexCollection == null ? null : mFsIndexCollection.getFsIndexes();
}
origin: fr.univ-nantes.julestar/uima-tokens-regex

private void inferFeatureMap(TypeDescription type) {
  // 1 - Recursively add features of the super type
  TypeDescription superType = typeSystemDescription.getType(type.getSupertypeName());
  if(superType != null)
    inferFeatureMap(superType);
  
  // 2 - Add features of this type
  for(FeatureDescription feature:type.getFeatures()) {
    String featureFQN = type.getName() + ":" + feature.getName();
    featureMap.put(feature.getName(), featureFQN);
    featureMap.put(featureFQN, featureFQN);
  }
}
origin: de.tudarmstadt.ukp.clarin.webanno/webanno-api-annotation

@Override
public void generateFeature(TypeSystemDescription aTSD, TypeDescription aTD,
    AnnotationFeature aFeature)
{
  // Link type
  TypeDescription linkTD = aTSD.addType(aFeature.getLinkTypeName(), "",
      CAS.TYPE_NAME_TOP);
  linkTD.addFeature(aFeature.getLinkTypeRoleFeatureName(), "", CAS.TYPE_NAME_STRING);
  linkTD.addFeature(aFeature.getLinkTypeTargetFeatureName(), "", aFeature.getType());
  // Link feature
  aTD.addFeature(aFeature.getName(), "", CAS.TYPE_NAME_FS_ARRAY, linkTD.getName(),
      false);
}

origin: org.apache.uima/uimaj-as-core

private void addConfigIntParameter(String aParamName, int aParamValue) {
 ConfigurationParameter cp = new ConfigurationParameter_impl();
 cp.setMandatory(false);
 cp.setMultiValued(false);
 cp.setName(aParamName);
 cp.setType("Integer");
 getAnalysisEngineMetadata().getConfigurationParameterDeclarations().addConfigurationParameter(
     cp);
 getAnalysisEngineMetadata().getConfigurationParameterSettings().setParameterValue(aParamName,
     aParamValue);
}
origin: org.apache.uima/uimaj-ep-configurator

/**
 * Checks if is imported type.
 *
 * @param td the td
 * @return true, if is imported type
 */
protected boolean isImportedType(TypeDescription td) {
 return null != editor.getImportedTypeSystemDesription().getType(td.getName());
}
origin: org.apache.uima/uimaj-ep-configurator

/**
 * Checks if is imported allowed value.
 *
 * @param td the td
 * @param av the av
 * @return true, if is imported allowed value
 */
protected boolean isImportedAllowedValue(TypeDescription td, AllowedValue av) {
 TypeDescription importedTd = editor.getImportedTypeSystemDesription().getType(td.getName());
 if (null == importedTd)
  return false;
 return null != getAllowedValue(av.getString(), importedTd);
}
origin: edu.utah.bmi.nlp/nlp-core

public TreeSet<String> getImportedTypeNames() {
  TreeSet<String> typeNames = new TreeSet<>();
  for (TypeDescription typeDescription : typeSystemDescription.getTypes()) {
    typeNames.add(typeDescription.getName());
  }
  return typeNames;
}
origin: apache/uima-uimaj

/**
 * @see org.apache.uima.resource.ConfigurableResource#getConfigParameterValue(java.lang.String)
 */
public Object getConfigParameterValue(String aParamName) {
 return getMetaData().getConfigurationParameterSettings().getParameterValue(aParamName);
}
origin: org.apache.uima/uimaj-ep-configurator

/**
 * Fixup cpd.
 */
private void fixupCpd() {
 if (null == cpd.getConfigurationParameters())
  cpd.setConfigurationParameters(AbstractSection.configurationParameterArray0);
 if (null == cpd.getCommonParameters())
  cpd.setCommonParameters(AbstractSection.configurationParameterArray0);
 if (null == cpd.getConfigurationGroups())
  cpd.setConfigurationGroups(AbstractSection.configurationGroupArray0);
 ConfigurationGroup[] cgs = cpd.getConfigurationGroups();
 for (int i = 0; i < cgs.length; i++) {
  if (null == cgs[i].getConfigurationParameters())
   cgs[i].setConfigurationParameters(AbstractSection.configurationParameterArray0);
 }
}
origin: apache/uima-uimaj

public void resolveImports(ResourceManager aResourceManager) throws InvalidXMLException {
 if (getTypeSystem() != null) {
  getTypeSystem().resolveImports(aResourceManager);
 }
 if (getTypePriorities() != null) {
  getTypePriorities().resolveImports(aResourceManager);
 }
 if (getFsIndexCollection() != null) {
  getFsIndexCollection().resolveImports(aResourceManager);
 }
}
origin: org.apache.uima/uimaj-cpe

@Override
public Object getConfigParameterValue(String aGroupName, String aParamName) {
 return configParams.getParameterValue(aGroupName, aParamName);
}
origin: apache/uima-uimaj

/**
 * Returns true. By contract, CAS Consumers must be read only.
 * 
 * @see org.apache.uima.collection.base_cpm.CasProcessor#isReadOnly()
 */
public final boolean isReadOnly() {
 OperationalProperties opProps = getProcessingResourceMetaData().getOperationalProperties();
 return opProps == null ? true : !opProps.getModifiesCas();
}
origin: de.tudarmstadt.ukp.inception.app/inception-ui-kb

@Override
public void generateFeature(TypeSystemDescription aTSD, TypeDescription aTD,
  AnnotationFeature aFeature)
{
  // Link type
  TypeDescription linkTD = aTSD.addType(aFeature.getLinkTypeName(), "",
    CAS.TYPE_NAME_TOP);
  linkTD.addFeature(aFeature.getLinkTypeRoleFeatureName(), "", CAS.TYPE_NAME_STRING);
  linkTD.addFeature(aFeature.getLinkTypeTargetFeatureName(), "", aFeature.getType());
  
  // Link feature
  aTD.addFeature(aFeature.getName(), "", CAS.TYPE_NAME_FS_ARRAY, linkTD.getName(),
    false);
}
origin: org.apache.uima/uimaj-ep-configurator

/**
 * Gets the local type definition.
 *
 * @param td the td
 * @return the local type definition
 */
protected TypeDescription getLocalTypeDefinition(TypeDescription td) {
 TypeSystemDescription tsdLocal = getTypeSystemDescription();
 if (null == tsdLocal)
  return null;
 return tsdLocal.getType(td.getName());
}
origin: apache/uima-uimaj

/**
 * @see org.apache.uima.resource.ConfigurableResource#getConfigParameterValue(java.lang.String,
 *      java.lang.String)
 */
public Object getConfigParameterValue(String aGroupName, String aParamName) {
 return getMetaData().getConfigurationParameterSettings().getParameterValue(aGroupName,
     aParamName);
}
origin: org.apache.uima/uimaj-cpe

@Override
public void setConfigParameterValue(String aGroupName, String aParamName, Object aValue) {
 configParams.setParameterValue(aGroupName, aParamName, aValue);
}
origin: org.apache.uima/uimaj-cpe

@Override
public Object getConfigParameterValue(String aParamName) {
 return configParams.getParameterValue(aParamName);
}
origin: inception-project/inception

@Override
public void generateFeature(TypeSystemDescription aTSD, TypeDescription aTD,
  AnnotationFeature aFeature)
{
  // Link type
  TypeDescription linkTD = aTSD.addType(aFeature.getLinkTypeName(), "",
    CAS.TYPE_NAME_TOP);
  linkTD.addFeature(aFeature.getLinkTypeRoleFeatureName(), "", CAS.TYPE_NAME_STRING);
  linkTD.addFeature(aFeature.getLinkTypeTargetFeatureName(), "", aFeature.getType());
  
  // Link feature
  aTD.addFeature(aFeature.getName(), "", CAS.TYPE_NAME_FS_ARRAY, linkTD.getName(),
    false);
}
org.apache.uima.resource.metadata

Most used classes

  • TypeSystemDescription
  • ResourceMetaData
  • TypeDescription
  • ConfigurationParameterSettings
  • ConfigurationParameter
  • Import,
  • ProcessingResourceMetaData,
  • OperationalProperties,
  • FeatureDescription,
  • Import_impl,
  • TypeSystemDescription_impl,
  • Capability,
  • NameValuePair,
  • ConfigurationParameter_impl,
  • ExternalResourceBinding,
  • FsIndexCollection,
  • FsIndexDescription,
  • TypePriorities,
  • MetaDataObject_impl
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now