Révision 3063
| tmp/org.txm.treetagger.rcp/META-INF/MANIFEST.MF (revision 3063) | ||
|---|---|---|
| 11 | 11 |
Bundle-ManifestVersion: 2 |
| 12 | 12 |
Bundle-RequiredExecutionEnvironment: JavaSE-1.8 |
| 13 | 13 |
Bundle-Vendor: Textometrie.org |
| 14 |
Automatic-Module-Name: org.txm.treetagger.rcp |
|
| 14 | 15 |
|
| tmp/org.txm.treetagger.core/META-INF/MANIFEST.MF (revision 3063) | ||
|---|---|---|
| 10 | 10 |
Bundle-ManifestVersion: 2 |
| 11 | 11 |
Bundle-RequiredExecutionEnvironment: JavaSE-1.8 |
| 12 | 12 |
Bundle-Vendor: Textometrie.org |
| 13 |
Automatic-Module-Name: org.txm.treetagger.core |
|
| 13 | 14 |
|
| tmp/org.txm.searchengine.core/META-INF/MANIFEST.MF (revision 3063) | ||
|---|---|---|
| 10 | 10 |
Bundle-ManifestVersion: 2 |
| 11 | 11 |
Bundle-RequiredExecutionEnvironment: JavaSE-1.8 |
| 12 | 12 |
Bundle-Vendor: Textometrie.org |
| 13 |
Automatic-Module-Name: org.txm.searchengine.core |
|
| 13 | 14 |
|
| tmp/org.txm.properties.core/META-INF/MANIFEST.MF (revision 3063) | ||
|---|---|---|
| 10 | 10 |
Bundle-ManifestVersion: 2 |
| 11 | 11 |
Bundle-RequiredExecutionEnvironment: JavaSE-1.8 |
| 12 | 12 |
Bundle-Vendor: Textometrie.org |
| 13 |
Automatic-Module-Name: org.txm.properties.core |
|
| 13 | 14 |
|
| tmp/org.txm.tmp.rcp/META-INF/MANIFEST.MF (revision 3063) | ||
|---|---|---|
| 6 | 6 |
Bundle-ManifestVersion: 2 |
| 7 | 7 |
Bundle-RequiredExecutionEnvironment: JavaSE-1.8 |
| 8 | 8 |
Bundle-Vendor: Textometrie.org |
| 9 |
Automatic-Module-Name: org.txm.tmp.rcp |
|
| 9 | 10 |
|
| tmp/org.txm.treetaggerinstaller.rcp/META-INF/MANIFEST.MF (revision 3063) | ||
|---|---|---|
| 14 | 14 |
Bundle-ManifestVersion: 2 |
| 15 | 15 |
Bundle-RequiredExecutionEnvironment: JavaSE-1.8 |
| 16 | 16 |
Bundle-Vendor: Textometrie.org |
| 17 |
Automatic-Module-Name: org.txm.treetaggerinstaller.rcp |
|
| 17 | 18 |
|
| tmp/org.txm.practically.rcp/META-INF/MANIFEST.MF (revision 3063) | ||
|---|---|---|
| 16 | 16 |
Bundle-ManifestVersion: 2 |
| 17 | 17 |
Bundle-Activator: practicallymacro.editormacros.Activator |
| 18 | 18 |
Bundle-RequiredExecutionEnvironment: JavaSE-1.8 |
| 19 |
Automatic-Module-Name: org.txm.practically.rcp |
|
| 19 | 20 |
|
| tmp/org.txm.chartsengine.r.rcp/META-INF/MANIFEST.MF (revision 3063) | ||
|---|---|---|
| 9 | 9 |
Bundle-ManifestVersion: 2 |
| 10 | 10 |
Bundle-RequiredExecutionEnvironment: JavaSE-1.8 |
| 11 | 11 |
Bundle-Vendor: Textometrie.org |
| 12 |
Automatic-Module-Name: org.txm.chartsengine.r.rcp |
|
| 12 | 13 |
|
| tmp/org.txm.libs.rserve/META-INF/MANIFEST.MF (revision 3063) | ||
|---|---|---|
| 8 | 8 |
Bundle-ManifestVersion: 2 |
| 9 | 9 |
Bundle-RequiredExecutionEnvironment: JavaSE-1.8 |
| 10 | 10 |
Bundle-Vendor: https://rforge.net/Rserve/index.html |
| 11 |
Automatic-Module-Name: org.txm.libs.rserve |
|
| 11 | 12 |
|
| tmp/org.txm.libs.jfreesvg/META-INF/MANIFEST.MF (revision 3063) | ||
|---|---|---|
| 8 | 8 |
Bundle-ManifestVersion: 2 |
| 9 | 9 |
Bundle-RequiredExecutionEnvironment: JavaSE-1.8 |
| 10 | 10 |
Bundle-Vendor: www.jfree.org |
| 11 |
Automatic-Module-Name: org.txm.libs.jfreesvg |
|
| 11 | 12 |
|
| tmp/org.txm.libs.jfreechart/META-INF/MANIFEST.MF (revision 3063) | ||
|---|---|---|
| 47 | 47 |
Bundle-Vendor: www.jfree.org |
| 48 | 48 |
Bundle-ClassPath: ., |
| 49 | 49 |
lib/jfreechart-1.5.0.jar |
| 50 |
Automatic-Module-Name: org.txm.libs.jfreechart |
|
| tmp/org.txm.libs.graphstream/META-INF/MANIFEST.MF (revision 3063) | ||
|---|---|---|
| 52 | 52 |
Bundle-ManifestVersion: 2 |
| 53 | 53 |
Bundle-RequiredExecutionEnvironment: JavaSE-1.8 |
| 54 | 54 |
Bundle-Vendor: http://graphstream-project.org |
| 55 |
Automatic-Module-Name: org.txm.libs.graphstream |
|
| 55 | 56 |
|
| tmp/org.txm.para.rcp/META-INF/MANIFEST.MF (revision 3063) | ||
|---|---|---|
| 10 | 10 |
Bundle-ManifestVersion: 2 |
| 11 | 11 |
Bundle-RequiredExecutionEnvironment: JavaSE-1.8 |
| 12 | 12 |
Bundle-Vendor: Textometrie.org |
| 13 |
Automatic-Module-Name: org.txm.para.rcp |
|
| 13 | 14 |
|
| tmp/org.txm.imports.metopes/META-INF/MANIFEST.MF (revision 3063) | ||
|---|---|---|
| 15 | 15 |
org.txm.imports.metopes, |
| 16 | 16 |
org.txm.macro.metopes |
| 17 | 17 |
Bundle-Vendor: Textometrie.org |
| 18 |
Automatic-Module-Name: org.txm.imports.metopes |
|
| tmp/org.txm.chartsengine.jfreechart.rcp/META-INF/MANIFEST.MF (revision 3063) | ||
|---|---|---|
| 17 | 17 |
Bundle-ManifestVersion: 2 |
| 18 | 18 |
Bundle-RequiredExecutionEnvironment: JavaSE-1.8 |
| 19 | 19 |
Bundle-Vendor: Textometrie.org |
| 20 |
Automatic-Module-Name: org.txm.chartsengine.jfreechart.rcp |
|
| 20 | 21 |
|
| tmp/org.txm.statsengine.r.core.linux/META-INF/MANIFEST.MF (revision 3063) | ||
|---|---|---|
| 7 | 7 |
Bundle-RequiredExecutionEnvironment: JavaSE-1.7 |
| 8 | 8 |
Eclipse-PlatformFilter: (osgi.os=linux) |
| 9 | 9 |
Bundle-Vendor: Textometrie.org |
| 10 |
Automatic-Module-Name: org.txm.statsengine.r.core.linux |
|
| tmp/org.txm.oriflamms.rcp/META-INF/MANIFEST.MF (revision 3063) | ||
|---|---|---|
| 12 | 12 |
Bundle-Activator: oriflamms.Activator |
| 13 | 13 |
Bundle-RequiredExecutionEnvironment: JavaSE-1.8 |
| 14 | 14 |
Bundle-Vendor: Textometrie.org |
| 15 |
Automatic-Module-Name: org.txm.oriflamms.rcp |
|
| 15 | 16 |
|
| tmp/org.txm.rcp.feature/feature.xml (revision 3063) | ||
|---|---|---|
| 254 | 254 |
<import plugin="org.eclipse.e4.ui.workbench.renderers.swt"/> |
| 255 | 255 |
<import plugin="javax.annotation" version="1.2.0" match="greaterOrEqual"/> |
| 256 | 256 |
<import plugin="org.txm.rcp" version="0.8.0" match="greaterOrEqual"/> |
| 257 |
<import plugin="org.txm.searchengine.core" version="1.0.0" match="greaterOrEqual"/> |
|
| 258 |
<import plugin="org.txm.rcp" version="0.8.1" match="greaterOrEqual"/> |
|
| 257 | 259 |
</requires> |
| 258 | 260 |
|
| 259 | 261 |
<plugin |
| tmp/org.txm.rcp.p2.ui/META-INF/MANIFEST.MF (revision 3063) | ||
|---|---|---|
| 11 | 11 |
Export-Package: org.eclipse.equinox.internal.p2.ui, |
| 12 | 12 |
org.eclipse.equinox.internal.p2.ui.dialogs |
| 13 | 13 |
Bundle-Vendor: Textometrie.org |
| 14 |
Automatic-Module-Name: org.txm.rcp.p2.ui |
|
| tmp/org.txm.libs.saxon/META-INF/MANIFEST.MF (revision 3063) | ||
|---|---|---|
| 18 | 18 |
Bundle-ManifestVersion: 2 |
| 19 | 19 |
Bundle-RequiredExecutionEnvironment: JavaSE-1.8 |
| 20 | 20 |
Bundle-Vendor: http://saxon.sourceforge.net/ |
| 21 |
Automatic-Module-Name: org.txm.libs.saxon |
|
| 21 | 22 |
|
| tmp/org.txm.backtomedia.rcp/META-INF/MANIFEST.MF (revision 3063) | ||
|---|---|---|
| 27 | 27 |
uk.co.caprica.vlcj.factory.swt, |
| 28 | 28 |
uk.co.caprica.vlcj.player.embedded.videosurface.swt, |
| 29 | 29 |
vlcplayerrcp |
| 30 |
Automatic-Module-Name: org.txm.backtomedia.rcp |
|
| 30 | 31 |
|
| tmp/org.txm.annotation.rcp/META-INF/MANIFEST.MF (revision 3063) | ||
|---|---|---|
| 12 | 12 |
Bundle-ManifestVersion: 2 |
| 13 | 13 |
Bundle-RequiredExecutionEnvironment: JavaSE-1.8 |
| 14 | 14 |
Bundle-Vendor: Textometrie.org |
| 15 |
Automatic-Module-Name: org.txm.annotation.rcp |
|
| 15 | 16 |
|
| tmp/org.txm.chartsengine.rcp/META-INF/MANIFEST.MF (revision 3063) | ||
|---|---|---|
| 12 | 12 |
Bundle-ManifestVersion: 2 |
| 13 | 13 |
Bundle-RequiredExecutionEnvironment: JavaSE-1.8 |
| 14 | 14 |
Bundle-Vendor: Textometrie.org |
| 15 |
Automatic-Module-Name: org.txm.chartsengine.rcp |
|
| 15 | 16 |
|
| tmp/org.txm.internalview.core/META-INF/MANIFEST.MF (revision 3063) | ||
|---|---|---|
| 9 | 9 |
Bundle-ManifestVersion: 2 |
| 10 | 10 |
Bundle-RequiredExecutionEnvironment: JavaSE-1.8 |
| 11 | 11 |
Bundle-Vendor: Textometrie.org |
| 12 |
Automatic-Module-Name: org.txm.internalview.core |
|
| 12 | 13 |
|
| tmp/org.txm.utils/META-INF/MANIFEST.MF (revision 3063) | ||
|---|---|---|
| 95 | 95 |
Bundle-ManifestVersion: 2 |
| 96 | 96 |
Bundle-RequiredExecutionEnvironment: JavaSE-1.8 |
| 97 | 97 |
Bundle-Vendor: Textometrie.org |
| 98 |
Automatic-Module-Name: org.txm.utils.core |
|
| 98 | 99 |
|
| tmp/org.txm.chartsengine.r.core/META-INF/MANIFEST.MF (revision 3063) | ||
|---|---|---|
| 11 | 11 |
Bundle-ManifestVersion: 2 |
| 12 | 12 |
Bundle-RequiredExecutionEnvironment: JavaSE-1.8 |
| 13 | 13 |
Bundle-Vendor: Textometrie.org |
| 14 |
Automatic-Module-Name: org.txm.chartsengine.r.core |
|
| 14 | 15 |
|
| tmp/org.txm.links.rcp/META-INF/MANIFEST.MF (revision 3063) | ||
|---|---|---|
| 8 | 8 |
Bundle-ManifestVersion: 2 |
| 9 | 9 |
Bundle-RequiredExecutionEnvironment: JavaSE-1.8 |
| 10 | 10 |
Bundle-Vendor: Textometrie.org |
| 11 |
Automatic-Module-Name: org.txm.links.rcp |
|
| 11 | 12 |
|
| tmp/org.txm.textsbalance.core/META-INF/MANIFEST.MF (revision 3063) | ||
|---|---|---|
| 12 | 12 |
Bundle-ManifestVersion: 2 |
| 13 | 13 |
Bundle-RequiredExecutionEnvironment: JavaSE-1.8 |
| 14 | 14 |
Bundle-Vendor: Textometrie.org |
| 15 |
Automatic-Module-Name: org.txm.textsbalance.core |
|
| 15 | 16 |
|
| tmp/org.txm.concordance.core/META-INF/MANIFEST.MF (revision 3063) | ||
|---|---|---|
| 12 | 12 |
Bundle-ManifestVersion: 2 |
| 13 | 13 |
Bundle-RequiredExecutionEnvironment: JavaSE-1.8 |
| 14 | 14 |
Bundle-Vendor: Textometry.org |
| 15 |
Automatic-Module-Name: org.txm.concordance.core |
|
| 15 | 16 |
|
| tmp/org.txm.chartsengine.graphstream.rcp/META-INF/MANIFEST.MF (revision 3063) | ||
|---|---|---|
| 13 | 13 |
Bundle-ManifestVersion: 2 |
| 14 | 14 |
Bundle-RequiredExecutionEnvironment: JavaSE-1.8 |
| 15 | 15 |
Bundle-Vendor: Textometrie.org |
| 16 |
Automatic-Module-Name: org.txm.chartsengine.graphstream.rcp |
|
| 16 | 17 |
|
| tmp/org.txm.statsengine.r.core/META-INF/MANIFEST.MF (revision 3063) | ||
|---|---|---|
| 14 | 14 |
Bundle-ManifestVersion: 2 |
| 15 | 15 |
Bundle-RequiredExecutionEnvironment: JavaSE-1.8 |
| 16 | 16 |
Bundle-Vendor: Textometrie.org |
| 17 |
Automatic-Module-Name: org.txm.statsengine.r.core |
|
| 17 | 18 |
|
| tmp/org.txm.libs.cqp.win32/META-INF/MANIFEST.MF (revision 3063) | ||
|---|---|---|
| 7 | 7 |
Eclipse-PlatformFilter: (osgi.os=win32) |
| 8 | 8 |
Bundle-Vendor: Textometrie.org |
| 9 | 9 |
Fragment-Host: org.txm.libs.cqp |
| 10 |
Automatic-Module-Name: org.txm.libs.cqp.win32 |
|
| 10 | 11 |
|
| tmp/org.txm.tigersearch.rcp/META-INF/MANIFEST.MF (revision 3063) | ||
|---|---|---|
| 42 | 42 |
Bundle-ClassPath: lib/dom4j-1.6.1.jar,lib/log4j-1.2.12.jar,lib/TigerSe |
| 43 | 43 |
arch.jar,. |
| 44 | 44 |
Bundle-Activator: tigersearch4txm.Activator |
| 45 |
Automatic-Module-Name: org.txm.tigersearch.rcp |
|
| 45 | 46 |
|
| tmp/org.txm.libs.groovy-all/META-INF/MANIFEST.MF (revision 3063) | ||
|---|---|---|
| 82 | 82 |
Bundle-ManifestVersion: 2 |
| 83 | 83 |
Bundle-RequiredExecutionEnvironment: JavaSE-1.8 |
| 84 | 84 |
Bundle-Vendor: Textometrie.org |
| 85 |
Automatic-Module-Name: org.txm.libs.groovy-all |
|
| 85 | 86 |
|
| tmp/org.txm.chartsengine.core/META-INF/MANIFEST.MF (revision 3063) | ||
|---|---|---|
| 10 | 10 |
Bundle-ManifestVersion: 2 |
| 11 | 11 |
Bundle-RequiredExecutionEnvironment: JavaSE-1.8 |
| 12 | 12 |
Bundle-Vendor: Textometrie.org |
| 13 |
Automatic-Module-Name: org.txm.chartsengine.core |
|
| 13 | 14 |
|
| tmp/org.txm.tokenizer.core/build.properties (revision 3063) | ||
|---|---|---|
| 6 | 6 |
OSGI-INF/ |
| 7 | 7 |
source..=src/ |
| 8 | 8 |
#qualifier=svn |
| 9 |
sourceFileExtensions=*.java, *.groovy |
|
| 10 |
compilerAdapter=org.codehaus.groovy.eclipse.ant.GroovyCompilerAdapter |
|
| 11 |
compilerAdapter.useLog=true # this ensures that exceptions are logged to the proper log file. |
|
| tmp/org.txm.searchengine.cqp.core/src/org/txm/importer/cwb/ReadRegistryFile.java (revision 3063) | ||
|---|---|---|
| 39 | 39 |
* reload the informations |
| 40 | 40 |
*/ |
| 41 | 41 |
public void read() {
|
| 42 |
pAttributes = new ArrayList(); |
|
| 42 |
pAttributes = new ArrayList<>();
|
|
| 43 | 43 |
sAttributes = new ArrayList(); |
| 44 | 44 |
sattrs = new HashMap<>(); |
| 45 | 45 |
sattrsProfs = new HashMap<>(); |
| tmp/org.txm.searchengine.cqp.core/META-INF/MANIFEST.MF (revision 3063) | ||
|---|---|---|
| 21 | 21 |
Bundle-ManifestVersion: 2 |
| 22 | 22 |
Bundle-RequiredExecutionEnvironment: JavaSE-1.8 |
| 23 | 23 |
Bundle-Vendor: %Bundle-Vendor |
| 24 |
Automatic-Module-Name: org.txm.searchengine.cqp.core |
|
| 24 | 25 |
|
| tmp/org.txm.ca.rcp/META-INF/MANIFEST.MF (revision 3063) | ||
|---|---|---|
| 12 | 12 |
Bundle-ManifestVersion: 2 |
| 13 | 13 |
Bundle-RequiredExecutionEnvironment: JavaSE-1.8 |
| 14 | 14 |
Bundle-Vendor: Textometrie.org |
| 15 |
Automatic-Module-Name: org.txm.ca.rcp |
|
| 15 | 16 |
|
| tmp/org.txm.referencer.core/META-INF/MANIFEST.MF (revision 3063) | ||
|---|---|---|
| 11 | 11 |
Bundle-ManifestVersion: 2 |
| 12 | 12 |
Bundle-RequiredExecutionEnvironment: JavaSE-1.8 |
| 13 | 13 |
Bundle-Vendor: Textometrie.org |
| 14 |
Automatic-Module-Name: org.txm.referencer.core |
|
| 14 | 15 |
|
| tmp/org.txm.para.core/META-INF/MANIFEST.MF (revision 3063) | ||
|---|---|---|
| 9 | 9 |
Bundle-ManifestVersion: 2 |
| 10 | 10 |
Bundle-RequiredExecutionEnvironment: JavaSE-1.8 |
| 11 | 11 |
Bundle-Vendor: Textometrie.org |
| 12 |
Automatic-Module-Name: org.txm.para.core |
|
| 12 | 13 |
|
| tmp/org.txm.groovy.core/src/groovy/org/txm/scripts/importer/xml/pager.groovy (revision 3063) | ||
|---|---|---|
| 300 | 300 |
case XMLStreamConstants.START_ELEMENT: |
| 301 | 301 |
localname = parser.getLocalName(); |
| 302 | 302 |
|
| 303 |
if (paginate && localname == paginationElement) {
|
|
| 304 |
createNextOutput(); |
|
| 303 |
if (localname == paginationElement) {
|
|
| 304 |
if (paginate) createNextOutput(); |
|
| 305 |
|
|
| 305 | 306 |
pagedWriter.write("\n");
|
| 306 | 307 |
if (parser.getAttributeValue(null,"n") != null) {
|
| 307 | 308 |
pagedWriter.writeElement("p", ["style":"color:red", "align":"center"], "- "+parser.getAttributeValue(null,"n")+" -")
|
| tmp/org.txm.groovy.core/src/groovy/org/txm/scripts/importer/transcriber/pager.groovy (revision 3063) | ||
|---|---|---|
| 419 | 419 |
break; |
| 420 | 420 |
case "div": |
| 421 | 421 |
|
| 422 |
|
|
| 423 |
|
|
| 424 | 422 |
if (paginate && paginateSections) {
|
| 425 | 423 |
nbBreak++ |
| 426 | 424 |
writer.writeEmptyElement("pb");
|
| tmp/org.txm.groovy.core/src/groovy/org/txm/scripts/importer/transcriber/TranscriberTokenizer.groovy (revision 3063) | ||
|---|---|---|
| 86 | 86 |
String text = buffer.toString().trim().replace("\t", " ");
|
| 87 | 87 |
text = text.replaceAll("\\p{C}", "");
|
| 88 | 88 |
String previousChar = ""; |
| 89 |
for (String s : text.split("[\\p{Z}\\p{C}]+") )
|
|
| 90 |
{
|
|
| 89 |
for (String s : text.split("[\\p{Z}\\p{C}]+") ) {
|
|
| 91 | 90 |
//init transcriber attributes |
| 92 | 91 |
if (troncature) |
| 93 | 92 |
audio = "absent"; |
| ... | ... | |
| 167 | 166 |
} |
| 168 | 167 |
|
| 169 | 168 |
/** |
| 170 |
* Iterate. |
|
| 169 |
* Iterate over the String to tokenize it and write words using the 'audio', 'event' and "notation' properties.
|
|
| 171 | 170 |
* |
| 172 |
* @param s the s |
|
| 171 |
* @param s the string to tokenize
|
|
| 173 | 172 |
* @return the java.lang. object |
| 174 | 173 |
*/ |
| 175 | 174 |
protected iterate(String s) |
| 176 | 175 |
{
|
| 177 |
while (s != null && s.length() > 0) {
|
|
| 178 |
if (DEBUG) {println " > $s"}
|
|
| 179 |
s = standardChecks(s); |
|
| 180 |
event = ""; |
|
| 176 |
def words = stringTokenizer.processText(s); |
|
| 177 |
for (def word : words) {
|
|
| 178 |
wordcount++; |
|
| 179 |
writer.writeStartElement(word_element_to_create); |
|
| 180 |
writeWordAttributes();// id |
|
| 181 |
writer.writeCharacters(word); |
|
| 182 |
writer.writeEndElement(); |
|
| 183 |
writer.writeCharacters("\n");
|
|
| 181 | 184 |
} |
| 182 | 185 |
} |
| 183 | 186 |
|
| tmp/org.txm.groovy.core/src/groovy/org/txm/scripts/importer/xtz/XTZDefaultPagerStep.groovy (revision 3063) | ||
|---|---|---|
| 163 | 163 |
pagedWriter.writeEndElements(); |
| 164 | 164 |
// write notes |
| 165 | 165 |
if (notes.size() > 0) {
|
| 166 |
pagedWriter.writeEmptyElement("hr", ["id":"notes", "width":"20%", "align":"left"]);
|
|
| 166 |
pagedWriter.writeStartElement("hr", ["id":"notes", "width":"20%", "align":"left"]);
|
|
| 167 |
pagedWriter.writeEndElement() // </hr> |
|
| 167 | 168 |
//pagedWriter.writeStartElement("ol");
|
| 168 | 169 |
int i = 1; |
| 169 | 170 |
for (String note : notes) {
|
| ... | ... | |
| 328 | 329 |
currentOutOfTextElements << localname |
| 329 | 330 |
} |
| 330 | 331 |
|
| 331 |
if (paginate && localname == paginationElement) {
|
|
| 332 |
createNextOutput() |
|
| 333 |
wordcount=0; |
|
| 332 |
if (localname == paginationElement) {
|
|
| 333 |
if (paginate) {
|
|
| 334 |
createNextOutput() |
|
| 335 |
} |
|
| 336 |
|
|
| 337 |
wordcount = 0; |
|
| 334 | 338 |
pagedWriter.write("\n")
|
| 335 | 339 |
if (getAttributeValue(parser, null,"n") != null) {
|
| 336 | 340 |
pagedWriter.writeElement("p", ["class":"txmeditionpb", "align":"center"], getAttributeValue(parser, null,"n"))
|
| ... | ... | |
| 441 | 445 |
pagedWriter.write("\n")
|
| 442 | 446 |
pagedWriter.writeStartElement("p", ["class":rend])
|
| 443 | 447 |
break; |
| 448 |
case "cb": |
|
| 449 |
pagedWriter.write("\n")
|
|
| 450 |
pagedWriter.writeElement("span", ["class":"txmeditioncb", "align":"center"], getAttributeValue(parser, null,"n")) // element ignored in the END_ELEMENT event
|
|
| 451 |
break; |
|
| 444 | 452 |
case "sp": |
| 445 | 453 |
pagedWriter.writeStartElement("p", ["class":"turn"])
|
| 446 | 454 |
|
| ... | ... | |
| 472 | 480 |
break; |
| 473 | 481 |
case "lb": |
| 474 | 482 |
//case "l": |
| 475 |
pagedWriter.writeStartElement("br", ["class":rend])
|
|
| 476 |
pagedWriter.writeEndElement() |
|
| 483 |
pagedWriter.writeEmptyElement("br", ["class":rend])
|
|
| 477 | 484 |
break; |
| 478 | 485 |
case wordTag: |
| 479 | 486 |
wordid = getAttributeValue(parser, null,"id"); |
| ... | ... | |
| 514 | 521 |
localname = parser.getLocalName(); |
| 515 | 522 |
if (currentOutOfTextElements.size() > 0) currentOutOfTextElements.pop() |
| 516 | 523 |
writeOutOfTextToEditText = currentOutOfTextElements.size() > 0 |
| 524 |
|
|
| 525 |
if (localname == paginationElement) {
|
|
| 526 |
break; // element already processed in the START_ELEMENT event |
|
| 527 |
} |
|
| 517 | 528 |
|
| 518 | 529 |
switch (localname) {
|
| 519 | 530 |
case "text": |
| ... | ... | |
| 527 | 538 |
pagedWriter.writeEndElement() // </p> |
| 528 | 539 |
pagedWriter.write("\n")
|
| 529 | 540 |
break; |
| 541 |
case "cb": |
|
| 542 |
break; |
|
| 530 | 543 |
case "lb": |
| 531 | 544 |
break; |
| 532 | 545 |
case "div": |
| tmp/org.txm.groovy.core/src/groovy/org/txm/scripts/filters/Tokeniser/SimpleTokenizerXml.groovy (revision 3063) | ||
|---|---|---|
| 510 | 510 |
text = regLN.matcher(text).replaceAll(WHITESPACE); |
| 511 | 511 |
text = regCTRL.matcher(text).replaceAll(EMPTY); // remove ctrl characters |
| 512 | 512 |
|
| 513 |
def words = stringTokenizer.processText(text);
|
|
| 513 |
def words = stringTokenizer.processText(text); |
|
| 514 | 514 |
for (def word : words) {
|
| 515 | 515 |
wordcount++; |
| 516 | 516 |
writer.writeStartElement(word_element_to_create); |
| tmp/org.txm.groovy.core/META-INF/MANIFEST.MF (revision 3063) | ||
|---|---|---|
| 13 | 13 |
Bundle-ManifestVersion: 2 |
| 14 | 14 |
Bundle-RequiredExecutionEnvironment: JavaSE-1.8 |
| 15 | 15 |
Bundle-Vendor: Textometrie.org |
| 16 |
Automatic-Module-Name: org.txm.groovy.core |
|
| 16 | 17 |
|
| tmp/org.txm.edition.rcp/META-INF/MANIFEST.MF (revision 3063) | ||
|---|---|---|
| 11 | 11 |
Bundle-ManifestVersion: 2 |
| 12 | 12 |
Bundle-RequiredExecutionEnvironment: JavaSE-1.8 |
| 13 | 13 |
Bundle-Vendor: Textometrie.org |
| 14 |
Automatic-Module-Name: org.txm.edition.rcp |
|
| 14 | 15 |
|
| tmp/org.txm.treetagger.core.win32/META-INF/MANIFEST.MF (revision 3063) | ||
|---|---|---|
| 6 | 6 |
Fragment-Host: org.txm.treetagger.core;bundle-version="1.0.0" |
| 7 | 7 |
Bundle-RequiredExecutionEnvironment: JavaSE-1.7 |
| 8 | 8 |
Bundle-Vendor: Textometrie.org |
| 9 |
Automatic-Module-Name: org.txm.treetagger.core.win32 |
|
| tmp/org.txm.dictionary.rcp/META-INF/MANIFEST.MF (revision 3063) | ||
|---|---|---|
| 18 | 18 |
Bundle-ManifestVersion: 2 |
| 19 | 19 |
Bundle-RequiredExecutionEnvironment: JavaSE-1.8 |
| 20 | 20 |
Bundle-Vendor: Textometrie.org |
| 21 |
Automatic-Module-Name: org.txm.dictionary.rcp |
|
| 21 | 22 |
|
| tmp/org.txm.internalview.rcp/META-INF/MANIFEST.MF (revision 3063) | ||
|---|---|---|
| 12 | 12 |
Bundle-ManifestVersion: 2 |
| 13 | 13 |
Bundle-RequiredExecutionEnvironment: JavaSE-1.8 |
| 14 | 14 |
Bundle-Vendor: Textometrie.org |
| 15 |
Automatic-Module-Name: org.txm.internalview.rcp |
|
| 15 | 16 |
|
| tmp/org.txm.referencer.rcp/META-INF/MANIFEST.MF (revision 3063) | ||
|---|---|---|
| 13 | 13 |
Bundle-ManifestVersion: 2 |
| 14 | 14 |
Bundle-RequiredExecutionEnvironment: JavaSE-1.8 |
| 15 | 15 |
Bundle-Vendor: Textometrie.org |
| 16 |
Automatic-Module-Name: org.txm.referencer.rcp |
|
| 16 | 17 |
|
| tmp/org.txm.statsengine.r.core.macosx/META-INF/MANIFEST.MF (revision 3063) | ||
|---|---|---|
| 7 | 7 |
Bundle-RequiredExecutionEnvironment: JavaSE-1.7 |
| 8 | 8 |
Eclipse-PlatformFilter: (osgi.os=macosx) |
| 9 | 9 |
Bundle-Vendor: Textometrie.org |
| 10 |
Automatic-Module-Name: org.txm.statsengine.r.core.macosx |
|
| tmp/org.txm.libs.cqp.linux/META-INF/MANIFEST.MF (revision 3063) | ||
|---|---|---|
| 7 | 7 |
Eclipse-PlatformFilter: (osgi.os=linux) |
| 8 | 8 |
Bundle-Vendor: Textometrie.org |
| 9 | 9 |
Fragment-Host: org.txm.libs.cqp |
| 10 |
Automatic-Module-Name: org.txm.libs.cqp.linux |
|
| 10 | 11 |
|
| tmp/org.txm.queryindex.rcp/META-INF/MANIFEST.MF (revision 3063) | ||
|---|---|---|
| 21 | 21 |
Bundle-Activator: queryindexrcp.Activator |
| 22 | 22 |
Bundle-RequiredExecutionEnvironment: JavaSE-1.8 |
| 23 | 23 |
Bundle-Vendor: Textometrie.org |
| 24 |
Automatic-Module-Name: org.txm.queryindex.rcp |
|
| 24 | 25 |
|
| tmp/org.txm.cooccurrence.rcp/META-INF/MANIFEST.MF (revision 3063) | ||
|---|---|---|
| 12 | 12 |
Bundle-ManifestVersion: 2 |
| 13 | 13 |
Bundle-RequiredExecutionEnvironment: JavaSE-1.8 |
| 14 | 14 |
Bundle-Vendor: Textometrie.org |
| 15 |
Automatic-Module-Name: org.txm.cooccurrence.rcp |
|
| 15 | 16 |
|
| tmp/org.txm.progression.rcp/META-INF/MANIFEST.MF (revision 3063) | ||
|---|---|---|
| 14 | 14 |
Bundle-ManifestVersion: 2 |
| 15 | 15 |
Bundle-RequiredExecutionEnvironment: JavaSE-1.8 |
| 16 | 16 |
Bundle-Vendor: Textometrie.org |
| 17 |
Automatic-Module-Name: org.txm.progression.rcp |
|
| 17 | 18 |
|
| tmp/org.txm.index.core/META-INF/MANIFEST.MF (revision 3063) | ||
|---|---|---|
| 12 | 12 |
Bundle-ManifestVersion: 2 |
| 13 | 13 |
Bundle-RequiredExecutionEnvironment: JavaSE-1.8 |
| 14 | 14 |
Bundle-Vendor: Textometrie.org |
| 15 |
Automatic-Module-Name: org.txm.index.core |
|
| 15 | 16 |
|
| tmp/org.txm.concordance.rcp/META-INF/MANIFEST.MF (revision 3063) | ||
|---|---|---|
| 12 | 12 |
Bundle-ManifestVersion: 2 |
| 13 | 13 |
Bundle-RequiredExecutionEnvironment: JavaSE-1.8 |
| 14 | 14 |
Bundle-Vendor: Textometrie.org |
| 15 |
Automatic-Module-Name: org.txm.concordance.rcp |
|
| 15 | 16 |
|
| tmp/org.txm.treetagger.core.models/META-INF/MANIFEST.MF (revision 3063) | ||
|---|---|---|
| 6 | 6 |
Fragment-Host: org.txm.treetagger.core |
| 7 | 7 |
Bundle-RequiredExecutionEnvironment: JavaSE-1.7 |
| 8 | 8 |
Bundle-Vendor: Textometrie.org |
| 9 |
Automatic-Module-Name: org.txm.treetagger.core.models |
|
| tmp/org.txm.specificities.rcp/META-INF/MANIFEST.MF (revision 3063) | ||
|---|---|---|
| 11 | 11 |
Bundle-ManifestVersion: 2 |
| 12 | 12 |
Bundle-RequiredExecutionEnvironment: JavaSE-1.8 |
| 13 | 13 |
Bundle-Vendor: Textometrie.org |
| 14 |
Automatic-Module-Name: org.txm.specificities.rcp |
|
| 14 | 15 |
|
| tmp/org.txm.treetagger.core.macosx/META-INF/MANIFEST.MF (revision 3063) | ||
|---|---|---|
| 6 | 6 |
Bundle-Version: 1.0.0.qualifier |
| 7 | 7 |
Fragment-Host: org.txm.treetagger.core |
| 8 | 8 |
Bundle-RequiredExecutionEnvironment: JavaSE-1.7 |
| 9 |
Automatic-Module-Name: org.txm.treetagger.core.macosx |
|
| tmp/org.txm.ca.core/META-INF/MANIFEST.MF (revision 3063) | ||
|---|---|---|
| 15 | 15 |
Bundle-ManifestVersion: 2 |
| 16 | 16 |
Bundle-RequiredExecutionEnvironment: JavaSE-1.8 |
| 17 | 17 |
Bundle-Vendor: Textometrie.org |
| 18 |
Automatic-Module-Name: org.txm.ca.core |
|
| 18 | 19 |
|
| tmp/org.txm.libs.cqp/META-INF/MANIFEST.MF (revision 3063) | ||
|---|---|---|
| 9 | 9 |
Bundle-RequiredExecutionEnvironment: JavaSE-1.8 |
| 10 | 10 |
Bundle-ActivationPolicy: lazy |
| 11 | 11 |
Bundle-Vendor: Textometrie.org |
| 12 |
Automatic-Module-Name: org.txm.libs.cqp |
|
| 12 | 13 |
|
| tmp/org.txm.treetagger.core.linux/META-INF/MANIFEST.MF (revision 3063) | ||
|---|---|---|
| 5 | 5 |
Bundle-Version: 1.0.0.qualifier |
| 6 | 6 |
Fragment-Host: org.txm.treetagger.core;bundle-version="1.0.0" |
| 7 | 7 |
Bundle-RequiredExecutionEnvironment: JavaSE-1.7 |
| 8 |
Automatic-Module-Name: org.txm.treetagger.core.linux |
|
| tmp/org.txm.properties.rcp/META-INF/MANIFEST.MF (revision 3063) | ||
|---|---|---|
| 13 | 13 |
Bundle-ManifestVersion: 2 |
| 14 | 14 |
Bundle-RequiredExecutionEnvironment: JavaSE-1.8 |
| 15 | 15 |
Bundle-Vendor: Textometrie.org |
| 16 |
Automatic-Module-Name: org.txm.properties.rcp |
|
| 16 | 17 |
|
| tmp/org.txm.cooccurrence.chartsengine/META-INF/MANIFEST.MF (revision 3063) | ||
|---|---|---|
| 13 | 13 |
org.txm.cooccurrence.editors, |
| 14 | 14 |
org.txm.cooccurrence.functions, |
| 15 | 15 |
org.txm.cooccurrence.handlers |
| 16 |
Automatic-Module-Name: org.txm.cooccurrence.chartsengine |
|
| tmp/org.txm.rcp/META-INF/MANIFEST.MF (revision 3063) | ||
|---|---|---|
| 153 | 153 |
Bundle-Activator: org.txm.rcp.Activator |
| 154 | 154 |
Bundle-RequiredExecutionEnvironment: JavaSE-1.8 |
| 155 | 155 |
Bundle-Vendor: %Bundle-Vendor |
| 156 |
Automatic-Module-Name: org.txm.rcp |
|
| 156 | 157 |
|
| tmp/org.txm.libs.itext/META-INF/MANIFEST.MF (revision 3063) | ||
|---|---|---|
| 15 | 15 |
Bundle-ManifestVersion: 2 |
| 16 | 16 |
Bundle-RequiredExecutionEnvironment: JavaSE-1.8 |
| 17 | 17 |
Bundle-Vendor: itextpdf.com |
| 18 |
Automatic-Module-Name: org.txm.libs.itext |
|
| 18 | 19 |
|
| tmp/org.txm.wordcloud.rcp/META-INF/MANIFEST.MF (revision 3063) | ||
|---|---|---|
| 12 | 12 |
Bundle-ManifestVersion: 2 |
| 13 | 13 |
Bundle-RequiredExecutionEnvironment: JavaSE-1.8 |
| 14 | 14 |
Bundle-Vendor: Textometrie.org |
| 15 |
Automatic-Module-Name: org.txm.wordcloud.rcp |
|
| 15 | 16 |
|
| tmp/org.txm.core/META-INF/MANIFEST.MF (revision 3063) | ||
|---|---|---|
| 468 | 468 |
Bundle-Activator: org.txm.core.Activator |
| 469 | 469 |
Bundle-RequiredExecutionEnvironment: JavaSE-1.8 |
| 470 | 470 |
Bundle-Vendor: Textometrie.org |
| 471 |
Automatic-Module-Name: org.txm.core |
|
| 471 | 472 |
|
| tmp/org.txm.core/src/java/org/txm/scripts/importer/StaxStackWriter.groovy (revision 3063) | ||
|---|---|---|
| 149 | 149 |
* @throws XMLStreamException |
| 150 | 150 |
*/ |
| 151 | 151 |
public void writeElement (String localName, String text) throws XMLStreamException {
|
| 152 |
writer.writeStartElement(localName); |
|
| 153 |
writer.writeCharacters(text); |
|
| 154 |
writer.writeEndElement(); |
|
| 152 |
if (text != null && text.length() > 0) {
|
|
| 153 |
writer.writeStartElement(localName); |
|
| 154 |
writer.writeCharacters(text); |
|
| 155 |
writer.writeEndElement(); |
|
| 156 |
} else {
|
|
| 157 |
writer.writeEmptyElement(localName); |
|
| 158 |
} |
|
| 155 | 159 |
} |
| 156 | 160 |
|
| 157 | 161 |
public void writeElement (String localName, def map, String text) throws XMLStreamException {
|
| 158 |
writer.writeStartElement(localName); |
|
| 159 |
for (def key : map.keySet()) writeAttribute(key.toString(), map[key].toString()); |
|
| 160 |
writer.writeCharacters(text); |
|
| 161 |
writer.writeEndElement(); |
|
| 162 |
if (text != null && text.length() > 0) {
|
|
| 163 |
writer.writeStartElement(localName); |
|
| 164 |
for (def key : map.keySet()) writeAttribute(key.toString(), map[key].toString()); |
|
| 165 |
writer.writeCharacters(text); |
|
| 166 |
writer.writeEndElement(); |
|
| 167 |
} else {
|
|
| 168 |
writer.writeEmptyElement(localName); |
|
| 169 |
for (def key : map.keySet()) writeAttribute(key.toString(), map[key].toString()); |
|
| 170 |
} |
|
| 162 | 171 |
} |
| 163 | 172 |
|
| 164 | 173 |
@Override |
| ... | ... | |
| 168 | 177 |
|
| 169 | 178 |
public void writeEmptyElement (String localName, def map) throws XMLStreamException {
|
| 170 | 179 |
writer.writeEmptyElement(localName); |
| 171 |
for (def key : map.keySet()) |
|
| 172 |
writeAttribute(key.toString(), map[key].toString()); |
|
| 180 |
for (def key : map.keySet()) writeAttribute(key.toString(), map[key].toString()); |
|
| 173 | 181 |
} |
| 174 | 182 |
|
| 175 | 183 |
@Override |
| tmp/org.txm.partition.rcp/META-INF/MANIFEST.MF (revision 3063) | ||
|---|---|---|
| 11 | 11 |
Bundle-ManifestVersion: 2 |
| 12 | 12 |
Bundle-RequiredExecutionEnvironment: JavaSE-1.8 |
| 13 | 13 |
Bundle-Vendor: Textometrie.org |
| 14 |
Automatic-Module-Name: org.txm.partition.rcp |
|
| tmp/org.txm.chartsengine.raster.rcp/META-INF/MANIFEST.MF (revision 3063) | ||
|---|---|---|
| 9 | 9 |
Bundle-ManifestVersion: 2 |
| 10 | 10 |
Bundle-RequiredExecutionEnvironment: JavaSE-1.8 |
| 11 | 11 |
Bundle-Vendor: Textometrie.org |
| 12 |
Automatic-Module-Name: org.txm.chartsengine.raster.rcp |
|
| 12 | 13 |
|
| tmp/org.txm.rcp.about.fragment/META-INF/MANIFEST.MF (revision 3063) | ||
|---|---|---|
| 10 | 10 |
. |
| 11 | 11 |
Export-Package: org.eclipse.ui.internal.about |
| 12 | 12 |
Bundle-Vendor: Textometrie.org |
| 13 |
Automatic-Module-Name: org.txm.rcp.about.fragment |
|
| tmp/org.txm.textsbalance.rcp/META-INF/MANIFEST.MF (revision 3063) | ||
|---|---|---|
| 11 | 11 |
Bundle-ManifestVersion: 2 |
| 12 | 12 |
Bundle-RequiredExecutionEnvironment: JavaSE-1.8 |
| 13 | 13 |
Bundle-Vendor: Textometrie.org |
| 14 |
Automatic-Module-Name: org.txm.textsbalance.rcp |
|
| 14 | 15 |
|
| tmp/org.txm.partition.core/META-INF/MANIFEST.MF (revision 3063) | ||
|---|---|---|
| 13 | 13 |
Bundle-ManifestVersion: 2 |
| 14 | 14 |
Bundle-RequiredExecutionEnvironment: JavaSE-1.8 |
| 15 | 15 |
Bundle-Vendor: Textometrie.org |
| 16 |
Automatic-Module-Name: org.txm.partition.core |
|
| 16 | 17 |
|
| tmp/org.txm.progression.core/META-INF/MANIFEST.MF (revision 3063) | ||
|---|---|---|
| 15 | 15 |
Bundle-ManifestVersion: 2 |
| 16 | 16 |
Bundle-RequiredExecutionEnvironment: JavaSE-1.8 |
| 17 | 17 |
Bundle-Vendor: Textometrie.org |
| 18 |
Automatic-Module-Name: org.txm.progression.core |
|
| 18 | 19 |
|
| tmp/org.txm.cooccurrence.core/META-INF/MANIFEST.MF (revision 3063) | ||
|---|---|---|
| 12 | 12 |
Bundle-ManifestVersion: 2 |
| 13 | 13 |
Bundle-RequiredExecutionEnvironment: JavaSE-1.8 |
| 14 | 14 |
Bundle-Vendor: Textometrie.org |
| 15 |
Automatic-Module-Name: org.txm.cooccurrence.core |
|
| 15 | 16 |
|
| tmp/org.txm.analec.rcp/src/visuAnalec/chaines/VisuConversion.java (revision 3063) | ||
|---|---|---|
| 5 | 5 |
*/ |
| 6 | 6 |
|
| 7 | 7 |
package visuAnalec.chaines; |
| 8 |
|
|
| 8 | 9 |
import java.awt.*; |
| 9 | 10 |
import java.awt.event.*; |
| 10 | 11 |
import java.util.*; |
| ... | ... | |
| 15 | 16 |
import visuAnalec.util.GVisu.*; |
| 16 | 17 |
import visuAnalec.vue.*; |
| 17 | 18 |
import visuAnalec.vue.Vue.*; |
| 19 |
|
|
| 18 | 20 |
/** |
| 19 | 21 |
* |
| 20 | 22 |
* @author marc |
| 21 | 23 |
*/ |
| 22 |
public class VisuConversion extends JFrame implements VueListener, ActionListener{
|
|
| 23 |
private Box PanneauCommande = Box.createVerticalBox(); |
|
| 24 |
private Box PanneauCommandeSource = Box.createVerticalBox(); |
|
| 25 |
private Vue vue; |
|
| 26 |
private PanneauEditeur panneauEditeur; |
|
| 27 |
private JList choixModeConversion = new JList(); |
|
| 28 |
private JButton lancerConversion = new JButton("Convertir");
|
|
| 29 |
private JTextField nomSchema = new JTextField("Chaine de coréférence");
|
|
| 30 |
private Val0ComboBox typeSource = new Val0ComboBox("Rien");
|
|
| 31 |
private Val0ComboBox primaryKey = new Val0ComboBox("Rien");
|
|
| 32 |
private String[] otherKey = new String[0]; |
|
| 33 |
private Val0ComboBox addOtherKey = new Val0ComboBox("Rien");
|
|
| 34 |
private Val0ComboBox removeOtherKey = new Val0ComboBox("Rien");
|
|
| 35 |
private String[] sourcesPossibles = new String[]{"Type de Relation", "Type d'unité","Propriété d'unité"};
|
|
| 36 |
private String[] typesSourceDisponibles = new String[0]; |
|
| 37 |
private ArrayList<String> primaryKeyDisponibles = new ArrayList(); |
|
| 38 |
private ArrayList<String> otherKeyDisponibles = new ArrayList(); |
|
| 39 |
private ArrayList<String> otherKeyAjoutees = new ArrayList(); |
|
| 40 |
public VisuConversion(Container fenetre, Vue vue, PanneauEditeur pEditeur){
|
|
| 41 |
super("Conversion de données en schéma");
|
|
| 42 |
Point pos = new Point(fenetre.getX()+20, fenetre.getY()+20); |
|
| 43 |
Dimension dim = new Dimension(700, 500); |
|
| 44 |
setLocation(pos); |
|
| 45 |
setSize(dim); |
|
| 46 |
this.vue = vue; |
|
| 47 |
vue.addEventListener(this); |
|
| 48 |
this.panneauEditeur = pEditeur; |
|
| 49 |
choixModeConversion.addMouseListener(new MouseAdapter() {
|
|
| 50 |
public void mousePressed(MouseEvent e) {//on gère les évènements de la souris
|
|
| 51 |
check(e); |
|
| 52 |
} |
|
| 53 |
public void mouseReleased(MouseEvent e) {
|
|
| 54 |
//check(e); |
|
| 55 |
} |
|
| 56 |
public void check(MouseEvent e) {
|
|
| 57 |
if (!e.isPopupTrigger()) {//si on a un clique gauche sur la liste
|
|
| 58 |
listAction(choixModeConversion.getSelectedIndex()); |
|
| 59 |
} |
|
| 60 |
} |
|
| 61 |
}); |
|
| 62 |
lancerConversion.addActionListener(this); |
|
| 63 |
PanneauCommandeSource.add(Box.createVerticalStrut(20)); |
|
| 64 |
PanneauCommandeSource.add(new JLabel("Choix de la source de donnée :"));
|
|
| 65 |
PanneauCommandeSource.add(Box.createVerticalStrut(20)); |
|
| 66 |
PanneauCommandeSource.add(choixModeConversion); |
|
| 67 |
PanneauCommandeSource.add(Box.createVerticalStrut(20)); |
|
| 68 |
PanneauCommandeSource.add(lancerConversion); |
|
| 69 |
JSplitPane split = new JSplitPane(JSplitPane.HORIZONTAL_SPLIT, PanneauCommandeSource, PanneauCommande); |
|
| 70 |
getContentPane().add(split); |
|
| 71 |
split.setDividerLocation(1./3); |
|
| 72 |
setVisible(true); |
|
| 73 |
typeSource.setAlignmentX(0); |
|
| 74 |
primaryKey.setAlignmentX(0); |
|
| 75 |
addOtherKey.setAlignmentX(0); |
|
| 76 |
removeOtherKey.setAlignmentX(0); |
|
| 77 |
choixModeConversion.setAlignmentX(0); |
|
| 78 |
// Fermeture de la fenêtre |
|
| 79 |
setDefaultCloseOperation(JFrame.DO_NOTHING_ON_CLOSE); |
|
| 80 |
addWindowListener(new WindowAdapter() {
|
|
| 81 |
@Override |
|
| 82 |
public void windowClosing(WindowEvent evt) {
|
|
| 83 |
fermerFenetre(); |
|
| 84 |
} |
|
| 85 |
}); |
|
| 86 |
initVide(); |
|
| 87 |
} |
|
| 88 |
public void initVide(){
|
|
| 89 |
PanneauCommande.removeAll(); |
|
| 90 |
choixModeConversion.setListData(sourcesPossibles); |
|
| 91 |
} |
|
| 92 |
public void actionPerformed(ActionEvent evt) {
|
|
| 93 |
try {
|
|
| 94 |
if(choixModeConversion.isSelectionEmpty()){
|
|
| 95 |
initVide(); |
|
| 96 |
return; |
|
| 97 |
} |
|
| 98 |
else{
|
|
| 99 |
switch(choixModeConversion.getSelectedIndex()){
|
|
| 100 |
case 0 : |
|
| 101 |
if(evt.getSource().equals(typeSource)){
|
|
| 102 |
primaryKeyDisponibles = vue.getListeChamps(Relation.class, typeSource.getSelection()); |
|
| 103 |
primaryKey.removeActionListener(this); |
|
| 104 |
primaryKey.setModele(primaryKeyDisponibles.toArray(new String[0])); |
|
| 105 |
primaryKey.addActionListener(this); |
|
| 106 |
return; |
|
| 107 |
} |
|
| 108 |
if(evt.getSource().equals(primaryKey)){
|
|
| 109 |
return; |
|
| 110 |
} |
|
| 111 |
if(evt.getSource().equals(lancerConversion)){
|
|
| 112 |
if(!typeSource.pasdeSelection() && !primaryKey.pasdeSelection()){
|
|
| 113 |
ChaineUtil.conversion("Relation",nomSchema.getText(),typeSource.getSelection(),
|
|
| 114 |
primaryKey.getSelection(),null,vue); |
|
| 115 |
fermerFenetre(); |
|
| 116 |
} |
|
| 117 |
return; |
|
| 118 |
} |
|
| 119 |
break; |
|
| 120 |
case 1 : |
|
| 121 |
if(evt.getSource().equals(lancerConversion)){
|
|
| 122 |
ChaineUtil.conversion("typeUnite",nomSchema.getText(),null,null,new String[0],vue);
|
|
| 123 |
fermerFenetre(); |
|
| 124 |
return; |
|
| 125 |
} |
|
| 126 |
break; |
|
| 127 |
case 2 : |
|
| 128 |
if(evt.getSource().equals(typeSource)){
|
|
| 129 |
if(!typeSource.pasdeSelection()){
|
|
| 130 |
primaryKeyDisponibles = vue.getListeChamps(Unite.class, typeSource.getSelection()); |
|
| 131 |
primaryKey.removeActionListener(this); |
|
| 132 |
primaryKey.setModele(primaryKeyDisponibles.toArray(new String[0])); |
|
| 133 |
primaryKey.addActionListener(this); |
|
| 134 |
otherKeyDisponibles = vue.getListeChamps(Unite.class, typeSource.getSelection()); |
|
| 135 |
addOtherKey.removeActionListener(this); |
|
| 136 |
addOtherKey.setModele(otherKeyDisponibles.toArray(new String[0])); |
|
| 137 |
addOtherKey.addActionListener(this); |
|
| 138 |
otherKeyAjoutees = new ArrayList(); |
|
| 139 |
removeOtherKey.removeActionListener(this); |
|
| 140 |
removeOtherKey.setModele(otherKeyAjoutees.toArray(new String[0])); |
|
| 141 |
removeOtherKey.addActionListener(this); |
|
| 142 |
} |
|
| 143 |
return; |
|
| 144 |
} |
|
| 145 |
if(evt.getSource().equals(primaryKey)){
|
|
| 146 |
if(!typeSource.pasdeSelection() && !primaryKey.pasdeSelection()){
|
|
| 147 |
otherKeyDisponibles = vue.getListeChamps(Unite.class, typeSource.getSelection()); |
|
| 148 |
otherKeyDisponibles.remove(primaryKey.getSelection()); |
|
| 149 |
for(String key : otherKeyAjoutees){
|
|
| 150 |
otherKeyDisponibles.remove(key); |
|
| 151 |
} |
|
| 152 |
otherKeyAjoutees.remove(primaryKey.getSelection()); |
|
| 153 |
addOtherKey.removeActionListener(this); |
|
| 154 |
removeOtherKey.removeActionListener(this); |
|
| 155 |
addOtherKey.setModele(otherKeyDisponibles.toArray(new String[0])); |
|
| 156 |
removeOtherKey.setModele(otherKeyAjoutees.toArray(new String[0])); |
|
| 157 |
addOtherKey.addActionListener(this); |
|
| 158 |
removeOtherKey.addActionListener(this); |
|
| 159 |
} |
|
| 160 |
return; |
|
| 161 |
} |
|
| 162 |
if(evt.getSource().equals(lancerConversion)){
|
|
| 163 |
if(!typeSource.pasdeSelection() && !primaryKey.pasdeSelection()){
|
|
| 164 |
ChaineUtil.conversion("attributUnite",nomSchema.getText(),typeSource.getSelection(),
|
|
| 165 |
primaryKey.getSelection(),otherKeyAjoutees.toArray(new String[0]),vue); |
|
| 166 |
fermerFenetre(); |
|
| 167 |
} |
|
| 168 |
return; |
|
| 169 |
} |
|
| 170 |
if(evt.getSource().equals(addOtherKey)){
|
|
| 171 |
if(!typeSource.pasdeSelection() && !addOtherKey.pasdeSelection()){
|
|
| 172 |
otherKeyDisponibles.remove(addOtherKey.getSelection()); |
|
| 173 |
otherKeyAjoutees.add(addOtherKey.getSelection()); |
|
| 174 |
addOtherKey.removeActionListener(this); |
|
| 175 |
removeOtherKey.removeActionListener(this); |
|
| 176 |
addOtherKey.setModele(otherKeyDisponibles.toArray(new String[0])); |
|
| 177 |
removeOtherKey.setModele(otherKeyAjoutees.toArray(new String[0])); |
|
| 178 |
addOtherKey.addActionListener(this); |
|
| 179 |
removeOtherKey.addActionListener(this); |
|
| 180 |
} |
|
| 181 |
return; |
|
| 182 |
} |
|
| 183 |
if(evt.getSource().equals(removeOtherKey)){
|
|
| 184 |
if(!typeSource.pasdeSelection() && !removeOtherKey.pasdeSelection()){
|
|
| 185 |
otherKeyDisponibles.add(removeOtherKey.getSelection()); |
|
| 186 |
otherKeyAjoutees.remove(removeOtherKey.getSelection()); |
|
| 187 |
addOtherKey.removeActionListener(this); |
|
| 188 |
removeOtherKey.removeActionListener(this); |
|
| 189 |
addOtherKey.setModele(otherKeyDisponibles.toArray(new String[0])); |
|
| 190 |
removeOtherKey.setModele(otherKeyAjoutees.toArray(new String[0])); |
|
| 191 |
addOtherKey.addActionListener(this); |
|
| 192 |
removeOtherKey.addActionListener(this); |
|
| 193 |
} |
|
| 194 |
return; |
|
| 195 |
} |
|
| 196 |
break; |
|
| 197 |
default : |
|
| 198 |
initVide(); |
|
| 199 |
break; |
|
| 200 |
|
|
| 201 |
} |
|
| 202 |
|
|
| 203 |
} |
|
| 204 |
throw new UnsupportedOperationException("Evénement non prévu : "+evt.paramString());
|
|
| 205 |
} catch (Throwable ex) {
|
|
| 206 |
GMessages.erreurFatale(ex); |
|
| 207 |
} |
|
| 208 |
} |
|
| 209 |
|
|
| 210 |
private void fermerFenetre() {
|
|
| 211 |
vue.removeEventListener(this); |
|
| 212 |
dispose(); |
|
| 213 |
} |
|
| 214 |
public void traiterEvent(Message evt) { // très grossier : à améliorer
|
|
| 215 |
switch (evt.getType()) {
|
|
| 216 |
case CLEAR_CORPUS: |
|
| 217 |
fermerFenetre(); |
|
| 218 |
return; |
|
| 219 |
case NEW_CORPUS: // impossible en principe : CLEAR_CORPUS a détruit la fenêtre |
|
| 220 |
throw new UnsupportedOperationException("Fenêtre chaines présente lors d'un message NEW_CORPUS ???");
|
|
| 221 |
case MODIF_TEXTE: |
|
| 222 |
fermerFenetre(); |
|
| 223 |
return; |
|
| 224 |
case MODIF_VUE: |
|
| 225 |
fermerFenetre(); |
|
| 226 |
return; |
|
| 227 |
case MODIF_STRUCTURE: |
|
| 228 |
fermerFenetre(); |
|
| 229 |
return; |
|
| 230 |
case MODIF_ELEMENT: |
|
| 231 |
// ElementEvent evtE = (ElementEvent) evt; |
|
| 232 |
// if (evtE.getModif() != TypeModifElement.BORNES_UNITE) fermerFenetre(); |
|
| 233 |
fermerFenetre(); |
|
| 234 |
return; |
|
| 235 |
case CORPUS_SAVED: |
|
| 236 |
fermerFenetre(); |
|
| 237 |
return; |
|
| 238 |
default: |
|
| 239 |
throw new UnsupportedOperationException("Cas "+evt.getType()+" oublié dans un switch");
|
|
| 240 |
} |
|
| 241 |
} |
|
| 242 |
public void listAction(int Index){
|
|
| 243 |
if(!choixModeConversion.isSelectionEmpty()){
|
|
| 244 |
PanneauCommande.removeAll(); |
|
| 245 |
PanneauCommande.add(Box.createVerticalStrut(20)); |
|
| 246 |
PanneauCommande.add(new JLabel("Saisisez un nom pour votre nouveau type de schéma :"));
|
|
| 247 |
nomSchema.setMaximumSize(new Dimension(500,50)); |
|
| 248 |
PanneauCommande.add(Box.createVerticalStrut(20)); |
|
| 249 |
PanneauCommande.add(nomSchema); |
|
| 250 |
switch(Index){
|
|
| 251 |
case 0 : |
|
| 252 |
PanneauCommande.add(Box.createVerticalStrut(20)); |
|
| 253 |
PanneauCommande.add(new JLabel("Sélectionner un type de relation :"));
|
|
| 254 |
PanneauCommande.add(Box.createVerticalStrut(20)); |
|
| 255 |
PanneauCommande.add(typeSource); |
|
| 256 |
PanneauCommande.add(Box.createVerticalStrut(20)); |
|
| 257 |
PanneauCommande.add(new JLabel("Sélectionner une propriété caractérisant chaque chaine :"));
|
|
| 258 |
PanneauCommande.add(Box.createVerticalStrut(20)); |
|
| 259 |
PanneauCommande.add(primaryKey); |
|
| 260 |
this.typesSourceDisponibles = vue.getTypesRelationsAVoir(); |
|
| 261 |
typeSource.removeActionListener(this); |
|
| 262 |
typeSource.setModele(typesSourceDisponibles); |
|
| 263 |
typeSource.addActionListener(this); |
|
| 264 |
this.primaryKeyDisponibles = new ArrayList(); |
|
| 265 |
primaryKey.removeActionListener(this); |
|
| 266 |
this.primaryKey.setModele(this.primaryKeyDisponibles.toArray(new String[0])); |
|
| 267 |
primaryKey.addActionListener(this); |
|
| 268 |
break; |
|
| 269 |
case 1: |
|
| 270 |
break; |
|
| 271 |
case 2 : |
|
| 272 |
PanneauCommande.add(Box.createVerticalStrut(20)); |
|
| 273 |
PanneauCommande.add(new JLabel("Sélectionner un type d'unité :"));
|
|
| 274 |
PanneauCommande.add(Box.createVerticalStrut(20)); |
|
| 275 |
PanneauCommande.add(typeSource); |
|
| 276 |
PanneauCommande.add(Box.createVerticalStrut(20)); |
|
| 277 |
PanneauCommande.add(new JLabel("Sélectionner une propriété caractérisant chaque chaine :"));
|
|
| 278 |
PanneauCommande.add(Box.createVerticalStrut(20)); |
|
| 279 |
PanneauCommande.add(primaryKey); |
|
| 280 |
PanneauCommande.add(Box.createVerticalStrut(20)); |
|
| 281 |
PanneauCommande.add(new JLabel("Sélectionner une propriété des unités à ajouter aux schémas :"));
|
|
| 282 |
PanneauCommande.add(Box.createVerticalStrut(20)); |
|
| 283 |
PanneauCommande.add(addOtherKey); |
|
| 284 |
PanneauCommande.add(Box.createVerticalStrut(20)); |
|
| 285 |
PanneauCommande.add(new JLabel("Sélectionner une propriété des unités à enlever aux schemas :"));
|
|
| 286 |
PanneauCommande.add(Box.createVerticalStrut(20)); |
|
| 287 |
PanneauCommande.add(removeOtherKey); |
|
| 288 |
this.typesSourceDisponibles = vue.getTypesUnitesAVoir(); |
|
| 289 |
typeSource.removeActionListener(this); |
|
| 290 |
typeSource.setModele(typesSourceDisponibles); |
|
| 291 |
typeSource.addActionListener(this); |
|
| 292 |
primaryKey.removeActionListener(this); |
|
| 293 |
this.primaryKeyDisponibles = new ArrayList(); |
|
| 294 |
this.primaryKey.setModele(this.primaryKeyDisponibles.toArray(new String[0])); |
|
| 295 |
primaryKey.addActionListener(this); |
|
| 296 |
this.otherKeyDisponibles = new ArrayList(); |
|
| 297 |
addOtherKey.removeActionListener(this); |
|
| 298 |
this.addOtherKey.setModele(this.otherKeyDisponibles.toArray(new String[0])); |
|
| 299 |
addOtherKey.addActionListener(this); |
|
| 300 |
this.otherKeyAjoutees = new ArrayList(); |
|
| 301 |
removeOtherKey.removeActionListener(this); |
|
| 302 |
this.removeOtherKey.setModele(this.otherKeyAjoutees.toArray(new String[0])); |
|
| 303 |
removeOtherKey.addActionListener(this); |
|
| 304 |
break; |
|
| 305 |
default : |
|
| 306 |
PanneauCommande.removeAll(); |
|
| 307 |
break; |
|
| 308 |
} |
|
| 309 |
revalidate(); |
|
| 310 |
repaint(); |
|
| 311 |
} |
|
| 312 |
} |
|
| 313 |
|
|
| 314 |
|
|
| 24 |
public class VisuConversion extends JFrame implements VueListener, ActionListener {
|
|
| 25 |
|
|
| 26 |
private Box PanneauCommande = Box.createVerticalBox(); |
|
| 27 |
|
|
| 28 |
private Box PanneauCommandeSource = Box.createVerticalBox(); |
|
| 29 |
|
|
| 30 |
private Vue vue; |
|
| 31 |
|
|
| 32 |
private PanneauEditeur panneauEditeur; |
|
| 33 |
|
|
| 34 |
private JList choixModeConversion = new JList(); |
|
| 35 |
|
|
| 36 |
private JButton lancerConversion = new JButton("Convertir");
|
|
| 37 |
|
|
| 38 |
private JTextField nomSchema = new JTextField("Chaine de coréférence");
|
|
| 39 |
|
|
| 40 |
private Val0ComboBox typeSource = new Val0ComboBox("Rien");
|
|
| 41 |
|
|
| 42 |
private Val0ComboBox primaryKey = new Val0ComboBox("Rien");
|
|
| 43 |
|
|
| 44 |
private String[] otherKey = new String[0]; |
|
| 45 |
|
|
| 46 |
private Val0ComboBox addOtherKey = new Val0ComboBox("Rien");
|
|
| 47 |
|
|
| 48 |
private Val0ComboBox removeOtherKey = new Val0ComboBox("Rien");
|
|
| 49 |
|
|
| 50 |
private String[] sourcesPossibles = new String[] { "Type de Relation", "Type d'unité", "Propriété d'unité" };
|
|
| 51 |
|
|
| 52 |
private String[] typesSourceDisponibles = new String[0]; |
|
| 53 |
|
|
| 54 |
private ArrayList<String> primaryKeyDisponibles = new ArrayList(); |
|
| 55 |
|
|
| 56 |
private ArrayList<String> otherKeyDisponibles = new ArrayList<>(); |
|
| 57 |
|
|
| 58 |
private ArrayList<String> otherKeyAjoutees = new ArrayList(); |
|
| 59 |
|
|
| 60 |
public VisuConversion(Container fenetre, Vue vue, PanneauEditeur pEditeur) {
|
|
| 61 |
super("Conversion de données en schéma");
|
|
| 62 |
Point pos = new Point(fenetre.getX() + 20, fenetre.getY() + 20); |
|
| 63 |
Dimension dim = new Dimension(700, 500); |
|
| 64 |
setLocation(pos); |
|
| 65 |
setSize(dim); |
|
| 66 |
this.vue = vue; |
|
| 67 |
vue.addEventListener(this); |
|
| 68 |
this.panneauEditeur = pEditeur; |
|
| 69 |
choixModeConversion.addMouseListener(new MouseAdapter() {
|
|
| 70 |
|
|
| 71 |
@Override |
|
| 72 |
public void mousePressed(MouseEvent e) {// on gère les évènements de la souris
|
|
| 73 |
check(e); |
|
| 74 |
} |
|
| 75 |
|
|
| 76 |
@Override |
|
| 77 |
public void mouseReleased(MouseEvent e) {
|
|
| 78 |
// check(e); |
|
| 79 |
} |
|
| 80 |
|
|
| 81 |
public void check(MouseEvent e) {
|
|
| 82 |
if (!e.isPopupTrigger()) {// si on a un clique gauche sur la liste
|
|
| 83 |
listAction(choixModeConversion.getSelectedIndex()); |
|
| 84 |
} |
|
| 85 |
} |
|
| 86 |
}); |
|
| 87 |
lancerConversion.addActionListener(this); |
|
| 88 |
PanneauCommandeSource.add(Box.createVerticalStrut(20)); |
|
| 89 |
PanneauCommandeSource.add(new JLabel("Choix de la source de donnée :"));
|
|
| 90 |
PanneauCommandeSource.add(Box.createVerticalStrut(20)); |
|
| 91 |
PanneauCommandeSource.add(choixModeConversion); |
|
| 92 |
PanneauCommandeSource.add(Box.createVerticalStrut(20)); |
|
| 93 |
PanneauCommandeSource.add(lancerConversion); |
|
| 94 |
JSplitPane split = new JSplitPane(JSplitPane.HORIZONTAL_SPLIT, PanneauCommandeSource, PanneauCommande); |
|
| 95 |
getContentPane().add(split); |
|
| 96 |
split.setDividerLocation(1. / 3); |
|
| 97 |
setVisible(true); |
|
| 98 |
typeSource.setAlignmentX(0); |
|
| 99 |
primaryKey.setAlignmentX(0); |
|
| 100 |
addOtherKey.setAlignmentX(0); |
|
| 101 |
removeOtherKey.setAlignmentX(0); |
|
| 102 |
choixModeConversion.setAlignmentX(0); |
|
| 103 |
// Fermeture de la fenêtre |
|
| 104 |
setDefaultCloseOperation(JFrame.DO_NOTHING_ON_CLOSE); |
|
| 105 |
addWindowListener(new WindowAdapter() {
|
|
| 106 |
|
|
| 107 |
@Override |
|
| 108 |
public void windowClosing(WindowEvent evt) {
|
|
| 109 |
fermerFenetre(); |
|
| 110 |
} |
|
| 111 |
}); |
|
| 112 |
initVide(); |
|
| 113 |
} |
|
| 114 |
|
|
| 115 |
public void initVide() {
|
|
| 116 |
PanneauCommande.removeAll(); |
|
| 117 |
choixModeConversion.setListData(sourcesPossibles); |
|
| 118 |
} |
|
| 119 |
|
|
| 120 |
@Override |
|
| 121 |
public void actionPerformed(ActionEvent evt) {
|
|
| 122 |
try {
|
|
| 123 |
if (choixModeConversion.isSelectionEmpty()) {
|
|
| 124 |
initVide(); |
|
| 125 |
return; |
|
| 126 |
} |
|
| 127 |
else {
|
|
| 128 |
switch (choixModeConversion.getSelectedIndex()) {
|
|
| 129 |
case 0: |
|
| 130 |
if (evt.getSource().equals(typeSource)) {
|
|
| 131 |
primaryKeyDisponibles = vue.getListeChamps(Relation.class, typeSource.getSelection()); |
|
| 132 |
primaryKey.removeActionListener(this); |
|
| 133 |
primaryKey.setModele(primaryKeyDisponibles.toArray(new String[0])); |
|
| 134 |
primaryKey.addActionListener(this); |
|
| 135 |
return; |
|
| 136 |
} |
|
| 137 |
if (evt.getSource().equals(primaryKey)) {
|
|
| 138 |
return; |
|
| 139 |
} |
|
| 140 |
if (evt.getSource().equals(lancerConversion)) {
|
|
| 141 |
if (!typeSource.pasdeSelection() && !primaryKey.pasdeSelection()) {
|
|
| 142 |
ChaineUtil.conversion("Relation", nomSchema.getText(), typeSource.getSelection(),
|
|
| 143 |
primaryKey.getSelection(), null, vue); |
|
| 144 |
fermerFenetre(); |
|
| 145 |
} |
|
| 146 |
return; |
|
| 147 |
} |
|
| 148 |
break; |
|
| 149 |
case 1: |
|
| 150 |
if (evt.getSource().equals(lancerConversion)) {
|
|
| 151 |
ChaineUtil.conversion("typeUnite", nomSchema.getText(), null, null, new String[0], vue);
|
|
| 152 |
fermerFenetre(); |
|
| 153 |
return; |
|
| 154 |
} |
|
| 155 |
break; |
|
| 156 |
case 2: |
|
| 157 |
if (evt.getSource().equals(typeSource)) {
|
|
| 158 |
if (!typeSource.pasdeSelection()) {
|
|
| 159 |
primaryKeyDisponibles = vue.getListeChamps(Unite.class, typeSource.getSelection()); |
|
| 160 |
primaryKey.removeActionListener(this); |
|
| 161 |
primaryKey.setModele(primaryKeyDisponibles.toArray(new String[0])); |
|
| 162 |
primaryKey.addActionListener(this); |
|
| 163 |
otherKeyDisponibles = vue.getListeChamps(Unite.class, typeSource.getSelection()); |
|
| 164 |
addOtherKey.removeActionListener(this); |
|
| 165 |
addOtherKey.setModele(otherKeyDisponibles.toArray(new String[0])); |
|
| 166 |
addOtherKey.addActionListener(this); |
|
| 167 |
otherKeyAjoutees = new ArrayList(); |
|
| 168 |
removeOtherKey.removeActionListener(this); |
|
| 169 |
removeOtherKey.setModele(otherKeyAjoutees.toArray(new String[0])); |
|
| 170 |
removeOtherKey.addActionListener(this); |
|
| 171 |
} |
|
| 172 |
return; |
|
| 173 |
} |
|
| 174 |
if (evt.getSource().equals(primaryKey)) {
|
|
| 175 |
if (!typeSource.pasdeSelection() && !primaryKey.pasdeSelection()) {
|
|
| 176 |
otherKeyDisponibles = vue.getListeChamps(Unite.class, typeSource.getSelection()); |
|
| 177 |
otherKeyDisponibles.remove(primaryKey.getSelection()); |
|
| 178 |
for (String key : otherKeyAjoutees) {
|
|
| 179 |
otherKeyDisponibles.remove(key); |
|
| 180 |
} |
|
| 181 |
otherKeyAjoutees.remove(primaryKey.getSelection()); |
|
| 182 |
addOtherKey.removeActionListener(this); |
|
| 183 |
removeOtherKey.removeActionListener(this); |
|
| 184 |
addOtherKey.setModele(otherKeyDisponibles.toArray(new String[0])); |
|
| 185 |
removeOtherKey.setModele(otherKeyAjoutees.toArray(new String[0])); |
|
| 186 |
addOtherKey.addActionListener(this); |
|
| 187 |
removeOtherKey.addActionListener(this); |
|
| 188 |
} |
|
| 189 |
return; |
|
| 190 |
} |
|
| 191 |
if (evt.getSource().equals(lancerConversion)) {
|
|
| 192 |
if (!typeSource.pasdeSelection() && !primaryKey.pasdeSelection()) {
|
|
| 193 |
ChaineUtil.conversion("attributUnite", nomSchema.getText(), typeSource.getSelection(),
|
|
| 194 |
primaryKey.getSelection(), otherKeyAjoutees.toArray(new String[0]), vue); |
|
| 195 |
fermerFenetre(); |
|
| 196 |
} |
|
| 197 |
return; |
|
| 198 |
} |
|
| 199 |
if (evt.getSource().equals(addOtherKey)) {
|
|
| 200 |
if (!typeSource.pasdeSelection() && !addOtherKey.pasdeSelection()) {
|
|
| 201 |
otherKeyDisponibles.remove(addOtherKey.getSelection()); |
|
| 202 |
otherKeyAjoutees.add(addOtherKey.getSelection()); |
|
| 203 |
addOtherKey.removeActionListener(this); |
|
| 204 |
removeOtherKey.removeActionListener(this); |
|
| 205 |
addOtherKey.setModele(otherKeyDisponibles.toArray(new String[0])); |
|
| 206 |
removeOtherKey.setModele(otherKeyAjoutees.toArray(new String[0])); |
|
| 207 |
addOtherKey.addActionListener(this); |
|
| 208 |
removeOtherKey.addActionListener(this); |
|
| 209 |
} |
|
| 210 |
return; |
|
| 211 |
} |
|
| 212 |
if (evt.getSource().equals(removeOtherKey)) {
|
|
| 213 |
if (!typeSource.pasdeSelection() && !removeOtherKey.pasdeSelection()) {
|
|
| 214 |
otherKeyDisponibles.add(removeOtherKey.getSelection()); |
|
| 215 |
otherKeyAjoutees.remove(removeOtherKey.getSelection()); |
|
| 216 |
addOtherKey.removeActionListener(this); |
|
| 217 |
removeOtherKey.removeActionListener(this); |
|
| 218 |
addOtherKey.setModele(otherKeyDisponibles.toArray(new String[0])); |
|
| 219 |
removeOtherKey.setModele(otherKeyAjoutees.toArray(new String[0])); |
|
| 220 |
addOtherKey.addActionListener(this); |
|
| 221 |
removeOtherKey.addActionListener(this); |
|
| 222 |
} |
|
| 223 |
return; |
|
| 224 |
} |
|
| 225 |
break; |
|
| 226 |
default: |
|
| 227 |
initVide(); |
|
| 228 |
break; |
|
| 229 |
|
|
| 230 |
} |
|
| 231 |
|
|
| 232 |
} |
|
| 233 |
throw new UnsupportedOperationException("Evénement non prévu : " + evt.paramString());
|
|
| 234 |
} |
|
| 235 |
catch (Throwable ex) {
|
|
| 236 |
GMessages.erreurFatale(ex); |
|
| 237 |
} |
|
| 238 |
} |
|
| 239 |
|
|
| 240 |
private void fermerFenetre() {
|
|
| 241 |
vue.removeEventListener(this); |
|
| 242 |
dispose(); |
|
| 243 |
} |
|
| 244 |
|
|
| 245 |
@Override |
|
| 246 |
public void traiterEvent(Message evt) { // très grossier : à améliorer
|
|
| 247 |
switch (evt.getType()) {
|
|
| 248 |
case CLEAR_CORPUS: |
|
| 249 |
fermerFenetre(); |
|
| 250 |
return; |
|
| 251 |
case NEW_CORPUS: // impossible en principe : CLEAR_CORPUS a détruit la fenêtre |
|
| 252 |
throw new UnsupportedOperationException("Fenêtre chaines présente lors d'un message NEW_CORPUS ???");
|
|
| 253 |
case MODIF_TEXTE: |
|
| 254 |
fermerFenetre(); |
|
| 255 |
return; |
|
| 256 |
case MODIF_VUE: |
|
| 257 |
fermerFenetre(); |
|
| 258 |
return; |
|
| 259 |
case MODIF_STRUCTURE: |
|
| 260 |
fermerFenetre(); |
|
| 261 |
return; |
|
| 262 |
case MODIF_ELEMENT: |
|
| 263 |
// ElementEvent evtE = (ElementEvent) evt; |
|
| 264 |
// if (evtE.getModif() != TypeModifElement.BORNES_UNITE) fermerFenetre(); |
|
| 265 |
fermerFenetre(); |
|
| 266 |
return; |
|
| 267 |
case CORPUS_SAVED: |
|
| 268 |
fermerFenetre(); |
|
| 269 |
return; |
|
| 270 |
default: |
|
| 271 |
throw new UnsupportedOperationException("Cas " + evt.getType() + " oublié dans un switch");
|
|
| 272 |
} |
|
| 273 |
} |
|
| 274 |
|
|
| 275 |
public void listAction(int Index) {
|
|
| 276 |
if (!choixModeConversion.isSelectionEmpty()) {
|
|
| 277 |
PanneauCommande.removeAll(); |
|
| 278 |
PanneauCommande.add(Box.createVerticalStrut(20)); |
|
| 279 |
PanneauCommande.add(new JLabel("Saisisez un nom pour votre nouveau type de schéma :"));
|
|
| 280 |
nomSchema.setMaximumSize(new Dimension(500, 50)); |
|
| 281 |
PanneauCommande.add(Box.createVerticalStrut(20)); |
|
| 282 |
PanneauCommande.add(nomSchema); |
|
Formats disponibles : Unified diff