@Override public void setUp() throws Exception { // Get a new topic map object from the factory. factory = getFactory(); topicmapRef = factory.makeTopicMapReference(); listener = new TesterListener(); TopicMapEvents.addTopicListener(topicmapRef, listener); topicmap = topicmapRef.createStore(false).getTopicMap(); // Get the builder of that topic map. builder = topicmap.getBuilder(); }
@Override protected void setUp() throws Exception { factory = getFactory(); // Get a new topic map object from the factory. topicmapRef = factory.makeTopicMapReference(); topicmap = topicmapRef.createStore(false).getTopicMap(); assertTrue("Null topic map!" , topicmap != null); // Get the builder of that topic map. builder = topicmap.getBuilder(); assertTrue("Null builder!", builder != null); }
@Override public void setUp() throws Exception { // get a new topic map object from the factory. factory = getFactory(); topicmapRef = factory.makeTopicMapReference(); listener = new TesterListener(); TopicMapEvents.addTopicListener(topicmapRef, listener); // load topic map topicmap = topicmapRef.createStore(false).getTopicMap(); ImportExportUtils.getReader(TestFileUtils.getTestInputFile("various", "bart.ltm")).importInto(topicmap); topicmap.getStore().commit(); // get the builder of that topic map. builder = topicmap.getBuilder(); // get test topic bart = topicmap.getTopicBySubjectIdentifier(URILocator.create("test:bart")); }
@Override public void setUp() throws Exception { // get a new topic map object from the factory. factory = getFactory(); try { topicmapRef = factory.makeTopicMapReference(); listener = new EventListener(); TopicMapEvents.addTopicListener(topicmapRef, listener); // load topic map topicmap = topicmapRef.createStore(false).getTopicMap(); ImportExportUtils.getReader(TestFileUtils.getTestInputFile("various", "alumni.xtm")).importInto(topicmap); topicmap.getStore().commit(); // get the builder of that topic map. builder = topicmap.getBuilder(); // clean up the listener listener.reset(); } catch (java.io.IOException e) { throw new OntopiaRuntimeException(e); } }
topicmapRef = factory.makeTopicMapReference(); listener = new TesterListener(); try {