Revision 479 tmp/org.txm.groovy.core/src/groovy/org/txm/macro/misc/TXM2CoNLL2009Macro.groovy

TXM2CoNLL2009Macro.groovy (revision 479)
5 5
import org.txm.searchengine.cqp.corpus.*
6 6
import org.kohsuke.args4j.*
7 7
import groovy.transform.Field
8
import org.txm.rcp.swt.widget.parameters.*
8
import org.txm.rcpapplication.swt.widget.parameters.*
9 9

  
10 10
if (!(corpusViewSelection instanceof Corpus)) {
11 11
	println "Select a corpus or a sub-corpus"
......
27 27

  
28 28
if (!ParametersDialog.open(this)) return;
29 29

  
30
outputFile = outputFile.getAbsoluteFile()
31

  
30 32
def split = sentenceProperty.split("_", 2)
31 33
StructuralUnitProperty s = corpus.getStructuralUnit(split[0]).getProperty(split[1])
32 34
Property word = corpus.getProperty("word")
......
40 42

  
41 43

  
42 44
ToCoNLL2009 processor = new ToCoNLL2009()
43
processor.process(outputFile, corpus, s, word, lemma, pos, encoding)
45
processor.process(outputFile, corpus, s, word, lemma, pos, encoding)
46

  
47
println "Done: $outputFile"

Also available in: Unified diff