Révision 2875
tmp/org.txm.annotation.kr.core/src/org/txm/annotation/kr/core/AnnotationWriter.java (revision 2875) | ||
---|---|---|
173 | 173 |
int currentText = 0; |
174 | 174 |
File currentXMLFile = new File(txmDirectory, textsIds.get(currentText) + ".xml"); |
175 | 175 |
|
176 |
// store first text |
|
177 |
currentXMLFile = new File(txmDirectory, textsIds.get(currentText) + ".xml"); |
|
178 | 176 |
textAnnotations = new ArrayList<Annotation>(); |
179 | 177 |
annotationsPerTexts.put(textsIds.get(currentText), textAnnotations); |
180 | 178 |
|
... | ... | |
190 | 188 |
} |
191 | 189 |
}); |
192 | 190 |
|
193 |
// group annotations per text |
|
191 |
// group annotations per text ; annotations are now sorted by position
|
|
194 | 192 |
for (Annotation currentAnnot : allCorpusAnnotations) { // parse all annotations |
195 | 193 |
// System.out.println(" Annotation: "+currentAnnot); |
196 | 194 |
int pos = currentAnnot.getPK().getEndPosition(); |
197 | 195 |
|
198 | 196 |
while (pos > end_limits[currentText]) { // while pos is not in the currentText.end |
199 | 197 |
currentText++; |
200 |
currentXMLFile = new File(txmDirectory, textsIds.get(currentText) + ".xml"); |
|
201 | 198 |
textAnnotations = new ArrayList<Annotation>(); |
202 | 199 |
annotationsPerTexts.put(textsIds.get(currentText), textAnnotations); |
203 | 200 |
} |
Formats disponibles : Unified diff