Bug 59956 [R21PRES] perspective switcher
bundles/org.eclipse.ui.ide/src/org/eclipse/ui/internal/ide/IDEWorkbenchAdvisor.java
/**
	 * Returns the ordered set of versioned feature ids new for this session.
	 * 
	 * @return ordered set of versioned feature ids (element type: <code>String</code>)
	 */
	private Set getNewlyAddedFeatures() {
		Assert.isNotNull(newlyAddedFeatures);
		return newlyAddedFeatures;
	}
	
	/**
	 * Initializes the old, current, and newly added features.
	 */
	private void initializeFeatureSets() {
			
		IDialogSettings settings = IDEWorkbenchPlugin.getDefault().getDialogSettings();
		String[] previousFeaturesArray = settings.getArray(INSTALLED_FEATURES);
		Set previousFeatures = null;
		if (previousFeaturesArray != null) {
			previousFeatures = new HashSet(Arrays.asList(previousFeaturesArray));
		} else {
			previousFeatures = new HashSet(0);
		}
		
		Set currentFeatures = computeFeatureSet();
		String[] currentFeaturesArray = new String[currentFeatures.size()];
		currentFeatures.toArray(currentFeaturesArray);
		settings.put(INSTALLED_FEATURES, currentFeaturesArray);