43 lines
1.4 KiB
Java
43 lines
1.4 KiB
Java
|
import java.io.File;
|
||
|
|
||
|
import org.apache.commons.io.FileUtils;
|
||
|
import org.apache.commons.io.IOCase;
|
||
|
import org.apache.commons.io.filefilter.FileFilterUtils;
|
||
|
import org.apache.commons.io.filefilter.TrueFileFilter;
|
||
|
import org.junit.Test;
|
||
|
|
||
|
import data.*;
|
||
|
import javafx.collections.ObservableList;
|
||
|
|
||
|
public class CorpusTests {
|
||
|
|
||
|
@Test
|
||
|
public void solarTest() {
|
||
|
//File selectedDirectory = new File("/home/andrej/Desktop/corpus-analyzer/src/main/resources/Solar");
|
||
|
// File selectedDirectory = new File("/home/andrej/Desktop/corpus-analyzer/src/main/resources/GOS");
|
||
|
File selectedDirectory = new File("/home/andrej/Desktop/corpus-analyzer/src/main/resources/Gigafida_subset");
|
||
|
|
||
|
Settings.resultsFilePath = new File(selectedDirectory.getAbsolutePath().concat(File.separator));
|
||
|
|
||
|
Settings.corpus = FileUtils.listFiles(selectedDirectory, FileFilterUtils.suffixFileFilter("xml", IOCase.INSENSITIVE), TrueFileFilter.INSTANCE);
|
||
|
|
||
|
File f = Settings.corpus.iterator().next();
|
||
|
|
||
|
Statistics stats = new Statistics(AnalysisLevel.STRING_LEVEL, 2, 0, CalculateFor.WORD);
|
||
|
// stats.setCorpusType(CorpusType.GOS);
|
||
|
stats.setCorpusType(CorpusType.SOLAR);
|
||
|
|
||
|
// XML_processing.readXMLGos(f.toString(), stats);
|
||
|
// XML_processing.readXML(f.toString(), stats);
|
||
|
// XML_processing.readXMLHeaderTag(f.toString(), "stats");
|
||
|
|
||
|
}
|
||
|
|
||
|
@Test
|
||
|
public void test() {
|
||
|
ObservableList<String> var = GosTaxonomy.getForComboBox();
|
||
|
String debug = "";
|
||
|
|
||
|
}
|
||
|
}
|