Package org.locationtech.udig.catalog

Examples of org.locationtech.udig.catalog.IServiceFactory.createService()


        // add the service to the catalog
        IServiceFactory sFactory = CatalogPlugin.getDefault().getServiceFactory();
        ICatalog catalog = CatalogPlugin.getDefault().getLocalCatalog();
        URL url = URLUtils.fileToURL(file);
        List<IService> services = sFactory.createService(url);
        monitor.beginTask("add to catalog", services.size() * 10);
        for( IService service : services ) {
            IService registeredService = catalog.add(service);
            SubProgressMonitor monitor2 = new SubProgressMonitor(monitor, 10);
            List<IGeoResource> contents = (List<IGeoResource>) registeredService.resources(monitor2);
View Full Code Here


      = CatalogPlugin.getDefault().getServiceFactory();
   
    HashMap<String, Serializable> map = new HashMap<String, Serializable>();
    map.put("dummy", DummyService.url); //$NON-NLS-1$
   
    List<IService> services = sFactory.createService(map);
    service = services.get(0);
//        catalog.add(service);
  }
 
  @SuppressWarnings("unchecked")
View Full Code Here

        Collection<IService> services = new HashSet<IService>();
        if (urls != null && !urls.isEmpty()) {       
            for( URL url : urls ) {
                Collection<IService> searchResult = searchLocalCatalog(url, monitor);
                if (searchResult.isEmpty()) {
                    List<IService> created = sFactory.createService(url);
                    services.addAll(created);
                } else {
                    services.addAll(searchResult);
                }
            }
View Full Code Here

        try {
            URL fileUrl = new File(serviceFile).toURI().toURL();
            // add the service to the catalog and map
            IServiceFactory sFactory = CatalogPlugin.getDefault().getServiceFactory();
            ICatalog catalog = CatalogPlugin.getDefault().getLocalCatalog();
            List<IService> services = sFactory.createService(fileUrl);
            for( IService service : services ) {
                catalog.add(service);
            }
        } catch (Exception e) {
            JGrassPlugin.log(
View Full Code Here

  @Ignore("Connection refused ..")
    @Test
    public void testMemoryDataStoreType() throws Exception {
        IServiceFactory serviceFactory = CatalogPlugin.getDefault().getServiceFactory();
        URL dragNdrop = new URL("http://localhost/scratch/TestNewFeatureTypeOp");
        List<IService> services = serviceFactory.createService(dragNdrop); //$NON-NLS-1$
       
        NewFeatureTypeOp op=new NewFeatureTypeOp();
        op.testingSetTesting(true);
        op.op(Display.getCurrent(), services.get(0), new NullProgressMonitor());
       
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.