Package org.locationtech.udig.catalog

Examples of org.locationtech.udig.catalog.IResolveDelta


        if (!mapsetMembers.contains(resource)) {
            mapsetMembers.add(resource);

            ICatalog catalog = parent(null);
            if (catalog instanceof CatalogImpl) {
                IResolveDelta delta = new ResolveDelta(resource, Kind.ADDED);
                IResolveChangeEvent event = new ResolveChangeEvent(this, Type.POST_CHANGE, delta);
                ((CatalogImpl) catalog).fire(event);
            }
        }
        return resource;
View Full Code Here


            if (mapsetIdentifier.toExternalForm().equals(identifier.toExternalForm())) {
                mapsetMembers.remove(i);

                ICatalog catalog = parent(null);
                if (catalog instanceof CatalogImpl) {
                    IResolveDelta delta = new ResolveDelta(resource, Kind.REMOVED);
                    IResolveChangeEvent event = new ResolveChangeEvent(this, Type.POST_CHANGE, delta);
                    ((CatalogImpl) catalog).fire(event);
                }
                break;
            }
View Full Code Here

        if (!jgrassMapMembers.contains(resource)) {
            jgrassMapMembers.add(resource);

            ICatalog catalog = getService(null).parent(null);
            if (catalog instanceof CatalogImpl) {
                IResolveDelta delta = new ResolveDelta(resource, Kind.ADDED);
                IResolveChangeEvent event = new ResolveChangeEvent(this, Type.POST_CHANGE, delta);
                ((CatalogImpl) catalog).fire(event);
            }
        } else {
            try {
View Full Code Here

        if (jgrassMapMembers.contains(resource)) {
            jgrassMapMembers.remove(resource);

            ICatalog catalog = getService(null).parent(null);
            if (catalog instanceof CatalogImpl) {
                IResolveDelta delta = new ResolveDelta(resource, Kind.REMOVED);
                IResolveChangeEvent event = new ResolveChangeEvent(this, Type.POST_CHANGE, delta);
                ((CatalogImpl) catalog).fire(event);
            }
        }
        return resource;
View Full Code Here

     */
    public void changed( IResolveChangeEvent event ) {
        if (isEvaluating.get()){
            return;
        }
        IResolveDelta found = SearchIDDeltaVisitor.search( resourceId, event);
        if( found != null ){
            owner.notifyListeners(evaluationObject);
        }
        // Original code that only noticed changes *on* the IResolve, not the parent
        /*
 
View Full Code Here

        if (event.getType() != IResolveChangeEvent.Type.POST_CHANGE) {
            return;
        }

        IResolveDelta delta = event.getDelta();
        IResolve hit = event.getResolve();

        // Temporary solution while migrating to URI identifiers
        if (delta.getKind() == IResolveDelta.Kind.CHANGED && hit != null) {

            ID affected = hit.getID();
            ID id = getResourceID();
            if (id == null)
                return;
View Full Code Here

                }
            } finally {
                dsLock.unlock();
                monitor.done();
            }
            IResolveDelta delta = new ResolveDelta(this, IResolveDelta.Kind.CHANGED);
            ((CatalogImpl) CatalogPlugin.getDefault().getLocalCatalog())
                    .fire(new ResolveChangeEvent(this, IResolveChangeEvent.Type.POST_CHANGE, delta));
        }
        return ds;
    }
View Full Code Here

        }

        services.add(service);
        runInterceptor(service, ServiceInterceptor.ADDED_ID);
       
        IResolveDelta deltaAdded = new ResolveDelta(service, IResolveDelta.Kind.ADDED);
        IResolveDelta deltaChanged = new ResolveDelta(this, Collections.singletonList(deltaAdded));
        fire(new ResolveChangeEvent(CatalogImpl.this, IResolveChangeEvent.Type.POST_CHANGE,deltaChanged));
       
        return service;
    }
View Full Code Here

     */
    public void remove( IService entry ) throws UnsupportedOperationException {
        if (entry == null || entry.getIdentifier() == null){
            throw new NullPointerException("Cannot have a null id"); //$NON-NLS-1$
        }
        IResolveDelta deltaRemoved = new ResolveDelta(entry, IResolveDelta.Kind.REMOVED);
        IResolveDelta deltaChanged = new ResolveDelta(this, Collections.singletonList(deltaRemoved));
        fire(new ResolveChangeEvent(CatalogImpl.this, IResolveChangeEvent.Type.PRE_DELETE,
                deltaChanged));
       
        services.remove(entry);
        runInterceptor(entry, ServiceInterceptor.REMOVED_ID);
View Full Code Here

        } catch (IOException ignore) {
            // no children? Not a very good entry ..
        }
        changes.add(new ResolveDelta(service, replacement, childChanges));

        IResolveDelta deltas = new ResolveDelta(this, changes);
        IResolveChangeEvent event = new ResolveChangeEvent(this,
                IResolveChangeEvent.Type.PRE_DELETE, deltas);
        fire(event);
        services.remove(service);
        runInterceptor(service, ServiceInterceptor.REMOVED_ID);
View Full Code Here

TOP

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

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.