Revision 2144 tmp/org.txm.analec.rcp/src/org/txm/macro/urs/exploit/UnitsListMacro.groovy

UnitsListMacro.groovy (revision 2144)
72 72
def allResults = [:]
73 73
for (def corpus : selection) {
74 74

  
75
	mainCorpus = corpus.getMainCorpus()
75
	def word = corpus.getWordProperty()
76
	def analecCorpus = URSCorpora.getCorpus(corpus)
76 77

  
77
	def word = mainCorpus.getWordProperty()
78
	def analecCorpus = URSCorpora.getCorpus(mainCorpus)
79

  
80 78
	def selectedUnits = AnalecUtils.selectUnitsInSchema(debug, analecCorpus, corpus, schema_ursql, minimum_schema_size, maximum_schema_size,
81 79
			unit_ursql, position_in_schema, cql_limit, strict_inclusion, position_in_matches);
82 80

  
......
87 85

  
88 86
if (output_mode == "FORMATED") {
89 87
	for (def corpus : allResults.keySet()) {
90
		def mainCorpus = corpus.getMainCorpus()
91
		def word = mainCorpus.getWordProperty()
88
		def word = corpus.getWordProperty()
92 89
		def selectedUnits = allResults[corpus]
93 90
		println "$corpus units: "+selectedUnits.size()
94 91
		def n = 1
......
105 102
	}
106 103
} else if (output_mode == "TABULATED") {
107 104
	for (def corpus : allResults.keySet()) {
108
		def mainCorpus = corpus.getMainCorpus()
109
		def word = mainCorpus.getWordProperty()
105
		def word = corpus.getWordProperty()
110 106
		def selectedUnits = allResults[corpus]
111 107
		println "$corpus units: "+selectedUnits.size()
112 108
		def n = 1

Also available in: Unified diff