You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@uima.apache.org by jo...@apache.org on 2011/08/01 17:28:50 UTC
svn commit: r1152828 [1/6] - in
/uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils: ./
META-INF/ bin/ icons/ 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/...
Author: joern
Date: Mon Aug 1 15:28:46 2011
New Revision: 1152828
URL: http://svn.apache.org/viewvc?rev=1152828&view=rev
Log:
UIMA-2172 Initial commit of the TextMarker contribution.
Added:
uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/.classpath (with props)
uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/.project (with props)
uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/META-INF/
uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/META-INF/MANIFEST.MF (with props)
uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/bin/
uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/build.properties (with props)
uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/icons/
uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/icons/text_signature.png (with props)
uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/icons/tm_obj.png (with props)
uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/plugin.xml (with props)
uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/src/
uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/src/main/
uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/src/main/java/
uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/src/main/java/org/
uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/src/main/java/org/apache/
uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/src/main/java/org/apache/uima/
uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/src/main/java/org/apache/uima/tm/
uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/src/main/java/org/apache/uima/tm/textmarker/
uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/src/main/java/org/apache/uima/tm/textmarker/ui/
uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/src/main/java/org/apache/uima/tm/textmarker/ui/apply/
uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/src/main/java/org/apache/uima/tm/textmarker/ui/apply/AbstarctApplyScriptHandler.java (with props)
uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/src/main/java/org/apache/uima/tm/textmarker/ui/apply/AbstractApplyScriptHandlerJob.java (with props)
uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/src/main/java/org/apache/uima/tm/textmarker/ui/apply/ApplyScriptKeepBasicsHandler.java (with props)
uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/src/main/java/org/apache/uima/tm/textmarker/ui/apply/ApplyScriptKeepBasicsJob.java (with props)
uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/src/main/java/org/apache/uima/tm/textmarker/ui/apply/ApplyScriptNoXMIHandler.java (with props)
uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/src/main/java/org/apache/uima/tm/textmarker/ui/apply/ApplyScriptNoXMIJob.java (with props)
uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/src/main/java/org/apache/uima/tm/textmarker/ui/apply/ApplyScriptRemoveBasicsHandler.java (with props)
uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/src/main/java/org/apache/uima/tm/textmarker/ui/apply/ApplyScriptRemoveBasicsJob.java (with props)
uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/src/main/java/org/apache/uima/tm/textmarker/ui/convert/
uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/src/main/java/org/apache/uima/tm/textmarker/ui/convert/ConvertSyntax.g (with props)
uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/src/main/java/org/apache/uima/tm/textmarker/ui/convert/ConvertSyntax.tokens (with props)
uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/src/main/java/org/apache/uima/tm/textmarker/ui/convert/ConvertSyntaxAction.java (with props)
uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/src/main/java/org/apache/uima/tm/textmarker/ui/convert/ConvertSyntaxLexer.java (with props)
uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/src/main/java/org/apache/uima/tm/textmarker/ui/convert/ConvertSyntaxParser.java (with props)
uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/src/main/java/org/apache/uima/tm/textmarker/ui/twl/
uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/src/main/java/org/apache/uima/tm/textmarker/ui/twl/MultiTWLConverterHandler.java (with props)
uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/src/main/java/org/apache/uima/tm/textmarker/ui/twl/TWLConverterHandler.java (with props)
uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/src/main/java/org/apache/uima/tm/textmarker/ui/utils/
uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/src/main/java/org/apache/uima/tm/textmarker/ui/utils/TextMarkerUtilsPlugin.java (with props)
Modified:
uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/ (props changed)
Propchange: uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/
------------------------------------------------------------------------------
--- svn:ignore (added)
+++ svn:ignore Mon Aug 1 15:28:46 2011
@@ -0,0 +1 @@
+.settings
Added: uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/.classpath
URL: http://svn.apache.org/viewvc/uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/.classpath?rev=1152828&view=auto
==============================================================================
--- uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/.classpath (added)
+++ uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/.classpath Mon Aug 1 15:28:46 2011
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<classpath>
+ <classpathentry kind="src" path="src/main/java"/>
+ <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.6"/>
+ <classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
+ <classpathentry kind="output" path="bin"/>
+</classpath>
Propchange: uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/.classpath
------------------------------------------------------------------------------
svn:executable = *
Propchange: uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/.classpath
------------------------------------------------------------------------------
svn:mime-type = text/plain
Added: uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/.project
URL: http://svn.apache.org/viewvc/uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/.project?rev=1152828&view=auto
==============================================================================
--- uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/.project (added)
+++ uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/.project Mon Aug 1 15:28:46 2011
@@ -0,0 +1,28 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<projectDescription>
+ <name>org.apache.uima.tm.textmarker.ui.utils</name>
+ <comment></comment>
+ <projects>
+ </projects>
+ <buildSpec>
+ <buildCommand>
+ <name>org.eclipse.jdt.core.javabuilder</name>
+ <arguments>
+ </arguments>
+ </buildCommand>
+ <buildCommand>
+ <name>org.eclipse.pde.ManifestBuilder</name>
+ <arguments>
+ </arguments>
+ </buildCommand>
+ <buildCommand>
+ <name>org.eclipse.pde.SchemaBuilder</name>
+ <arguments>
+ </arguments>
+ </buildCommand>
+ </buildSpec>
+ <natures>
+ <nature>org.eclipse.pde.PluginNature</nature>
+ <nature>org.eclipse.jdt.core.javanature</nature>
+ </natures>
+</projectDescription>
Propchange: uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/.project
------------------------------------------------------------------------------
svn:executable = *
Propchange: uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/.project
------------------------------------------------------------------------------
svn:mime-type = text/plain
Added: uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/META-INF/MANIFEST.MF
URL: http://svn.apache.org/viewvc/uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/META-INF/MANIFEST.MF?rev=1152828&view=auto
==============================================================================
--- uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/META-INF/MANIFEST.MF (added)
+++ uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/META-INF/MANIFEST.MF Mon Aug 1 15:28:46 2011
@@ -0,0 +1,24 @@
+Manifest-Version: 1.0
+Bundle-ManifestVersion: 2
+Bundle-Name: TextMarker Utils Plugin
+Bundle-SymbolicName: org.apache.uima.tm.textmarker.ui.utils;singleton:=true
+Bundle-Version: 1.0.0.qualifier
+Bundle-Activator: org.apache.uima.tm.textmarker.ui.utils.TextMarkerUtilsPlugin
+Require-Bundle: org.eclipse.ui,
+ org.eclipse.core.runtime,
+ org.apache.uima.tm.textmarker.engine,
+ org.eclipse.core.expressions,
+ org.eclipse.dltk.core;bundle-version="[1.0.0,2.0.0)",
+ org.eclipse.ui,
+ org.eclipse.core.runtime,
+ org.eclipse.core.resources,
+ org.apache.uima.tm.dltk.core,
+ org.apache.uima.tm.dltk.antlr,
+ org.eclipse.ui.editors,
+ org.eclipse.text,
+ org.eclipse.jface.text,
+ org.eclipse.ui.ide,
+ org.apache.uima.runtime;bundle-version="2.3.0"
+Bundle-ActivationPolicy: lazy
+Bundle-RequiredExecutionEnvironment: JavaSE-1.6
+Bundle-Vendor: University of Würzburg
Propchange: uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/META-INF/MANIFEST.MF
------------------------------------------------------------------------------
svn:executable = *
Propchange: uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/META-INF/MANIFEST.MF
------------------------------------------------------------------------------
svn:mime-type = text/plain
Added: uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/build.properties
URL: http://svn.apache.org/viewvc/uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/build.properties?rev=1152828&view=auto
==============================================================================
--- uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/build.properties (added)
+++ uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/build.properties Mon Aug 1 15:28:46 2011
@@ -0,0 +1,5 @@
+source.. = src/
+output.. = bin/
+bin.includes = META-INF/,\
+ .,\
+ plugin.xml
Propchange: uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/build.properties
------------------------------------------------------------------------------
svn:executable = *
Propchange: uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/build.properties
------------------------------------------------------------------------------
svn:mime-type = text/plain
Added: uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/icons/text_signature.png
URL: http://svn.apache.org/viewvc/uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/icons/text_signature.png?rev=1152828&view=auto
==============================================================================
Binary file - no diff available.
Propchange: uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/icons/text_signature.png
------------------------------------------------------------------------------
svn:executable = *
Propchange: uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/icons/text_signature.png
------------------------------------------------------------------------------
svn:mime-type = application/octet-stream
Added: uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/icons/tm_obj.png
URL: http://svn.apache.org/viewvc/uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/icons/tm_obj.png?rev=1152828&view=auto
==============================================================================
Binary file - no diff available.
Propchange: uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/icons/tm_obj.png
------------------------------------------------------------------------------
svn:executable = *
Propchange: uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/icons/tm_obj.png
------------------------------------------------------------------------------
svn:mime-type = application/octet-stream
Added: uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/plugin.xml
URL: http://svn.apache.org/viewvc/uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/plugin.xml?rev=1152828&view=auto
==============================================================================
--- uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/plugin.xml (added)
+++ uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/plugin.xml Mon Aug 1 15:28:46 2011
@@ -0,0 +1,271 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<?eclipse version="3.2"?>
+<plugin>
+ <extension
+ point="org.eclipse.ui.commands">
+ <command
+ defaultHandler="org.apache.uima.tm.textmarker.ui.twl.TWLConverterHandler"
+ description="TWLConvertCommand"
+ id="org.apache.uima.tm.textmarker.ui.twl.command"
+ name="Convert to TWL">
+ <defaultHandler
+ class="org.apache.uima.tm.textmarker.ui.twl.TWLConverterHandler">
+ </defaultHandler>
+ </command>
+ <command
+ defaultHandler="org.apache.uima.tm.textmarker.ui.twl.MultiTWLConverterHandler"
+ description="MultiTWLConvertCommand"
+ id="org.apache.uima.tm.textmarker.ui.mtwl.command"
+ name="Convert to Multi TWL">
+ <defaultHandler
+ class="org.apache.uima.tm.textmarker.ui.twl.MultiTWLConverterHandler">
+ </defaultHandler>
+ </command>
+ <command
+ defaultHandler="org.apache.uima.tm.textmarker.ui.apply.ApplyScriptRemoveBasicsHandler"
+ id="org.apache.uima.tm.textmarker.ui.apply.script"
+ name="ApplyScriptCommand">
+ </command>
+ <command
+ defaultHandler="org.apache.uima.tm.textmarker.ui.apply.ApplyScriptKeepBasicsHandler"
+ id="org.apache.uima.tm.textmarker.ui.apply.script.basics"
+ name="ApplyScriptBasicsCommand">
+ </command>
+ <command
+ defaultHandler="org.apache.uima.tm.textmarker.ui.apply.ApplyScriptNoXMIHandler"
+ id="org.apache.uima.tm.textmarker.ui.apply.script.noxmi"
+ name="ApplyScriptNoXMICommand">
+ </command>
+ </extension>
+ <extension
+ point="org.eclipse.ui.menus">
+ <menuContribution
+ locationURI="popup:org.eclipse.ui.popup.any">
+ <menu
+ icon="icons/tm_obj.png"
+ id="org.apache.uima.tm.textmarker.ui.popup.submenu"
+ label="TextMarker">
+ </menu>
+ </menuContribution>
+ <menuContribution
+ locationURI="popup:org.apache.uima.tm.textmarker.ui.popup.submenu">
+ <command
+ commandId="org.apache.uima.tm.textmarker.ui.apply.script.basics"
+ disabledIcon="icons/tm_obj.png"
+ hoverIcon="icons/tm_obj.png"
+ icon="icons/tm_obj.png"
+ id="org.apache.uima.tm.textmarker.ui.apply.script.basics.popup"
+ label="Quick TextMarker"
+ style="push"
+ tooltip="Apply current TextMarker script on folder and keep basics">
+ <visibleWhen
+ checkEnabled="true">
+ </visibleWhen>
+ </command>
+ </menuContribution>
+ <menuContribution
+ locationURI="popup:org.apache.uima.tm.textmarker.ui.popup.submenu">
+ <command
+ commandId="org.apache.uima.tm.textmarker.ui.apply.script"
+ disabledIcon="icons/tm_obj.png"
+ hoverIcon="icons/tm_obj.png"
+ icon="icons/tm_obj.png"
+ id="org.apache.uima.tm.textmarker.ui.apply.script.popup"
+ label="Quick TextMarker (remove basics)"
+ style="push"
+ tooltip="Apply current TextMarker script on folder">
+ <visibleWhen
+ checkEnabled="true">
+ </visibleWhen>
+ </command>
+ </menuContribution>
+ <menuContribution
+ locationURI="popup:org.apache.uima.tm.textmarker.ui.popup.submenu">
+ <command
+ commandId="org.apache.uima.tm.textmarker.ui.apply.script.noxmi"
+ disabledIcon="icons/tm_obj.png"
+ hoverIcon="icons/tm_obj.png"
+ icon="icons/tm_obj.png"
+ id="org.apache.uima.tm.textmarker.ui.apply.script.noxmi.popup"
+ label="Quick TextMarker (no xmi)"
+ style="push"
+ tooltip="Apply current TextMarker script on folder">
+ <visibleWhen
+ checkEnabled="true">
+ </visibleWhen>
+ </command>
+ </menuContribution>
+ <menuContribution
+ locationURI="popup:org.apache.uima.tm.textmarker.ui.popup.submenu">
+ <command
+ commandId="org.apache.uima.tm.textmarker.ui.twl.command"
+ disabledIcon="icons/tm_obj.png"
+ hoverIcon="icons/tm_obj.png"
+ icon="icons/tm_obj.png"
+ id="org.apache.uima.tm.textmarker.ui.twl.popup"
+ label="Convert to TWL"
+ style="push"
+ tooltip="Convert the word list to a tree">
+ <visibleWhen
+ checkEnabled="true">
+ <reference
+ definitionId="org.apache.uima.tm.textmarker.ui.twl.definition">
+ </reference>
+ </visibleWhen>
+ </command>
+ </menuContribution>
+ <menuContribution
+ locationURI="popup:org.apache.uima.tm.textmarker.ui.popup.submenu">
+ <command
+ commandId="org.apache.uima.tm.textmarker.ui.mtwl.command"
+ disabledIcon="icons/tm_obj.png"
+ hoverIcon="icons/tm_obj.png"
+ icon="icons/tm_obj.png"
+ id="org.apache.uima.tm.textmarker.ui.mtwl.popup"
+ label="Convert to Multi TWL"
+ style="push"
+ tooltip="Convert several word lists to a tree">
+ <visibleWhen
+ checkEnabled="true">
+ <reference
+ definitionId="org.apache.uima.tm.textmarker.ui.mtwl.definition">
+ </reference>
+ </visibleWhen>
+ </command>
+ </menuContribution>
+ </extension>
+ <extension
+ point="org.eclipse.core.expressions.definitions">
+ <definition
+ id="org.apache.uima.tm.textmarker.ui.twl.definition">
+ <with
+ variable="selection">
+ <iterate
+ ifEmpty="false"
+ operator="and">
+ <test
+ property="org.eclipse.core.resources.extension"
+ value="txt">
+ </test>
+ </iterate>
+ </with>
+ </definition>
+ <definition
+ id="org.apache.uima.tm.textmarker.ui.mtwl.definition">
+ <with
+ variable="selection">
+ <iterate
+ ifEmpty="true">
+ <or>
+ <test
+ property="org.eclipse.core.resources.extension"
+ value="txt">
+ </test>
+ </or>
+ </iterate>
+ </with>
+ </definition>
+ <definition
+ id="org.apache.uima.tm.textmarker.ui.apply.script.definition">
+ <with
+ variable="selection">
+ <and>
+ <!--
+ <iterate
+ ifEmpty="false">
+ <or>
+ <test
+ property="org.eclipse.core.resources.extension"
+ value="txt">
+ </test>
+ <test
+ property="org.eclipse.core.resources.extension"
+ value="html">
+ </test>
+ <test
+ property="org.eclipse.core.resources.extension"
+ value="htm">
+ </test>
+ <test
+ property="org.eclipse.core.resources.extension"
+ value="xmi">
+ </test>
+ <test
+ property="org.apache.uima.tm.textmarker.ui.utils.test2">
+ </test>
+ </or>
+ </iterate>
+ -->
+ <with
+ variable="activeEditorId">
+ <equals
+ value="org.apache.uima.tm.dltk.ui.editor.TextMarkerEditor">
+ </equals>
+ </with>
+ </and>
+ </with>
+ </definition>
+ </extension>
+ <extension
+ point="org.eclipse.ui.bindings">
+ <key
+ commandId="org.apache.uima.tm.textmarker.ui.apply.script"
+ contextId="org.eclipse.ui.contexts.window"
+ schemeId="org.eclipse.ui.defaultAcceleratorConfiguration"
+ sequence="M1+M3+T">
+ </key>
+ <key
+ commandId="org.apache.uima.tm.textmarker.ui.apply.script.basics"
+ contextId="org.eclipse.ui.contexts.window"
+ schemeId="org.eclipse.ui.defaultAcceleratorConfiguration"
+ sequence="M1+T">
+ </key>
+ <key
+ commandId="org.apache.uima.tm.textmarker.ui.apply.script.noxmi"
+ contextId="org.eclipse.ui.contexts.window"
+ schemeId="org.eclipse.ui.defaultAcceleratorConfiguration"
+ sequence="M1+M2+M3+T">
+ </key>
+ <key
+ commandId="org.apache.uima.tm.textmarker.ui.twl.command"
+ contextId="org.eclipse.ui.contexts.window"
+ schemeId="org.eclipse.ui.defaultAcceleratorConfiguration"
+ sequence="M1+L">
+ </key>
+ <key
+ commandId="org.apache.uima.tm.textmarker.ui.mtwl.command"
+ contextId="org.eclipse.ui.contexts.window"
+ schemeId="org.eclipse.ui.defaultAcceleratorConfiguration"
+ sequence="M1+M2+L">
+ </key>
+ </extension>
+ <!--
+ <extension
+ point="org.eclipse.ui.popupMenus">
+ <viewerContribution
+ id="org.apache.uima.tm.textmarker.ui.utils.convert.syntax.statement"
+ targetID="#TextMarkerEditorContext">
+ <action
+ class="org.apache.uima.tm.textmarker.ui.convert.ConvertSyntaxAction"
+ icon="icons/tm_obj.png"
+ id="org.apache.uima.tm.textmarker.ui.utils.convert.action"
+ label="Convert syntax"
+ menubarPath="org.apache.uima.tm.textmarker.ui.popup.submenu">
+ </action>
+ </viewerContribution>
+ <objectContribution
+ adaptable="false"
+ id="org.apache.uima.tm.textmarker.ui.utils.convert.syntax.script"
+ nameFilter="*.tm"
+ objectClass="org.eclipse.dltk.core.ISourceModule">
+ <action
+ class="org.apache.uima.tm.textmarker.ui.convert.ConvertSyntaxAction"
+ icon="icons/tm_obj.png"
+ id="org.apache.uima.tm.textmarker.ui.utils.convert.action"
+ label="Convert syntax"
+ menubarPath="org.apache.uima.tm.textmarker.ui.popup.submenu">
+ </action>
+ </objectContribution>
+ </extension>
+ -->
+</plugin>
Propchange: uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/plugin.xml
------------------------------------------------------------------------------
svn:executable = *
Propchange: uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/plugin.xml
------------------------------------------------------------------------------
svn:mime-type = text/plain
Added: uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/src/main/java/org/apache/uima/tm/textmarker/ui/apply/AbstarctApplyScriptHandler.java
URL: http://svn.apache.org/viewvc/uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/src/main/java/org/apache/uima/tm/textmarker/ui/apply/AbstarctApplyScriptHandler.java?rev=1152828&view=auto
==============================================================================
--- uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/src/main/java/org/apache/uima/tm/textmarker/ui/apply/AbstarctApplyScriptHandler.java (added)
+++ uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/src/main/java/org/apache/uima/tm/textmarker/ui/apply/AbstarctApplyScriptHandler.java Mon Aug 1 15:28:46 2011
@@ -0,0 +1,51 @@
+package org.apache.uima.tm.textmarker.ui.apply;
+
+import org.apache.uima.tm.textmarker.ui.utils.TextMarkerUtilsPlugin;
+import org.eclipse.core.commands.ExecutionEvent;
+import org.eclipse.core.commands.ExecutionException;
+import org.eclipse.core.commands.IHandler;
+import org.eclipse.core.commands.IHandlerListener;
+import org.eclipse.core.resources.IFile;
+import org.eclipse.ui.IEditorInput;
+import org.eclipse.ui.IEditorPart;
+import org.eclipse.ui.IWorkbench;
+import org.eclipse.ui.IWorkbenchPage;
+import org.eclipse.ui.part.FileEditorInput;
+
+
+public abstract class AbstarctApplyScriptHandler implements IHandler {
+
+ public void addHandlerListener(IHandlerListener handlerListener) {
+ }
+
+ public void dispose() {
+ }
+
+ @Override
+ public Object execute(ExecutionEvent event) throws ExecutionException {
+ IWorkbench workbench = TextMarkerUtilsPlugin.getDefault().getWorkbench();
+ IWorkbenchPage page = workbench.getActiveWorkbenchWindow().getActivePage();
+ IEditorPart part = page.getActiveEditor();
+ IEditorInput editorInput = part.getEditorInput();
+ if (editorInput instanceof FileEditorInput) {
+ FileEditorInput input = (FileEditorInput) editorInput;
+ IFile path = input.getFile();
+ getJob(event, path).schedule();
+ }
+ return null;
+ }
+
+ abstract AbstractApplyScriptHandlerJob getJob(ExecutionEvent event, IFile path);
+
+ public boolean isEnabled() {
+ return true;
+ }
+
+ public boolean isHandled() {
+ return true;
+ }
+
+ public void removeHandlerListener(IHandlerListener handlerListener) {
+
+ }
+}
Propchange: uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/src/main/java/org/apache/uima/tm/textmarker/ui/apply/AbstarctApplyScriptHandler.java
------------------------------------------------------------------------------
svn:executable = *
Propchange: uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/src/main/java/org/apache/uima/tm/textmarker/ui/apply/AbstarctApplyScriptHandler.java
------------------------------------------------------------------------------
svn:mime-type = text/plain
Added: uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/src/main/java/org/apache/uima/tm/textmarker/ui/apply/AbstractApplyScriptHandlerJob.java
URL: http://svn.apache.org/viewvc/uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/src/main/java/org/apache/uima/tm/textmarker/ui/apply/AbstractApplyScriptHandlerJob.java?rev=1152828&view=auto
==============================================================================
--- uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/src/main/java/org/apache/uima/tm/textmarker/ui/apply/AbstractApplyScriptHandlerJob.java (added)
+++ uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/src/main/java/org/apache/uima/tm/textmarker/ui/apply/AbstractApplyScriptHandlerJob.java Mon Aug 1 15:28:46 2011
@@ -0,0 +1,217 @@
+package org.apache.uima.tm.textmarker.ui.apply;
+
+import java.io.File;
+import java.io.FileInputStream;
+import java.io.FileOutputStream;
+import java.io.IOException;
+import java.util.ArrayList;
+import java.util.Iterator;
+import java.util.List;
+
+import org.apache.uima.UIMAFramework;
+import org.apache.uima.analysis_engine.AnalysisEngine;
+import org.apache.uima.cas.CAS;
+import org.apache.uima.cas.impl.XmiCasDeserializer;
+import org.apache.uima.cas.impl.XmiCasSerializer;
+import org.apache.uima.resource.ResourceManager;
+import org.apache.uima.resource.ResourceSpecifier;
+import org.apache.uima.tm.dltk.core.TextMarkerPlugin;
+import org.apache.uima.tm.dltk.internal.core.builder.TextMarkerProjectUtils;
+import org.apache.uima.tm.textmarker.engine.TextMarkerEngine;
+import org.apache.uima.util.XMLInputSource;
+import org.apache.uima.util.XMLSerializer;
+import org.eclipse.core.commands.ExecutionEvent;
+import org.eclipse.core.resources.IFile;
+import org.eclipse.core.resources.IFolder;
+import org.eclipse.core.resources.IResource;
+import org.eclipse.core.resources.IWorkspace;
+import org.eclipse.core.resources.IWorkspaceRoot;
+import org.eclipse.core.resources.ResourcesPlugin;
+import org.eclipse.core.runtime.CoreException;
+import org.eclipse.core.runtime.IPath;
+import org.eclipse.core.runtime.IProgressMonitor;
+import org.eclipse.core.runtime.IStatus;
+import org.eclipse.core.runtime.NullProgressMonitor;
+import org.eclipse.core.runtime.Status;
+import org.eclipse.core.runtime.jobs.Job;
+import org.eclipse.dltk.core.DLTKCore;
+import org.eclipse.jface.viewers.IStructuredSelection;
+import org.eclipse.jface.viewers.StructuredSelection;
+import org.eclipse.ui.handlers.HandlerUtil;
+import org.xml.sax.SAXException;
+
+
+public abstract class AbstractApplyScriptHandlerJob extends Job {
+ private ExecutionEvent event;
+
+ private IFile scriptFile;
+
+ private boolean createXMI;
+
+ AbstractApplyScriptHandlerJob(ExecutionEvent event, IFile scriptFile, boolean createXMI) {
+ super("Applying " + scriptFile.getName() + "...");
+ this.event = event;
+ this.scriptFile = scriptFile;
+ this.createXMI = createXMI;
+ setUser(true);
+ }
+
+ @Override
+ public IStatus run(IProgressMonitor monitor) {
+ monitor.beginTask("Collecting files...", 1);
+
+ if (HandlerUtil.getCurrentSelection(event) instanceof IStructuredSelection) {
+ StructuredSelection selection = (StructuredSelection) HandlerUtil.getCurrentSelection(event);
+ Iterator<?> iter = selection.iterator();
+ IResource first = null;
+
+ List<IPath> paths = new ArrayList<IPath>();
+ while (iter.hasNext()) {
+ Object object = iter.next();
+ if (object instanceof IResource) {
+ IResource resource = (IResource) object;
+ if (first == null) {
+ first = resource;
+ }
+ paths.addAll(getPaths(resource));
+ }
+ }
+ IPath descriptorPath = TextMarkerProjectUtils.getEngineDescriptorPath(scriptFile
+ .getLocation(), scriptFile.getProject());
+ IPath rootPath = TextMarkerProjectUtils.getDescriptorRootPath(scriptFile.getProject());
+
+ CAS cas = null;
+ AnalysisEngine ae = null;
+ try {
+ XMLInputSource in = new XMLInputSource(descriptorPath.toPortableString());
+ ResourceSpecifier specifier = UIMAFramework.getXMLParser().parseResourceSpecifier(in);
+ ResourceManager resMgr = UIMAFramework.newDefaultResourceManager();
+ resMgr.setDataPath(rootPath.toPortableString());
+ ae = UIMAFramework.produceAnalysisEngine(specifier, resMgr, null);
+ initAE(ae);
+ ae.reconfigure();
+ } catch (Exception e) {
+ DLTKCore.error(e.getMessage(), e);
+ return Status.CANCEL_STATUS;
+ }
+ monitor.beginTask("Processing... ", paths.size());
+ for (IPath path : paths) {
+ if (monitor.isCanceled()) {
+ break;
+ }
+
+ monitor.setTaskName("Processing " + path.lastSegment() + "... ");
+ try {
+
+ if (cas == null) {
+ cas = ae.newCAS();
+ } else {
+ cas.reset();
+ }
+ if (path.getFileExtension().equals("xmi")) {
+ XmiCasDeserializer.deserialize(new FileInputStream(path.toPortableString()), cas, true);
+ } else {
+ cas.setDocumentText(getText(path.toPortableString()));
+ }
+ TextMarkerEngine.removeSourceDocumentInformation(cas);
+ TextMarkerEngine.addSourceDocumentInformation(cas, new File(path.toPortableString()));
+ ae.process(cas);
+ } catch (Exception e) {
+ DLTKCore.error(e.getMessage(), e);
+ monitor.worked(1);
+ continue;
+ }
+
+ if (createXMI) {
+ monitor.setTaskName("Writing " + path.lastSegment() + "... ");
+
+ File newFile = null;
+ if (path.getFileExtension().equals("xmi")) {
+ newFile = new File(path.toPortableString());
+ } else {
+ newFile = new File(path.toPortableString() + ".xmi");
+ }
+ try {
+ writeXmi(cas, newFile);
+ } catch (Exception e) {
+ DLTKCore.error(e.getMessage(), e);
+ monitor.worked(1);
+ continue;
+ }
+ IWorkspace workspace = ResourcesPlugin.getWorkspace();
+ IWorkspaceRoot root = workspace.getRoot();
+ IPath makeRelativeTo = path.makeRelativeTo(root.getLocation());
+ IResource resource = root.findMember(makeRelativeTo);
+
+ try {
+ if (resource != null) {
+ resource.getParent()
+ .refreshLocal(IResource.DEPTH_INFINITE, new NullProgressMonitor());
+ }
+ } catch (CoreException e) {
+ }
+ }
+ monitor.worked(1);
+ }
+ if (cas != null) {
+ cas.release();
+ }
+ }
+
+ monitor.done();
+ return Status.OK_STATUS;
+
+ }
+
+ private static void writeXmi(CAS aCas, File name) throws IOException, SAXException {
+ FileOutputStream out = null;
+
+ try {
+ // write XMI
+ out = new FileOutputStream(name);
+ XmiCasSerializer ser = new XmiCasSerializer(aCas.getTypeSystem());
+ XMLSerializer xmlSer = new XMLSerializer(out, false);
+ ser.serialize(aCas, xmlSer.getContentHandler());
+ } catch (Exception e) {
+ TextMarkerPlugin.error(e);
+ } finally {
+ if (out != null) {
+ out.close();
+ }
+ }
+ }
+
+ private List<IPath> getPaths(IResource resource) {
+ List<IPath> paths = new ArrayList<IPath>();
+ if (resource instanceof IFile) {
+ IFile file = (IFile) resource;
+ String fileExtension = file.getFileExtension();
+ if ("txt".equals(fileExtension) || "html".equals(fileExtension)
+ || "xmi".equals(fileExtension) || "htm".equals(fileExtension)) {
+ paths.add(file.getLocation());
+ }
+ } else if (resource instanceof IFolder) {
+ IFolder folder = (IFolder) resource;
+ try {
+ IResource[] members = folder.members();
+ for (IResource each : members) {
+ paths.addAll(getPaths(each));
+ }
+ } catch (CoreException e) {
+ }
+ }
+ return paths;
+ }
+
+ abstract void initAE(AnalysisEngine ae);
+
+ private static String getText(String each) {
+ try {
+ return org.apache.uima.pear.util.FileUtil.loadTextFile(new File(each), "UTF-8");
+ } catch (IOException e) {
+ DLTKCore.error(e.getMessage(), e);
+ }
+ return "";
+ }
+
+}
\ No newline at end of file
Propchange: uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/src/main/java/org/apache/uima/tm/textmarker/ui/apply/AbstractApplyScriptHandlerJob.java
------------------------------------------------------------------------------
svn:executable = *
Propchange: uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/src/main/java/org/apache/uima/tm/textmarker/ui/apply/AbstractApplyScriptHandlerJob.java
------------------------------------------------------------------------------
svn:mime-type = text/plain
Added: uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/src/main/java/org/apache/uima/tm/textmarker/ui/apply/ApplyScriptKeepBasicsHandler.java
URL: http://svn.apache.org/viewvc/uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/src/main/java/org/apache/uima/tm/textmarker/ui/apply/ApplyScriptKeepBasicsHandler.java?rev=1152828&view=auto
==============================================================================
--- uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/src/main/java/org/apache/uima/tm/textmarker/ui/apply/ApplyScriptKeepBasicsHandler.java (added)
+++ uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/src/main/java/org/apache/uima/tm/textmarker/ui/apply/ApplyScriptKeepBasicsHandler.java Mon Aug 1 15:28:46 2011
@@ -0,0 +1,13 @@
+package org.apache.uima.tm.textmarker.ui.apply;
+
+import org.eclipse.core.commands.ExecutionEvent;
+import org.eclipse.core.resources.IFile;
+
+public class ApplyScriptKeepBasicsHandler extends AbstarctApplyScriptHandler {
+
+ @Override
+ AbstractApplyScriptHandlerJob getJob(ExecutionEvent event, IFile path) {
+ return new ApplyScriptKeepBasicsJob(event, path);
+ }
+
+}
Propchange: uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/src/main/java/org/apache/uima/tm/textmarker/ui/apply/ApplyScriptKeepBasicsHandler.java
------------------------------------------------------------------------------
svn:executable = *
Propchange: uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/src/main/java/org/apache/uima/tm/textmarker/ui/apply/ApplyScriptKeepBasicsHandler.java
------------------------------------------------------------------------------
svn:mime-type = text/plain
Added: uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/src/main/java/org/apache/uima/tm/textmarker/ui/apply/ApplyScriptKeepBasicsJob.java
URL: http://svn.apache.org/viewvc/uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/src/main/java/org/apache/uima/tm/textmarker/ui/apply/ApplyScriptKeepBasicsJob.java?rev=1152828&view=auto
==============================================================================
--- uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/src/main/java/org/apache/uima/tm/textmarker/ui/apply/ApplyScriptKeepBasicsJob.java (added)
+++ uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/src/main/java/org/apache/uima/tm/textmarker/ui/apply/ApplyScriptKeepBasicsJob.java Mon Aug 1 15:28:46 2011
@@ -0,0 +1,20 @@
+package org.apache.uima.tm.textmarker.ui.apply;
+
+import org.apache.uima.analysis_engine.AnalysisEngine;
+import org.apache.uima.tm.textmarker.engine.TextMarkerEngine;
+import org.eclipse.core.commands.ExecutionEvent;
+import org.eclipse.core.resources.IFile;
+
+
+public class ApplyScriptKeepBasicsJob extends AbstractApplyScriptHandlerJob {
+
+ ApplyScriptKeepBasicsJob(ExecutionEvent event, IFile scriptFile) {
+ super(event, scriptFile, true);
+ }
+
+ @Override
+ void initAE(AnalysisEngine ae) {
+ ae.setConfigParameterValue(TextMarkerEngine.REMOVE_BASICS, false);
+ }
+
+}
Propchange: uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/src/main/java/org/apache/uima/tm/textmarker/ui/apply/ApplyScriptKeepBasicsJob.java
------------------------------------------------------------------------------
svn:executable = *
Propchange: uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/src/main/java/org/apache/uima/tm/textmarker/ui/apply/ApplyScriptKeepBasicsJob.java
------------------------------------------------------------------------------
svn:mime-type = text/plain
Added: uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/src/main/java/org/apache/uima/tm/textmarker/ui/apply/ApplyScriptNoXMIHandler.java
URL: http://svn.apache.org/viewvc/uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/src/main/java/org/apache/uima/tm/textmarker/ui/apply/ApplyScriptNoXMIHandler.java?rev=1152828&view=auto
==============================================================================
--- uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/src/main/java/org/apache/uima/tm/textmarker/ui/apply/ApplyScriptNoXMIHandler.java (added)
+++ uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/src/main/java/org/apache/uima/tm/textmarker/ui/apply/ApplyScriptNoXMIHandler.java Mon Aug 1 15:28:46 2011
@@ -0,0 +1,13 @@
+package org.apache.uima.tm.textmarker.ui.apply;
+
+import org.eclipse.core.commands.ExecutionEvent;
+import org.eclipse.core.resources.IFile;
+
+public class ApplyScriptNoXMIHandler extends AbstarctApplyScriptHandler {
+
+ @Override
+ AbstractApplyScriptHandlerJob getJob(ExecutionEvent event, IFile path) {
+ return new ApplyScriptNoXMIJob(event, path);
+ }
+
+}
Propchange: uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/src/main/java/org/apache/uima/tm/textmarker/ui/apply/ApplyScriptNoXMIHandler.java
------------------------------------------------------------------------------
svn:executable = *
Propchange: uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/src/main/java/org/apache/uima/tm/textmarker/ui/apply/ApplyScriptNoXMIHandler.java
------------------------------------------------------------------------------
svn:mime-type = text/plain
Added: uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/src/main/java/org/apache/uima/tm/textmarker/ui/apply/ApplyScriptNoXMIJob.java
URL: http://svn.apache.org/viewvc/uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/src/main/java/org/apache/uima/tm/textmarker/ui/apply/ApplyScriptNoXMIJob.java?rev=1152828&view=auto
==============================================================================
--- uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/src/main/java/org/apache/uima/tm/textmarker/ui/apply/ApplyScriptNoXMIJob.java (added)
+++ uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/src/main/java/org/apache/uima/tm/textmarker/ui/apply/ApplyScriptNoXMIJob.java Mon Aug 1 15:28:46 2011
@@ -0,0 +1,20 @@
+package org.apache.uima.tm.textmarker.ui.apply;
+
+import org.apache.uima.analysis_engine.AnalysisEngine;
+import org.apache.uima.tm.textmarker.engine.TextMarkerEngine;
+import org.eclipse.core.commands.ExecutionEvent;
+import org.eclipse.core.resources.IFile;
+
+
+public class ApplyScriptNoXMIJob extends AbstractApplyScriptHandlerJob {
+
+ ApplyScriptNoXMIJob(ExecutionEvent event, IFile scriptFile) {
+ super(event, scriptFile, false);
+ }
+
+ @Override
+ void initAE(AnalysisEngine ae) {
+ ae.setConfigParameterValue(TextMarkerEngine.REMOVE_BASICS, false);
+ }
+
+}
Propchange: uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/src/main/java/org/apache/uima/tm/textmarker/ui/apply/ApplyScriptNoXMIJob.java
------------------------------------------------------------------------------
svn:executable = *
Propchange: uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/src/main/java/org/apache/uima/tm/textmarker/ui/apply/ApplyScriptNoXMIJob.java
------------------------------------------------------------------------------
svn:mime-type = text/plain
Added: uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/src/main/java/org/apache/uima/tm/textmarker/ui/apply/ApplyScriptRemoveBasicsHandler.java
URL: http://svn.apache.org/viewvc/uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/src/main/java/org/apache/uima/tm/textmarker/ui/apply/ApplyScriptRemoveBasicsHandler.java?rev=1152828&view=auto
==============================================================================
--- uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/src/main/java/org/apache/uima/tm/textmarker/ui/apply/ApplyScriptRemoveBasicsHandler.java (added)
+++ uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/src/main/java/org/apache/uima/tm/textmarker/ui/apply/ApplyScriptRemoveBasicsHandler.java Mon Aug 1 15:28:46 2011
@@ -0,0 +1,13 @@
+package org.apache.uima.tm.textmarker.ui.apply;
+
+import org.eclipse.core.commands.ExecutionEvent;
+import org.eclipse.core.resources.IFile;
+
+public class ApplyScriptRemoveBasicsHandler extends AbstarctApplyScriptHandler {
+
+ @Override
+ AbstractApplyScriptHandlerJob getJob(ExecutionEvent event, IFile path) {
+ return new ApplyScriptRemoveBasicsJob(event, path);
+ }
+
+}
Propchange: uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/src/main/java/org/apache/uima/tm/textmarker/ui/apply/ApplyScriptRemoveBasicsHandler.java
------------------------------------------------------------------------------
svn:executable = *
Propchange: uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/src/main/java/org/apache/uima/tm/textmarker/ui/apply/ApplyScriptRemoveBasicsHandler.java
------------------------------------------------------------------------------
svn:mime-type = text/plain
Added: uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/src/main/java/org/apache/uima/tm/textmarker/ui/apply/ApplyScriptRemoveBasicsJob.java
URL: http://svn.apache.org/viewvc/uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/src/main/java/org/apache/uima/tm/textmarker/ui/apply/ApplyScriptRemoveBasicsJob.java?rev=1152828&view=auto
==============================================================================
--- uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/src/main/java/org/apache/uima/tm/textmarker/ui/apply/ApplyScriptRemoveBasicsJob.java (added)
+++ uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/src/main/java/org/apache/uima/tm/textmarker/ui/apply/ApplyScriptRemoveBasicsJob.java Mon Aug 1 15:28:46 2011
@@ -0,0 +1,20 @@
+package org.apache.uima.tm.textmarker.ui.apply;
+
+import org.apache.uima.analysis_engine.AnalysisEngine;
+import org.apache.uima.tm.textmarker.engine.TextMarkerEngine;
+import org.eclipse.core.commands.ExecutionEvent;
+import org.eclipse.core.resources.IFile;
+
+
+public class ApplyScriptRemoveBasicsJob extends AbstractApplyScriptHandlerJob {
+
+ ApplyScriptRemoveBasicsJob(ExecutionEvent event, IFile scriptFile) {
+ super(event, scriptFile, true);
+ }
+
+ @Override
+ void initAE(AnalysisEngine ae) {
+ ae.setConfigParameterValue(TextMarkerEngine.REMOVE_BASICS, true);
+ }
+
+}
Propchange: uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/src/main/java/org/apache/uima/tm/textmarker/ui/apply/ApplyScriptRemoveBasicsJob.java
------------------------------------------------------------------------------
svn:executable = *
Propchange: uima/sandbox/trunk/TextMarker/org.apache.uima.tm.textmarker.ui.utils/src/main/java/org/apache/uima/tm/textmarker/ui/apply/ApplyScriptRemoveBasicsJob.java
------------------------------------------------------------------------------
svn:mime-type = text/plain