@Override public List<String> getMMTConstants() { List<String> result = new ArrayList<String>(); info.kwarc.mmt.api.ontology.IsConstant$ t = info.kwarc.mmt.api.ontology.IsConstant$.MODULE$; for (Path p : JavaConversions.asJavaCollection(controller.depstore().getInds(t).toList())) { result.add(p.toPath()); } return result; }
@Override public List<String> getMMTTheories() { List<String> result = new ArrayList<String>(); info.kwarc.mmt.api.ontology.IsTheory$ t = info.kwarc.mmt.api.ontology.IsTheory$.MODULE$; for (Path p : JavaConversions.asJavaCollection(controller.depstore().getInds(t).toList())) { result.add(p.toPath()); } return result; }
public void startAdminHttpService() { try { Properties properties = new Properties(); properties.load(this.getClass().getResource("build.properties").openStream()); LOG.info("build.properties build_revision: {}", properties.getProperty("build_revision", "unknown")); } catch (Throwable t) { LOG.warn("Failed to load properties from build.properties", t); } Duration[] defaultLatchIntervals = {Duration.apply(1, TimeUnit.MINUTES)}; Iterator<Duration> durationIterator = Arrays.asList(defaultLatchIntervals).iterator(); @SuppressWarnings("deprecation") AdminServiceFactory adminServiceFactory = new AdminServiceFactory( this.port, 20, List$.MODULE$.empty(), Option.empty(), List$.MODULE$.empty(), Map$.MODULE$.empty(), JavaConversions.asScalaIterator(durationIterator).toList()); RuntimeEnvironment runtimeEnvironment = new RuntimeEnvironment(this); AdminHttpService service = adminServiceFactory.apply(runtimeEnvironment); for (Map.Entry<String, CustomHttpHandler> entry : this.customHttpHandlerMap.entrySet()) { service.httpServer().createContext(entry.getKey(), entry.getValue()); } }
public void startAdminHttpService() { try { Properties properties = new Properties(); properties.load(this.getClass().getResource("build.properties").openStream()); LOG.info("build.properties build_revision: {}", properties.getProperty("build_revision", "unknown")); } catch (Throwable t) { LOG.warn("Failed to load properties from build.properties", t); } Duration[] defaultLatchIntervals = {Duration.apply(1, TimeUnit.MINUTES)}; Iterator<Duration> durationIterator = Arrays.asList(defaultLatchIntervals).iterator(); @SuppressWarnings("deprecation") AdminServiceFactory adminServiceFactory = new AdminServiceFactory( this.port, 20, List$.MODULE$.empty(), Option.empty(), List$.MODULE$.empty(), Map$.MODULE$.empty(), JavaConversions.asScalaIterator(durationIterator).toList()); RuntimeEnvironment runtimeEnvironment = new RuntimeEnvironment(this); AdminHttpService service = adminServiceFactory.apply(runtimeEnvironment); for (Map.Entry<String, CustomHttpHandler> entry : this.customHttpHandlerMap.entrySet()) { service.httpServer().createContext(entry.getKey(), entry.getValue()); } }