| net.refractions.udig.catalog.IResolveDelta
All known Subclasses: net.refractions.udig.catalog.internal.ResolveDelta,
IResolveDelta | public interface IResolveDelta (Code) | | Constants used to communicate Catalog Deltas.
For those familiar with IResourceChangeEvent and IResourceDelta from eclipse development there is
one important addition. The constant REPLACE indicates a reaname, or substiution, you
will need to replace any references you have to the oldObject with the newObject.
For "bit mask" style interation please use: EnumSet.of(Kind.ADDED, Kind.REPLACED)
author: Jody Garnett since: 0.6.0 |
Inner Class :public enum Kind | |
Method Summary | |
public void | accept(IResolveDeltaVisitor visitor) Accepts the given visitor. | public List<IResolveDelta> | getChildren() Resource deltas for all added, removed, changed, or replaced. | public List<IResolveDelta> | getChildren(EnumSet<Kind> kindMask) Finds and returns the delta information for a given resource. | public Kind | getKind() Returns the kind of this delta.
Normally, one of ADDED , REMOVED , CHANGED or
REPLACED .
This set is still open, during shutdown we may throw a few more kinds around. | public IResolve | getNewResolve() For replacement (REPLACE ), this handle describes the resource in the "after"
state. | public Object | getNewValue() If
IResolveDelta.getKind() ==Kind.CHANGED this method returns the new value of the item changed for example the new bounds of the IGeoResource. | public Object | getOldValue() If
IResolveDelta.getKind() ==Kind.CHANGED this method returns the old value of the item changed for example the old bounds of the IGeoResource. | public IResolve | getResolve() Returns a handle for the affected handle.
For additions (ADDED ), this handle describes the newly-added resolve; i.e.,
the one in the "after" state.
For changes (CHANGED ), this handle also describes the resource in the
"after" state.
For removals (REMOVED ), this handle describes the resource in the "before"
state. |
accept | public void accept(IResolveDeltaVisitor visitor) throws IOException(Code) | | Accepts the given visitor.
The only kinds of resource delta that our visited are ADDED, REMOVED, CHANGED and REPLACED.
This is a convenience method, equivalent to accepts( visitor, IService.NONE )
Parameters: visitor - throws: CoreException - |
getChildren | public List<IResolveDelta> getChildren()(Code) | | Resource deltas for all added, removed, changed, or replaced.
This is a short cut for:
finally List list = new ArrayList();
accept( IServiceDeltaVisitor() {
public boolean visit(IResolveDelta delta) {
switch (delta.getKind()) {
case IDelta.ADDED :
case IDelta.REMOVED :
case IDelta.CHANGED :
case IDelta.REPLACED :
list.add( delta );
default: // ignore
}
return true;
}
});
return list.toArray();
|
getChildren | public List<IResolveDelta> getChildren(EnumSet<Kind> kindMask)(Code) | | Finds and returns the delta information for a given resource.
Array of IGeoResourceDelta |
getKind | public Kind getKind()(Code) | | Returns the kind of this delta.
Normally, one of ADDED , REMOVED , CHANGED or
REPLACED .
This set is still open, during shutdown we may throw a few more kinds around. Eclipse makes
use of PHANTOM, and NON_PHANTOM not sure we care
the kind of this resource delta See Also: Kind.ADDED See Also: Kind.REMOVED See Also: Kind.CHANGED See Also: Kind.REPLACED |
getNewResolve | public IResolve getNewResolve()(Code) | | For replacement (REPLACE ), this handle describes the resource in the "after"
state. The old handle can be determined with getResolve().
The new resolve replacing the affected handle. |
getNewValue | public Object getNewValue()(Code) | | If
IResolveDelta.getKind() ==Kind.CHANGED this method returns the new value of the item changed for example the new bounds of the IGeoResource.
Otherwise it will return null.
If IResolveDelta.getKind()==Kind.CHANGED this method returns the new value of the item changed, otherwise it will return null. |
getOldValue | public Object getOldValue()(Code) | | If
IResolveDelta.getKind() ==Kind.CHANGED this method returns the old value of the item changed for example the old bounds of the IGeoResource.
Otherwise it will return null.
If IResolveDelta.getKind()==Kind.CHANGED this method returns the old value of the item changed, otherwise it will return null. |
getResolve | public IResolve getResolve()(Code) | | Returns a handle for the affected handle.
For additions (ADDED ), this handle describes the newly-added resolve; i.e.,
the one in the "after" state.
For changes (CHANGED ), this handle also describes the resource in the
"after" state.
For removals (REMOVED ), this handle describes the resource in the "before"
state. Even though this handle not normally exist in the current workspace, the type of
resource that was removed can be determined from the handle.
For removals (REPLACE ), this handle describes the resource in the "before"
state. The new handle can be determined with getNewResolve().
the affected resource (handle) |
|
|