You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@uima.apache.org by mb...@apache.org on 2007/03/22 11:24:57 UTC
svn commit: r521189 -
/incubator/uima/uimaj/trunk/uimaj-core/src/main/java/org/apache/uima/pear/tools/PackageBrowser.java
Author: mbaessler
Date: Thu Mar 22 03:24:49 2007
New Revision: 521189
URL: http://svn.apache.org/viewvc?view=rev&rev=521189
Log:
UIMA-354
add an API at the PackageBrowser to return the component environment variable settings.
JIRA ticket https://issues.apache.org/jira/browse/UIMA-354
Modified:
incubator/uima/uimaj/trunk/uimaj-core/src/main/java/org/apache/uima/pear/tools/PackageBrowser.java
Modified: incubator/uima/uimaj/trunk/uimaj-core/src/main/java/org/apache/uima/pear/tools/PackageBrowser.java
URL: http://svn.apache.org/viewvc/incubator/uima/uimaj/trunk/uimaj-core/src/main/java/org/apache/uima/pear/tools/PackageBrowser.java?view=diff&rev=521189&r1=521188&r2=521189
==============================================================================
--- incubator/uima/uimaj/trunk/uimaj-core/src/main/java/org/apache/uima/pear/tools/PackageBrowser.java (original)
+++ incubator/uima/uimaj/trunk/uimaj-core/src/main/java/org/apache/uima/pear/tools/PackageBrowser.java Thu Mar 22 03:24:49 2007
@@ -405,4 +405,27 @@
return (String) pearEnvProps.get(RelativePathResolver.UIMA_DATAPATH_PROP);
}
+
+ /**
+ * Returns the environment variable settings for the component. The variable settings does not contain
+ * the <code>classpath</code> and <code>uima.datapath</code> settings for the component.
+ *
+ * @return returns the environment variable settings for the component
+ *
+ * @throws IOException
+ * If any I/O exception occurred while reading the component meta data.
+ */
+ public Properties getComponentEnvVars() throws IOException {
+ //get all environment variables that are specified for the current pear file
+ Properties pearEnvProps = InstallationController.buildTableOfEnvVars(this
+ .getInstallationDescriptor());
+
+ //removes the UIMA datapath setting if available since it is already returned with the
+ //getComponentDataPath() method.
+ pearEnvProps.remove(RelativePathResolver.UIMA_DATAPATH_PROP);
+
+ //return the environment variables specified for the component
+ return pearEnvProps;
+
+ }
}