diff --git a/rse/doc/org.eclipse.rse.doc.user/concepts/cfilters.html b/rse/doc/org.eclipse.rse.doc.user/concepts/cfilters.html index 36c61edeb45..7d7f01898ce 100755 --- a/rse/doc/org.eclipse.rse.doc.user/concepts/cfilters.html +++ b/rse/doc/org.eclipse.rse.doc.user/concepts/cfilters.html @@ -3,7 +3,8 @@ - + + Filters, filter pools, and filter pool references @@ -12,6 +13,7 @@

Filters, filter pools, and filter pool references

+

Filters and Filtering Resources

The Remote System Explorer is a set of local client tools you use to organize @@ -52,10 +54,10 @@ directory to a remote system will result in all the files in that folder being copied, not just those that are revealed by the filter. This is consistent with the way resources are managed elsewhere in Eclipse.

+

Filter Pools

-If -you have been using the Remote System Explorer for some +If you have been using the Remote System Explorer for some time, your workspace might contain too many filters to navigate easily. Or, you might just want to keep groups of filters separate if, for example, @@ -85,7 +87,11 @@ appear in any other connections. (See the related links for more information about filter pools.)

-

You +

+Note: at time this filter pool names cannot contain three consecutive underscore characters. +

+

Sharing Filters

+

You can share filter pools among many connections through the use of a filter pool reference. A filter pool reference is a mechanism diff --git a/rse/doc/org.eclipse.rse.doc.user/concepts/cprofile.html b/rse/doc/org.eclipse.rse.doc.user/concepts/cprofile.html index fc38a14b115..dc12ccd8ffb 100755 --- a/rse/doc/org.eclipse.rse.doc.user/concepts/cprofile.html +++ b/rse/doc/org.eclipse.rse.doc.user/concepts/cprofile.html @@ -1,9 +1,11 @@ + + Remote System Explorer Profiles @@ -15,6 +17,9 @@

All Remote System Explorer resources such as connections, filters, and filter pools are owned by a profile. Profiles help you manage these resources when you have a lot of connections. The Remote System Explorer creates two profiles when starting up for the first time: a private profile, usually named after the host name of the machine that creates the workspace, and a profile called Team. The intent is to be able to share the Team profile in the future with other members of your team. You can also create your own profiles.

+

+ Note: due to an internal restriction a profile name cannot contain three consecutive underscore characters at this time. +

Profiles contain: * @param pool The filter pool object to rename * @param newName The new name to give the pool + * @see ISystemFilterPool#setName(String) */ public void renameSystemFilterPool(ISystemFilterPool pool, String newName) throws Exception; @@ -214,6 +217,7 @@ public interface ISystemFilterPoolManager extends IRSEPersistableContainer { * @param pool The filter pool to copy * @param newName The new name to give the copied pool * @return the new copy of the copied system filter pool + * @see ISystemFilterPool#setName(String) */ public ISystemFilterPool copySystemFilterPool(ISystemFilterPoolManager targetMgr, ISystemFilterPool pool, String newName) throws Exception; @@ -249,6 +253,7 @@ public interface ISystemFilterPoolManager extends IRSEPersistableContainer { * @param oldPool The filter pool to move * @param newName The new name to give the moved pool * @return the new copy of the moved system filter pool + * @see ISystemFilterPool#setName(String) */ public ISystemFilterPool moveSystemFilterPool(ISystemFilterPoolManager targetMgr, ISystemFilterPool oldPool, String newName) throws Exception; diff --git a/rse/plugins/org.eclipse.rse.core/src/org/eclipse/rse/core/model/ISystemProfile.java b/rse/plugins/org.eclipse.rse.core/src/org/eclipse/rse/core/model/ISystemProfile.java index abade897ab4..8f20539c914 100644 --- a/rse/plugins/org.eclipse.rse.core/src/org/eclipse/rse/core/model/ISystemProfile.java +++ b/rse/plugins/org.eclipse.rse.core/src/org/eclipse/rse/core/model/ISystemProfile.java @@ -19,6 +19,7 @@ * David Dykstal (IBM) - [202630] getDefaultPrivateProfile() and ensureDefaultPrivateProfile() are inconsistent * David Dykstal (IBM) - [200735][Persistence] Delete a profile that contains a connection and restart, profile is back without connections * David Dykstal (IBM) - [226561] Add API markup to RSE javadocs for extend / implement + * David Dykstal (IBM) - [235800] Document naming restriction for profiles and filter pools *******************************************************************************/ package org.eclipse.rse.core.model; @@ -63,6 +64,7 @@ public interface ISystemProfile extends IRSEModelObject { * Profile names must not contain three consecutive underscores "___", since these are used * to separate a profile name from a filter pool name in a filter pool reference. * @param value The new value of the Name attribute + * @throws IllegalArgumentException if the name contains three consecutive underscore characters. */ void setName(String value); diff --git a/rse/plugins/org.eclipse.rse.core/src/org/eclipse/rse/core/model/ISystemRegistry.java b/rse/plugins/org.eclipse.rse.core/src/org/eclipse/rse/core/model/ISystemRegistry.java index 2e8b8fc4e86..91e5479f1d3 100644 --- a/rse/plugins/org.eclipse.rse.core/src/org/eclipse/rse/core/model/ISystemRegistry.java +++ b/rse/plugins/org.eclipse.rse.core/src/org/eclipse/rse/core/model/ISystemRegistry.java @@ -28,6 +28,7 @@ * Martin Oberhuber (Wind River) - [cleanup] Add API "since" Javadoc tags * David Dykstal (IBM) - [168976][api] move ISystemNewConnectionWizardPage from core to UI * David Dykstal (IBM) - [226561] Add API markup to RSE javadocs for extend / implement + * David Dykstal (IBM) - [235800] Document naming restriction for profiles and filter pools ********************************************************************************/ package org.eclipse.rse.core.model; @@ -179,11 +180,15 @@ public interface ISystemRegistry extends ISchedulingRule, IAdaptable, ISystemVie /** * Create a SystemProfile given its name and whether or not to make it active + * Note that there are some naming restrictions on profile names. + * @see ISystemProfile#setName(String) */ public ISystemProfile createSystemProfile(String profileName, boolean makeActive) throws Exception; /** * Copy a SystemProfile. All connections connection data is copied. + * Note that there are some naming restrictions on profile names. + * @see ISystemProfile#setName(String) * @param profile Source profile to copy * @param newName Unique name to give copied profile * @param makeActive whether to make the copied profile active or not @@ -195,6 +200,8 @@ public interface ISystemRegistry extends ISchedulingRule, IAdaptable, ISystemVie /** * Rename a SystemProfile. Rename is propagated to all subsystem factories so * they can rename their filter pool managers and whatever else is required. + * Note that there are some naming restrictions on profile names. + * @see ISystemProfile#setName(String) */ public void renameSystemProfile(ISystemProfile profile, String newName) throws Exception; diff --git a/rse/plugins/org.eclipse.rse.core/src/org/eclipse/rse/internal/core/filters/SystemFilterPool.java b/rse/plugins/org.eclipse.rse.core/src/org/eclipse/rse/internal/core/filters/SystemFilterPool.java index e424ccd437a..e8fadb73a40 100644 --- a/rse/plugins/org.eclipse.rse.core/src/org/eclipse/rse/internal/core/filters/SystemFilterPool.java +++ b/rse/plugins/org.eclipse.rse.core/src/org/eclipse/rse/internal/core/filters/SystemFilterPool.java @@ -359,6 +359,9 @@ public class SystemFilterPool extends SystemPersistableReferencedObject */ public void setName(String name) { + if (name.indexOf(SystemFilterPoolReference.DELIMITER) >= 0) { + throw new IllegalArgumentException("Cannot have ___ in filter pool name."); + } if (this.name == null || !this.name.equals(name) ) { this.name = name; diff --git a/rse/plugins/org.eclipse.rse.core/src/org/eclipse/rse/internal/core/model/SystemProfile.java b/rse/plugins/org.eclipse.rse.core/src/org/eclipse/rse/internal/core/model/SystemProfile.java index cfd4f16c69f..3298bdfb67f 100644 --- a/rse/plugins/org.eclipse.rse.core/src/org/eclipse/rse/internal/core/model/SystemProfile.java +++ b/rse/plugins/org.eclipse.rse.core/src/org/eclipse/rse/internal/core/model/SystemProfile.java @@ -42,6 +42,7 @@ import org.eclipse.rse.core.model.RSEModelObject; import org.eclipse.rse.core.subsystems.ISubSystemConfiguration; import org.eclipse.rse.core.subsystems.ISubSystemConfigurationProxy; import org.eclipse.rse.internal.core.RSECoreMessages; +import org.eclipse.rse.internal.core.filters.SystemFilterPoolReference; import org.eclipse.rse.persistence.IRSEPersistenceProvider; /** @@ -230,6 +231,9 @@ public class SystemProfile extends RSEModelObject implements ISystemProfile, IAd * @see org.eclipse.rse.core.model.ISystemProfile#setName(java.lang.String) */ public void setName(String newName) { + if (newName.indexOf(SystemFilterPoolReference.DELIMITER) >= 0) { + throw new IllegalArgumentException("Cannot have ___ in profile name."); + } String oldName = name; if (!newName.equals(oldName)) { name = newName;