Package org.locationtech.udig.catalog

Examples of org.locationtech.udig.catalog.IService


            }

            // usually only returns 1 service but it may be that multiple
            // Services know how to interpret the URL
            List<IService> services = CatalogPlugin.getDefault().getServiceFactory().createService(url);
            IService found = null;
            progressMonitor.worked(1);

            // find the service you want
            for (IService service : services) {
                // determine if the service is the type you are expecting;
View Full Code Here


    public List<IService> getResources( IProgressMonitor monitor ) throws Exception {
        if (!isPageComplete())
            return null;

        DB2ServiceExtension creator = new DB2ServiceExtension();
        IService service = creator.createService(null, getParams());
        service.getInfo(monitor); // load

        List<IService> servers = new ArrayList<IService>();
        servers.add(service);

        /*
 
View Full Code Here

        URL url = file.toURI().toURL();
       
        IProgressMonitor monitor = ProgressManager.instance().get();
       
        IRepository local = CatalogPlugin.getDefault().getLocal();
        IService service = local.acquire( url, monitor );       
    }
View Full Code Here

    IServiceFactory serviceFactory = CatalogPlugin.getDefault().getServiceFactory();
    List<IService> created = serviceFactory.createService( url );
   
    IRepository local = CatalogPlugin.getDefault().getLocal();
    for( IService service : created ){
        IService registered = local.add(service);
        //...
    }
  }
View Full Code Here

        //ensure the service was created
        assertNotNull(services);
        assertEquals(1, services.size() );
       
        //ensure the right type of service was created
        IService service = services.get(0);
        assertNotNull( service );
       
        ICatalog catalog = CatalogPlugin.getDefault().getLocalCatalog();
        catalog.add( service ); // we can now find this service!
       
        List<IResolve> found = catalog.search("csv",null, null );
        assertEquals( 2, found.size() );
       
        //get all the resources from the service
        List<? extends IGeoResource> resources = service.resources(null);
        assertNotNull(resources);
        assertEquals(resources.size(),1);
       
        CSV csv = null;
        for (IGeoResource resource : resources) {
View Full Code Here

    private void addItemData( Collection<IService> services, Object data ) {
        if (data instanceof WMTWizardTreeItemData) {
            WMTWizardTreeItemData itemData = (WMTWizardTreeItemData) data;

            IService service = itemData.getService();

            if (service != null) {
                services.add(service);
            }
        }
View Full Code Here

        URL location = new URL(url);
       
        WWServiceExtension creator = new WWServiceExtension();

        Map<String, Serializable> params = creator.createParams(location);
        IService service = creator.createService(location, params);
        service.getInfo(monitor); // load it

        List<IService> servers = new ArrayList<IService>();
        servers.add(service);

        /*
 
View Full Code Here

     */
    public boolean leavingPage() { 
        Collection<IService> services = getServices();
       
        for (IService service : services) {
            final IService runService = service;
           
            try {
                getContainer().run(false, true,
                        new IRunnableWithProgress(){

                            public void run(IProgressMonitor monitor)
                                    throws InvocationTargetException, InterruptedException {
                                monitor.beginTask(Messages.Wizard_WW_Connecting, IProgressMonitor.UNKNOWN);
               
                                // try to load the file
                                try {
                                    runService.members(monitor);
                                } catch (IOException e) {
                                    throw (InvocationTargetException) new InvocationTargetException(e, e.getLocalizedMessage());
                                   
                                }
                               
View Full Code Here

        URL location = new URL(url);
       
        WMSCServiceExtension creator = new WMSCServiceExtension();

        Map<String, Serializable> params = creator.createParams(location);
        IService service = creator.createService(location, params);
        service.getInfo(monitor); // load it

        List<IService> servers = new ArrayList<IService>();
        servers.add(service);

        /*
 
View Full Code Here

        WWServiceExtension serviceExtension = new WWServiceExtension();
       
        URL url = WWControl.class.getResource("DemisWorldMap.xml"); //$NON-NLS-1$
        Map<String, Serializable> params =  serviceExtension.createParams(url);
               
        IService service = serviceExtension.createService(url, params);
       
        return service;
    }
View Full Code Here

TOP

Related Classes of org.locationtech.udig.catalog.IService

Copyright © 2018 www.massapicom. 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.