diff options
Diffstat (limited to 'bundles/org.eclipse.team.ui/src/org/eclipse/team/ui/synchronize/AbstractSynchronizeScope.java')
-rw-r--r-- | bundles/org.eclipse.team.ui/src/org/eclipse/team/ui/synchronize/AbstractSynchronizeScope.java | 46 |
1 files changed, 23 insertions, 23 deletions
diff --git a/bundles/org.eclipse.team.ui/src/org/eclipse/team/ui/synchronize/AbstractSynchronizeScope.java b/bundles/org.eclipse.team.ui/src/org/eclipse/team/ui/synchronize/AbstractSynchronizeScope.java index f010689b7..bcef23350 100644 --- a/bundles/org.eclipse.team.ui/src/org/eclipse/team/ui/synchronize/AbstractSynchronizeScope.java +++ b/bundles/org.eclipse.team.ui/src/org/eclipse/team/ui/synchronize/AbstractSynchronizeScope.java @@ -24,26 +24,26 @@ import org.eclipse.ui.IMemento; /** * Abstract superclass of resource scopes for <code>SubscriberParticipant</code> * instances. - * + * * @see SubscriberParticipant * @since 3.0 * @noextend This class is not intended to be subclassed by clients. */ public abstract class AbstractSynchronizeScope implements ISynchronizeScope { - + /* * Key for scope in memento */ private static final String CTX_SUBSCRIBER_SCOPE_TYPE = TeamUIPlugin.ID + ".SCOPE_TYPE"; //$NON-NLS-1$ - + /* * Scope change listeners */ private ListenerList listeners = new ListenerList(ListenerList.IDENTITY); - + /** * Save the scope to the given memento - * + * * @param scope a scope * @param settings a memento */ @@ -51,10 +51,10 @@ public abstract class AbstractSynchronizeScope implements ISynchronizeScope { settings.putString(CTX_SUBSCRIBER_SCOPE_TYPE, getType(scope)); ((AbstractSynchronizeScope)scope).saveState(settings); } - + /** * Restore a scope from the given memento - * + * * @param settings a memento * @return the scope restored from the given memento */ @@ -71,29 +71,29 @@ public abstract class AbstractSynchronizeScope implements ISynchronizeScope { } return new WorkspaceScope(); } - + private static String getType(ISynchronizeScope scope) { String name = scope.getClass().getName(); int lastDot = name.lastIndexOf("."); //$NON-NLS-1$ if (lastDot == -1) { return name; } - return name.substring(lastDot + 1); + return name.substring(lastDot + 1); } - + /** * Constructor a scope from scratch */ protected AbstractSynchronizeScope() { } - + /** * Constructor a scope from a previously saved state */ protected AbstractSynchronizeScope(IMemento memento) { init(memento); } - + /* (non-Javadoc) * @see org.eclipse.team.internal.ui.synchronize.ScopableSubscriberParticipant.ISynchronizeScope#addPropertyChangeListener(org.eclipse.jface.util.IPropertyChangeListener) */ @@ -103,7 +103,7 @@ public abstract class AbstractSynchronizeScope implements ISynchronizeScope { listeners.add(listener); } } - + /* (non-Javadoc) * @see org.eclipse.team.internal.ui.synchronize.ScopableSubscriberParticipant.ISynchronizeScope#removePropertyChangeListener(org.eclipse.jface.util.IPropertyChangeListener) */ @@ -113,7 +113,7 @@ public abstract class AbstractSynchronizeScope implements ISynchronizeScope { listeners.remove(listeners); } } - + /* (non-Javadoc) * @see org.eclipse.team.ui.synchronize.ISynchronizeScope#dispose() */ @@ -121,10 +121,10 @@ public abstract class AbstractSynchronizeScope implements ISynchronizeScope { public void dispose() { // Do nothing by default } - + /** * Fires the given property change event to all registered listeners. - * + * * @param event the property change event to be fired */ protected void firePropertyChangedEvent(final PropertyChangeEvent event) { @@ -143,32 +143,32 @@ public abstract class AbstractSynchronizeScope implements ISynchronizeScope { } } /** - * Fires a change event for property <code>ISynchronizeScope.ROOTS</code> + * Fires a change event for property <code>ISynchronizeScope.ROOTS</code> * containing the new roots. The old roots are not provided in the event. */ protected void fireRootsChanges() { firePropertyChangedEvent(new PropertyChangeEvent(this, ROOTS, new IResource[0], getRoots())); } - + /** * Persist the state of this scope. Clients must persist enough additional * state to know what type (i.e. subclass) of scope to be recreated. - * + * * @param memento the memento into which the scope is to be saved */ public void saveState(IMemento memento) { // Do nothing by default } - + /** * Method invoked from the constructor which populates the fields of this scope - * + * * @param memento the memento into which the scope was previously saved */ protected void init(IMemento memento) { // Do nothing by default } - + /** * Return whether the given resource is within this scope. * By default, a resource is considered in the scope if @@ -188,7 +188,7 @@ public abstract class AbstractSynchronizeScope implements ISynchronizeScope { } return false; } - + /** * Return the resource mappings that define this scope. * By default, the mappings are just be deep traversals |