From b91b69775f21c19c83685a3b51d541938337bfca Mon Sep 17 00:00:00 2001
From: Sergey Prigogin <eclipse.sprigogin@gmail.com>
Date: Fri, 15 Apr 2016 09:33:51 -0700
Subject: [PATCH] Bug 491825 - Remove uses of new Boolean and friends

Change-Id: Ie358c8385c278472f3b86851f6fc219007bb9b5c
---
 .../core/AutotoolsNewMakeGenerator.java       |  6 +-
 .../make/internal/core/BuildInfoFactory.java  | 22 +++---
 .../make/internal/core/ProjectTargets.java    |  6 +-
 .../managedbuilder/internal/core/Builder.java | 78 +++++++++---------
 .../internal/core/InputOrder.java             | 14 ++--
 .../internal/core/InputType.java              | 79 +++++++++----------
 .../internal/core/MultiResourceInfo.java      |  2 +-
 .../managedbuilder/internal/core/Option.java  | 36 ++++-----
 .../internal/core/OptionReference.java        | 10 +--
 .../internal/core/OutputType.java             | 16 ++--
 .../internal/core/ProjectType.java            |  8 +-
 .../internal/core/ResourceInfo.java           |  2 +-
 .../internal/core/TargetPlatform.java         |  8 +-
 .../managedbuilder/internal/core/Tool.java    | 24 +++---
 .../internal/core/ToolChain.java              |  8 +-
 ...faultGCCDependencyCalculator2Commands.java |  4 +-
 ...CDependencyCalculatorPreBuildCommands.java |  6 +-
 .../UpdateManagedProject12.java               |  4 +-
 .../UpdateManagedProject20.java               |  4 +-
 .../ui/properties/ToolSettingsPrefStore.java  | 36 +++++----
 .../settings/model/util/CDataSerializer.java  |  4 +-
 .../core/settings/model/util/CDataUtil.java   |  2 +-
 .../cdt/internal/core/model/Binary.java       |  4 +-
 .../index/provider/IndexProviderManager.java  |  2 +-
 .../envvar/PrefsStorableEnvironment.java      |  4 +-
 .../cdt/utils/envvar/StorableEnvironment.java |  4 +-
 .../editor/ToggleMarkOccurrencesAction.java   | 22 +-----
 .../formatter/LineWrappingTabPage.java        |  4 +-
 .../ui/actions/CustomFiltersActionGroup.java  | 10 +--
 .../uitree/UIElementTreeBuilderHelper.java    | 14 ++--
 .../uitree/uiwidgets/UIBooleanWidget.java     |  4 +-
 .../core/RegisterGroupsPersistance.java       |  2 +-
 .../CDirectorySourceLocation.java             |  2 +-
 .../sourcelookup/CProjectSourceLocation.java  |  2 +-
 .../core/sourcelookup/CSourceLocator.java     |  2 +-
 .../CBreakpointPreferenceStore.java           |  4 +-
 .../dsf/mi/service/MIBreakpointDMData.java    | 18 ++---
 37 files changed, 228 insertions(+), 249 deletions(-)

diff --git a/build/org.eclipse.cdt.autotools.core/src/org/eclipse/cdt/internal/autotools/core/AutotoolsNewMakeGenerator.java b/build/org.eclipse.cdt.autotools.core/src/org/eclipse/cdt/internal/autotools/core/AutotoolsNewMakeGenerator.java
index 9a02a717da3..7f880bee707 100644
--- a/build/org.eclipse.cdt.autotools.core/src/org/eclipse/cdt/internal/autotools/core/AutotoolsNewMakeGenerator.java
+++ b/build/org.eclipse.cdt.autotools.core/src/org/eclipse/cdt/internal/autotools/core/AutotoolsNewMakeGenerator.java
@@ -1371,13 +1371,13 @@ public class AutotoolsNewMakeGenerator extends MarkerGenerator {
 		}
 
 		elem = targetElem.createChild(TARGET_STOP_ON_ERROR);
-		elem.setValue(Boolean.valueOf(target.isStopOnError()).toString());
+		elem.setValue(String.valueOf(target.isStopOnError()));
 
 		elem = targetElem.createChild(TARGET_USE_DEFAULT_CMD);
-		elem.setValue(Boolean.valueOf(target.isDefaultBuildCmd()).toString());
+		elem.setValue(String.valueOf(target.isDefaultBuildCmd()));
 
 		elem = targetElem.createChild(TARGET_RUN_ALL_BUILDERS);
-		elem.setValue(Boolean.valueOf(target.runAllBuilders()).toString());
+		elem.setValue(String.valueOf(target.runAllBuilders()));
 
 		return targetElem;
 	}
diff --git a/build/org.eclipse.cdt.make.core/src/org/eclipse/cdt/make/internal/core/BuildInfoFactory.java b/build/org.eclipse.cdt.make.core/src/org/eclipse/cdt/make/internal/core/BuildInfoFactory.java
index 52e7f70416b..c44712474cc 100644
--- a/build/org.eclipse.cdt.make.core/src/org/eclipse/cdt/make/internal/core/BuildInfoFactory.java
+++ b/build/org.eclipse.cdt.make.core/src/org/eclipse/cdt/make/internal/core/BuildInfoFactory.java
@@ -68,7 +68,7 @@ public class BuildInfoFactory {
 
 		@Override
 		public void setUseDefaultBuildCmd(boolean on) throws CoreException {
-			putString(USE_DEFAULT_BUILD_CMD, new Boolean(on).toString());
+			putString(USE_DEFAULT_BUILD_CMD, String.valueOf(on));
 		}
 
 		@Override
@@ -212,7 +212,7 @@ public class BuildInfoFactory {
 
 		@Override
 		public void setStopOnError(boolean enabled) throws CoreException {
-			putString(STOP_ON_ERROR, new Boolean(enabled).toString());
+			putString(STOP_ON_ERROR, String.valueOf(enabled));
 		}
 
 		@Override
@@ -286,7 +286,7 @@ public class BuildInfoFactory {
 
 		@Override
 		public void setAutoBuildEnable(boolean enabled) throws CoreException {
-			putString(BUILD_AUTO_ENABLED, new Boolean(enabled).toString());
+			putString(BUILD_AUTO_ENABLED, String.valueOf(enabled));
 		}
 
 		@Override
@@ -296,7 +296,7 @@ public class BuildInfoFactory {
 
 		@Override
 		public void setIncrementalBuildEnable(boolean enabled) throws CoreException {
-			putString(BUILD_INCREMENTAL_ENABLED, new Boolean(enabled).toString());
+			putString(BUILD_INCREMENTAL_ENABLED, String.valueOf(enabled));
 		}
 
 		@Override
@@ -306,7 +306,7 @@ public class BuildInfoFactory {
 
 		@Override
 		public void setFullBuildEnable(boolean enabled) throws CoreException {
-			putString(BUILD_FULL_ENABLED, new Boolean(enabled).toString());
+			putString(BUILD_FULL_ENABLED, String.valueOf(enabled));
 		}
 
 		@Override
@@ -316,7 +316,7 @@ public class BuildInfoFactory {
 
 		@Override
 		public void setCleanBuildEnable(boolean enabled) throws CoreException {
-			putString(BUILD_CLEAN_ENABLED, new Boolean(enabled).toString());
+			putString(BUILD_CLEAN_ENABLED, String.valueOf(enabled));
 		}
 
 		@Override
@@ -327,9 +327,9 @@ public class BuildInfoFactory {
 		@Override
 		public String[] getErrorParsers() {
 			String parsers = getString(ErrorParserManager.PREF_ERROR_PARSER);
-			if (parsers != null && parsers.length() > 0) {
+			if (parsers != null && !parsers.isEmpty()) {
 				StringTokenizer tok = new StringTokenizer(parsers, ";"); //$NON-NLS-1$
-				List<String> list = new ArrayList<String>(tok.countTokens());
+				List<String> list = new ArrayList<>(tok.countTokens());
 				while (tok.hasMoreElements()) {
 					list.add(tok.nextToken());
 				}
@@ -367,15 +367,15 @@ public class BuildInfoFactory {
 
 		@Override
 		public void setAppendEnvironment(boolean append) throws CoreException {
-			putString(BUILD_APPEND_ENVIRONMENT, new Boolean(append).toString());
+			putString(BUILD_APPEND_ENVIRONMENT, String.valueOf(append));
 		}
 
 		public boolean getBoolean(String property) {
-			return Boolean.valueOf(getString(property)).booleanValue();
+			return Boolean.parseBoolean(getString(property));
 		}
 
 		protected Map<String, String> decodeMap(String value) {
-			Map<String, String> map = new HashMap<String, String>();
+			Map<String, String> map = new HashMap<>();
 			if (value != null) {
 				StringBuffer envStr = new StringBuffer(value);
 				String escapeChars = "|\\"; //$NON-NLS-1$
diff --git a/build/org.eclipse.cdt.make.core/src/org/eclipse/cdt/make/internal/core/ProjectTargets.java b/build/org.eclipse.cdt.make.core/src/org/eclipse/cdt/make/internal/core/ProjectTargets.java
index 14bc9512ab1..41a10be49f6 100644
--- a/build/org.eclipse.cdt.make.core/src/org/eclipse/cdt/make/internal/core/ProjectTargets.java
+++ b/build/org.eclipse.cdt.make.core/src/org/eclipse/cdt/make/internal/core/ProjectTargets.java
@@ -195,13 +195,13 @@ public class ProjectTargets {
 		}
 
 		elem = targetElem.createChild(TARGET_STOP_ON_ERROR);
-		elem.setValue(new Boolean(target.isStopOnError()).toString());
+		elem.setValue(String.valueOf(target.isStopOnError()));
 
 		elem = targetElem.createChild(TARGET_USE_DEFAULT_CMD);
-		elem.setValue(new Boolean(target.isDefaultBuildCmd()).toString());
+		elem.setValue(String.valueOf(target.isDefaultBuildCmd()));
 
 		elem = targetElem.createChild(TARGET_RUN_ALL_BUILDERS);
-		elem.setValue(new Boolean(target.runAllBuilders()).toString());
+		elem.setValue(String.valueOf(target.runAllBuilders()));
 
 		return targetElem;
 	}
diff --git a/build/org.eclipse.cdt.managedbuilder.core/src/org/eclipse/cdt/managedbuilder/internal/core/Builder.java b/build/org.eclipse.cdt.managedbuilder.core/src/org/eclipse/cdt/managedbuilder/internal/core/Builder.java
index cce2fdf9264..51fd2d50245 100644
--- a/build/org.eclipse.cdt.managedbuilder.core/src/org/eclipse/cdt/managedbuilder/internal/core/Builder.java
+++ b/build/org.eclipse.cdt.managedbuilder.core/src/org/eclipse/cdt/managedbuilder/internal/core/Builder.java
@@ -251,10 +251,8 @@ public class Builder extends HoldsOptions implements IBuilder, IMatchKeyProvider
 		this.parent = parent;
 		
 		superClass = builder.superClass;
-		if (superClass != null) {
-			if (builder.superClassId != null) {
-				superClassId = new String(builder.superClassId);
-			}
+		if (superClass != null && builder.superClassId != null) {
+			superClassId = builder.superClassId;
 		}
 
 		setId(Id);
@@ -268,25 +266,25 @@ public class Builder extends HoldsOptions implements IBuilder, IMatchKeyProvider
 		
 		//  Copy the remaining attributes
 		if(builder.versionsSupported != null) {
-			versionsSupported = new String(builder.versionsSupported);
+			versionsSupported = builder.versionsSupported;
 		}
 		if(builder.convertToId != null) {
-			convertToId = new String(builder.convertToId);
+			convertToId = builder.convertToId;
 		}
 		if (builder.unusedChildren != null) {
-			unusedChildren = new String(builder.unusedChildren);
+			unusedChildren = builder.unusedChildren;
 		}
 		if (builder.errorParserIds != null) {
-			errorParserIds = new String(builder.errorParserIds);
+			errorParserIds = builder.errorParserIds;
 		}
 		if (builder.isAbstract != null) {
-			isAbstract = new Boolean(builder.isAbstract.booleanValue());
+			isAbstract = builder.isAbstract.booleanValue();
 		}
 		if (builder.command != null) {
-			command = new String(builder.command);
+			command = builder.command;
 		}
 		if (builder.args != null) {
-			args = new String(builder.args);
+			args = builder.args;
 		}
 		autoBuildTarget = builder.autoBuildTarget;
 		autoBuildEnabled = builder.autoBuildEnabled;
@@ -297,30 +295,28 @@ public class Builder extends HoldsOptions implements IBuilder, IMatchKeyProvider
 		managedBuildOn = builder.managedBuildOn;
 		keepEnvVarInBuildfile = builder.keepEnvVarInBuildfile;
 		supportsManagedBuild = builder.supportsManagedBuild;
-		if(builder.customizedErrorParserIds != null)
+		if (builder.customizedErrorParserIds != null)
 			customizedErrorParserIds = builder.customizedErrorParserIds.clone();
-		if(builder.customizedEnvironment != null)
+		if (builder.customizedEnvironment != null)
 			customizedEnvironment = cloneMap(builder.customizedEnvironment);
 		appendEnvironment = builder.appendEnvironment;
 		buildPath = builder.buildPath;
-		if(builder.customBuildProperties != null)
+		if (builder.customBuildProperties != null)
 			customBuildProperties = cloneMap(builder.customBuildProperties);
-
-			
 			
 		buildFileGeneratorElement = builder.buildFileGeneratorElement; 
 		
-		if(builder.fileContextBuildMacroValues != null){
+		if (builder.fileContextBuildMacroValues != null){
 			fileContextBuildMacroValues = (FileContextBuildMacroValues)builder.fileContextBuildMacroValues.clone();
 			fileContextBuildMacroValues.setBuilder(this);
 		}
 		
 		builderVariablePattern = builder.builderVariablePattern;
 		
-		if(builder.isVariableCaseSensitive != null)
-			isVariableCaseSensitive = new Boolean(builder.isVariableCaseSensitive.booleanValue());
+		if (builder.isVariableCaseSensitive != null)
+			isVariableCaseSensitive = Boolean.valueOf(builder.isVariableCaseSensitive.booleanValue());
 
-		if(builder.reservedMacroNames != null)
+		if (builder.reservedMacroNames != null)
 			reservedMacroNames = builder.reservedMacroNames.clone();
 
 		reservedMacroNameSupplierElement = builder.reservedMacroNameSupplierElement;
@@ -480,7 +476,7 @@ public class Builder extends HoldsOptions implements IBuilder, IMatchKeyProvider
 		// get the 'isVariableCaseSensitive' attribute
 		String isCS = element.getAttribute(IS_VARIABLE_CASE_SENSITIVE);
 		if(isCS != null)
-			isVariableCaseSensitive = new Boolean("true".equals(isCS)); //$NON-NLS-1$
+			isVariableCaseSensitive = Boolean.valueOf("true".equals(isCS)); //$NON-NLS-1$
 
 		// get the reserved macro names
 		String reservedNames = element.getAttribute(RESERVED_MACRO_NAMES);
@@ -499,7 +495,7 @@ public class Builder extends HoldsOptions implements IBuilder, IMatchKeyProvider
 		// isAbstract
         String isAbs = element.getAttribute(IProjectType.IS_ABSTRACT);
         if (isAbs != null){
-    		isAbstract = new Boolean("true".equals(isAbs)); //$NON-NLS-1$
+    		isAbstract = Boolean.valueOf("true".equals(isAbs)); //$NON-NLS-1$
         }
 
         // command
@@ -708,7 +704,7 @@ public class Builder extends HoldsOptions implements IBuilder, IMatchKeyProvider
 		if (element.getAttribute(IProjectType.IS_ABSTRACT) != null) {
 			String isAbs = element.getAttribute(IProjectType.IS_ABSTRACT);
 			if (isAbs != null){
-				isAbstract = new Boolean("true".equals(isAbs)); //$NON-NLS-1$
+				isAbstract = Boolean.valueOf("true".equals(isAbs)); //$NON-NLS-1$
 			}
 		}
 
@@ -986,21 +982,21 @@ public class Builder extends HoldsOptions implements IBuilder, IMatchKeyProvider
 		
 		if(getAutoBuildTargetAttribute() != null)
 			element.setAttribute(ATTRIBUTE_TARGET_AUTO, getAutoBuildTargetAttribute());
-		element.setAttribute(ATTRIBUTE_AUTO_ENABLED, Boolean.valueOf(isAutoBuildEnable()).toString());
+		element.setAttribute(ATTRIBUTE_AUTO_ENABLED, String.valueOf(isAutoBuildEnable()));
 		if(getIncrementalBuildTargetAttribute() != null)
 			element.setAttribute(ATTRIBUTE_TARGET_INCREMENTAL, getIncrementalBuildTargetAttribute());
-		element.setAttribute(ATTRIBUTE_INCREMENTAL_ENABLED, Boolean.valueOf(isIncrementalBuildEnabled()).toString());
+		element.setAttribute(ATTRIBUTE_INCREMENTAL_ENABLED, String.valueOf(isIncrementalBuildEnabled()));
 		if(getCleanBuildTargetAttribute() != null)
 			element.setAttribute(ATTRIBUTE_TARGET_CLEAN, getCleanBuildTargetAttribute());
-		element.setAttribute(ATTRIBUTE_CLEAN_ENABLED, Boolean.valueOf(isCleanBuildEnabled()).toString());
-		element.setAttribute(ATTRIBUTE_MANAGED_BUILD_ON, Boolean.valueOf(isManagedBuildOn()).toString());
-		element.setAttribute(ATTRIBUTE_KEEP_ENV, Boolean.valueOf(keepEnvironmentVariablesInBuildfile()).toString());
-		element.setAttribute(ATTRIBUTE_SUPORTS_MANAGED_BUILD, Boolean.valueOf(supportsBuild(true)).toString());
+		element.setAttribute(ATTRIBUTE_CLEAN_ENABLED, String.valueOf(isCleanBuildEnabled()));
+		element.setAttribute(ATTRIBUTE_MANAGED_BUILD_ON, String.valueOf(isManagedBuildOn()));
+		element.setAttribute(ATTRIBUTE_KEEP_ENV, String.valueOf(keepEnvironmentVariablesInBuildfile()));
+		element.setAttribute(ATTRIBUTE_SUPORTS_MANAGED_BUILD, String.valueOf(supportsBuild(true)));
 		if(customizedErrorParserIds != null)
 			element.setAttribute(ATTRIBUTE_CUSTOMIZED_ERROR_PARSERS, CDataUtil.arrayToString(customizedErrorParserIds, ";")); //$NON-NLS-1$
 		if(customizedEnvironment != null)
 			element.setAttribute(ATTRIBUTE_ENVIRONMENT, MapStorageElement.encodeMap(customizedEnvironment));
-		element.setAttribute(ATTRIBUTE_APPEND_ENVIRONMENT, Boolean.valueOf(appendEnvironment()).toString());
+		element.setAttribute(ATTRIBUTE_APPEND_ENVIRONMENT, String.valueOf(appendEnvironment()));
 		if(getBuildPathAttribute() != null)	
 			element.setAttribute(ATTRIBUTE_BUILD_PATH, getBuildPathAttribute());
 		if(customBuildProperties != null)
@@ -1008,7 +1004,7 @@ public class Builder extends HoldsOptions implements IBuilder, IMatchKeyProvider
 
 		if (getIgnoreErrCmdAttribute() != null)
 			element.setAttribute(ATTRIBUTE_IGNORE_ERR_CMD, getIgnoreErrCmdAttribute());
-		element.setAttribute(ATTRIBUTE_STOP_ON_ERR, Boolean.valueOf(isStopOnError()).toString());
+		element.setAttribute(ATTRIBUTE_STOP_ON_ERR, String.valueOf(isStopOnError()));
 
 		if (parallelBuildCmd != null)
 			element.setAttribute(ATTRIBUTE_PARALLEL_BUILD_CMD, parallelBuildCmd);
@@ -1332,7 +1328,7 @@ public class Builder extends HoldsOptions implements IBuilder, IMatchKeyProvider
 
 	@Override
 	public void setIsAbstract(boolean b) {
-		isAbstract = new Boolean(b);
+		isAbstract = Boolean.valueOf(b);
 		setDirty(true);
 	}
 	
@@ -2152,9 +2148,9 @@ public class Builder extends HoldsOptions implements IBuilder, IMatchKeyProvider
 		} else if(BuilderFactory.BUILD_LOCATION.equals(name)){
 			result = getBuildPathAttribute();
 		} else if(BuilderFactory.STOP_ON_ERROR.equals(name)){
-			result = Boolean.valueOf(isStopOnError()).toString();
+			result = String.valueOf(isStopOnError());
 		} else if(BuilderFactory.USE_DEFAULT_BUILD_CMD.equals(name)){
-			result = Boolean.valueOf(isDefaultBuildCmd()).toString();
+			result = String.valueOf(isDefaultBuildCmd());
 		} else if(BuilderFactory.BUILD_TARGET_AUTO.equals(name)){
 			result = getAutoBuildTargetAttribute();
 		} else if(BuilderFactory.BUILD_TARGET_INCREMENTAL.equals(name)){
@@ -2164,20 +2160,20 @@ public class Builder extends HoldsOptions implements IBuilder, IMatchKeyProvider
 		} else if(BuilderFactory.BUILD_TARGET_CLEAN.equals(name)){
 			result = getCleanBuildTargetAttribute();
 		} else if(BuilderFactory.BUILD_FULL_ENABLED.equals(name)){
-			result = Boolean.valueOf(isFullBuildEnabled()).toString();
+			result = String.valueOf(isFullBuildEnabled());
 		} else if(BuilderFactory.BUILD_CLEAN_ENABLED.equals(name)){
-			result = Boolean.valueOf(isCleanBuildEnabled()).toString();
+			result = String.valueOf(isCleanBuildEnabled());
 		} else if(BuilderFactory.BUILD_INCREMENTAL_ENABLED.equals(name)){
-			result = Boolean.valueOf(isIncrementalBuildEnabled()).toString();
+			result = String.valueOf(isIncrementalBuildEnabled());
 		} else if(BuilderFactory.BUILD_AUTO_ENABLED.equals(name)){
-			result = Boolean.valueOf(isAutoBuildEnable()).toString();
+			result = String.valueOf(isAutoBuildEnable());
 		} else if(BuilderFactory.BUILD_ARGUMENTS.equals(name)){
 			result = getArguments();
 		} else if(BuilderFactory.ENVIRONMENT.equals(name)){
 			result = customizedEnvironment != null ?
 				MapStorageElement.encodeMap(customizedEnvironment) : null;
 		} else if(BuilderFactory.BUILD_APPEND_ENVIRONMENT.equals(name)){
-			result = Boolean.valueOf(appendEnvironment()).toString();
+			result = String.valueOf(appendEnvironment());
 		} else if(customBuildProperties != null){
 			result = customBuildProperties.get(name);
 		}
@@ -2692,14 +2688,14 @@ public class Builder extends HoldsOptions implements IBuilder, IMatchKeyProvider
 	
 	void removeErrorParsers(Set<String> set){
 		Set<String> oldSet = contributeErrorParsers(null);
-		if(oldSet == null)
+		if (oldSet == null)
 			oldSet = new HashSet<String>();
 		oldSet.removeAll(set);
 		setErrorParserList(oldSet.toArray(new String[oldSet.size()]));
 	}
 	
 	public void setErrorParserList(String[] ids) {
-		if(ids == null){
+		if (ids == null){
 			errorParserIds = null;
 		} else if(ids.length == 0){
 			errorParserIds = EMPTY_STRING;
diff --git a/build/org.eclipse.cdt.managedbuilder.core/src/org/eclipse/cdt/managedbuilder/internal/core/InputOrder.java b/build/org.eclipse.cdt.managedbuilder.core/src/org/eclipse/cdt/managedbuilder/internal/core/InputOrder.java
index 92706f009e1..c448e2cf4d9 100644
--- a/build/org.eclipse.cdt.managedbuilder.core/src/org/eclipse/cdt/managedbuilder/internal/core/InputOrder.java
+++ b/build/org.eclipse.cdt.managedbuilder.core/src/org/eclipse/cdt/managedbuilder/internal/core/InputOrder.java
@@ -95,15 +95,15 @@ public class InputOrder implements IInputOrder {
 
 		//  Copy the remaining attributes
 		if (inputOrder.fPath != null) {
-			fPath = new String(inputOrder.fPath);
+			fPath = inputOrder.fPath;
 		}
 
 		if (inputOrder.fOrder != null) {
-			fOrder = new String(inputOrder.fOrder);
+			fOrder = inputOrder.fOrder;
 		}
 
 		if (inputOrder.fExcluded != null) {
-			fExcluded = new Boolean(inputOrder.fExcluded.booleanValue());
+			fExcluded = inputOrder.fExcluded.booleanValue();
 		}
 
 		setDirty(true);
@@ -131,7 +131,7 @@ public class InputOrder implements IInputOrder {
 		// excluded
         String isEx = element.getAttribute(IInputOrder.EXCLUDED);
         if (isEx != null){
-    		fExcluded = new Boolean("true".equals(isEx)); //$NON-NLS-1$
+    		fExcluded = Boolean.parseBoolean(isEx);
         }
 	}
 
@@ -142,7 +142,6 @@ public class InputOrder implements IInputOrder {
 	 * @param element An XML element containing the InputOrder information
 	 */
 	protected void loadFromProject(ICStorageElement element) {
-
 		// path
 		if (element.getAttribute(IInputOrder.PATH) != null) {
 			fPath = SafeStringInterner.safeIntern(element.getAttribute(IInputOrder.PATH));
@@ -157,7 +156,7 @@ public class InputOrder implements IInputOrder {
 		if (element.getAttribute(IInputOrder.EXCLUDED) != null) {
 			String isEx = element.getAttribute(IInputOrder.EXCLUDED);
 			if (isEx != null){
-				fExcluded = new Boolean("true".equals(isEx)); //$NON-NLS-1$
+				fExcluded = Boolean.parseBoolean(isEx);
 			}
 		}
 	}
@@ -166,7 +165,6 @@ public class InputOrder implements IInputOrder {
 	 * Persist the InputOrder to the project file.
 	 */
 	public void serialize(ICStorageElement element) {
-
 		if (fPath != null) {
 			element.setAttribute(IInputOrder.PATH, fPath);
 		}
@@ -255,7 +253,7 @@ public class InputOrder implements IInputOrder {
 	@Override
 	public void setExcluded(boolean b) {
 		if (fExcluded == null || !(b == fExcluded.booleanValue())) {
-			fExcluded = new Boolean(b);
+			fExcluded = b;
 			setDirty(true);
 			setRebuildState(true);
 		}
diff --git a/build/org.eclipse.cdt.managedbuilder.core/src/org/eclipse/cdt/managedbuilder/internal/core/InputType.java b/build/org.eclipse.cdt.managedbuilder.core/src/org/eclipse/cdt/managedbuilder/internal/core/InputType.java
index 8ccdcf0cfa2..14af19f13b3 100644
--- a/build/org.eclipse.cdt.managedbuilder.core/src/org/eclipse/cdt/managedbuilder/internal/core/InputType.java
+++ b/build/org.eclipse.cdt.managedbuilder.core/src/org/eclipse/cdt/managedbuilder/internal/core/InputType.java
@@ -215,10 +215,8 @@ public class InputType extends BuildObject implements IInputType {
 	public InputType(ITool parent, String Id, String name, InputType inputType) {
 		this.parent = parent;
 		superClass = inputType.superClass;
-		if (superClass != null) {
-			if (inputType.superClassId != null) {
-				superClassId = new String(inputType.superClassId);
-			}
+		if (superClass != null && inputType.superClassId != null) {
+			superClassId = inputType.superClassId;
 		}
 		setId(Id);
 		setName(name);
@@ -248,26 +246,26 @@ public class InputType extends BuildObject implements IInputType {
 		}
 
 		if (inputType.dependencyContentTypeId != null) {
-			dependencyContentTypeId = new String(inputType.dependencyContentTypeId);
+			dependencyContentTypeId = inputType.dependencyContentTypeId;
 		}
 		dependencyContentType = inputType.dependencyContentType;
 		if (inputType.dependencyExtensions != null) {
-			dependencyExtensions = new ArrayList<String>(inputType.dependencyExtensions);
+			dependencyExtensions = new ArrayList<>(inputType.dependencyExtensions);
 		}
 		if (inputType.optionId != null) {
-			optionId = new String(inputType.optionId);
+			optionId = inputType.optionId;
 		}
 		if (inputType.assignToOptionId != null) {
-			assignToOptionId = new String(inputType.assignToOptionId);
+			assignToOptionId = inputType.assignToOptionId;
 		}
 		if (inputType.buildVariable != null) {
-			buildVariable = new String(inputType.buildVariable);
+			buildVariable = inputType.buildVariable;
 		}
 		if (inputType.multipleOfType != null) {
-			multipleOfType = new Boolean(inputType.multipleOfType.booleanValue());
+			multipleOfType = inputType.multipleOfType.booleanValue();
 		}
 		if (inputType.primaryInput != null) {
-			primaryInput = new Boolean(inputType.primaryInput.booleanValue());
+			primaryInput = inputType.primaryInput.booleanValue();
 		}
 		dependencyGeneratorElement = inputType.dependencyGeneratorElement;
 		dependencyGenerator = inputType.dependencyGenerator;
@@ -292,7 +290,7 @@ public class InputType extends BuildObject implements IInputType {
 			}
 		}
 
-		if(copyIds){
+		if (copyIds){
 			isDirty = inputType.isDirty;
 			rebuildState = inputType.rebuildState;
 		} else {
@@ -326,7 +324,7 @@ public class InputType extends BuildObject implements IInputType {
 		// sourceContentType
 		List<String> list = new ArrayList<String>();
 		String ids = element.getAttribute(IInputType.SOURCE_CONTENT_TYPE);
-		if(ids != null){
+		if (ids != null){
 			StringTokenizer tokenizer = new StringTokenizer(ids, DEFAULT_SEPARATOR);
 			while (tokenizer.hasMoreElements()) {
 				list.add(SafeStringInterner.safeIntern(tokenizer.nextToken()));
@@ -345,7 +343,7 @@ public class InputType extends BuildObject implements IInputType {
 				list.add(SafeStringInterner.safeIntern(tokenizer.nextToken()));
 			}
 
-			if(list.size() != 0){
+			if (list.size() != 0) {
 				inputExtensions = list.toArray(new String[list.size()]);
 				list.clear();
 			}
@@ -353,12 +351,12 @@ public class InputType extends BuildObject implements IInputType {
 
 		// headerContentType
 		ids = element.getAttribute(IInputType.HEADER_CONTENT_TYPE);
-		if(ids != null){
+		if (ids != null){
 			StringTokenizer tokenizer = new StringTokenizer(ids, DEFAULT_SEPARATOR);
 			while (tokenizer.hasMoreElements()) {
 				list.add(SafeStringInterner.safeIntern(tokenizer.nextToken()));
 			}
-			if(list.size() != 0){
+			if (list.size() != 0){
 				headerContentTypeIds = list.toArray(new String[list.size()]);
 				list.clear();
 			}
@@ -372,7 +370,7 @@ public class InputType extends BuildObject implements IInputType {
 				list.add(SafeStringInterner.safeIntern(tokenizer.nextToken()));
 			}
 
-			if(list.size() != 0){
+			if (list.size() != 0){
 				headerExtensions = list.toArray(new String[list.size()]);
 				list.clear();
 			}
@@ -399,13 +397,13 @@ public class InputType extends BuildObject implements IInputType {
 		// multipleOfType
         String isMOT = element.getAttribute(IInputType.MULTIPLE_OF_TYPE);
         if (isMOT != null){
-    		multipleOfType = new Boolean("true".equals(isMOT)); //$NON-NLS-1$
+    		multipleOfType = Boolean.valueOf("true".equals(isMOT)); //$NON-NLS-1$
         }
 
 		// primaryInput
         String isPI = element.getAttribute(IInputType.PRIMARY_INPUT);
         if (isPI != null){
-			primaryInput = new Boolean("true".equals(isPI)); //$NON-NLS-1$
+			primaryInput = Boolean.valueOf("true".equals(isPI)); //$NON-NLS-1$
         }
 
 		// buildVariable
@@ -435,7 +433,6 @@ public class InputType extends BuildObject implements IInputType {
 	 * @param element An XML element containing the InputType information
 	 */
 	protected boolean loadFromProject(ICStorageElement element) {
-
 		// id
 		// note: IDs are unique so no benefit to intern them
 		setId(element.getAttribute(IBuildObject.ID));
@@ -465,7 +462,7 @@ public class InputType extends BuildObject implements IInputType {
 					list.add(SafeStringInterner.safeIntern(tokenizer.nextToken()));
 				}
 
-				if(list.size() != 0){
+				if (list.size() != 0){
 					sourceContentTypeIds = list.toArray(new String[list.size()]);
 					list.clear();
 				}
@@ -478,7 +475,7 @@ public class InputType extends BuildObject implements IInputType {
 							types.add(type);
 					}
 
-					if(types.size() != 0){
+					if (types.size() != 0){
 						sourceContentTypes = types.toArray(new IContentType[types.size()]);
 					}
 				}
@@ -494,7 +491,7 @@ public class InputType extends BuildObject implements IInputType {
 					list.add(SafeStringInterner.safeIntern(tokenizer.nextToken()));
 				}
 
-				if(list.size() != 0){
+				if (list.size() != 0){
 					inputExtensions = list.toArray(new String[list.size()]);
 					list.clear();
 				}
@@ -510,20 +507,20 @@ public class InputType extends BuildObject implements IInputType {
 					list.add(SafeStringInterner.safeIntern(tokenizer.nextToken()));
 				}
 
-				if(list.size() != 0){
+				if (list.size() != 0){
 					headerContentTypeIds = list.toArray(new String[list.size()]);
 					list.clear();
 				}
 
-				if(headerContentTypeIds != null){
-					List<IContentType> types = new ArrayList<IContentType>();
+				if (headerContentTypeIds != null){
+					List<IContentType> types = new ArrayList<>();
 					for (String headerContentTypeId : headerContentTypeIds) {
 						IContentType type = manager.getContentType(headerContentTypeId);
 						if(type != null)
 							types.add(type);
 					}
 
-					if(types.size() != 0){
+					if (types.size() != 0){
 						headerContentTypes = types.toArray(new IContentType[types.size()]);
 					}
 				}
@@ -539,7 +536,7 @@ public class InputType extends BuildObject implements IInputType {
 					list.add(SafeStringInterner.safeIntern(tokenizer.nextToken()));
 				}
 
-				if(list.size() != 0){
+				if (list.size() != 0){
 					headerExtensions = list.toArray(new String[list.size()]);
 					list.clear();
 				}
@@ -580,7 +577,7 @@ public class InputType extends BuildObject implements IInputType {
 		if (element.getAttribute(IInputType.MULTIPLE_OF_TYPE) != null) {
 			String isMOT = element.getAttribute(IInputType.MULTIPLE_OF_TYPE);
 			if (isMOT != null){
-				multipleOfType = new Boolean("true".equals(isMOT)); //$NON-NLS-1$
+				multipleOfType = Boolean.valueOf("true".equals(isMOT)); //$NON-NLS-1$
 			}
 		}
 
@@ -588,7 +585,7 @@ public class InputType extends BuildObject implements IInputType {
 		if (element.getAttribute(IInputType.PRIMARY_INPUT) != null) {
 	        String isPI = element.getAttribute(IInputType.PRIMARY_INPUT);
 	        if (isPI != null){
-				primaryInput = new Boolean("true".equals(isPI)); //$NON-NLS-1$
+				primaryInput = Boolean.valueOf("true".equals(isPI)); //$NON-NLS-1$
 	        }
 		}
 
@@ -611,14 +608,14 @@ public class InputType extends BuildObject implements IInputType {
 	}
 
 	private String composeString(String array[], String separator){
-		if(array == null)
+		if (array == null)
 			return null;
-		if(array.length == 0)
+		if (array.length == 0)
 			return ""; //$NON-NLS-1$
 
 		StringBuffer buf = new StringBuffer();
 		buf.append(array[0]);
-		for(int i = 1; i < array.length; i++){
+		for (int i = 1; i < array.length; i++){
 			buf.append(separator).append(array[i]);
 		}
 
@@ -698,13 +695,13 @@ public class InputType extends BuildObject implements IInputType {
 			element.setAttribute(IInputType.BUILD_VARIABLE, buildVariable);
 		}
 
-		if(languageId != null)
+		if (languageId != null)
 			element.setAttribute(LANGUAGE_ID, languageId);
 
-		if(languageName != null)
+		if (languageName != null)
 			element.setAttribute(LANGUAGE_NAME, languageName);
 
-		if(buildInfoDicsoveryProfileId != null)
+		if (buildInfoDicsoveryProfileId != null)
 			element.setAttribute(SCANNER_CONFIG_PROFILE_ID, buildInfoDicsoveryProfileId);
 
 		// Note: dependency generator cannot be specified in a project file because
@@ -779,7 +776,8 @@ public class InputType extends BuildObject implements IInputType {
 	@Override
 	public void removeInputOrder(String path) {
 		IInputOrder order = getInputOrder(path);
-		if (order != null) removeInputOrder(order);
+		if (order != null)
+			removeInputOrder(order);
 	}
 
 	/* (non-Javadoc)
@@ -838,7 +836,8 @@ public class InputType extends BuildObject implements IInputType {
 					}
 				}
 			}
-			if (match) return ai;
+			if (match)
+				return ai;
 		}
 		return null;
 	}
@@ -1159,7 +1158,7 @@ public class InputType extends BuildObject implements IInputType {
 	@Override
 	public void setMultipleOfType(boolean b) {
 		if (multipleOfType == null || !(b == multipleOfType.booleanValue())) {
-			multipleOfType = new Boolean(b);
+			multipleOfType = Boolean.valueOf(b);
 			setDirty(true);
 			setRebuildState(true);
 		}
@@ -1186,7 +1185,7 @@ public class InputType extends BuildObject implements IInputType {
 	@Override
 	public void setPrimaryInput(boolean b) {
 		if (primaryInput == null || !(b == primaryInput.booleanValue())) {
-			primaryInput = new Boolean(b);
+			primaryInput = Boolean.valueOf(b);
 			setDirty(true);
 			setRebuildState(true);
 		}
diff --git a/build/org.eclipse.cdt.managedbuilder.core/src/org/eclipse/cdt/managedbuilder/internal/core/MultiResourceInfo.java b/build/org.eclipse.cdt.managedbuilder.core/src/org/eclipse/cdt/managedbuilder/internal/core/MultiResourceInfo.java
index e0ef26ee9a1..a7de7046c3a 100644
--- a/build/org.eclipse.cdt.managedbuilder.core/src/org/eclipse/cdt/managedbuilder/internal/core/MultiResourceInfo.java
+++ b/build/org.eclipse.cdt.managedbuilder.core/src/org/eclipse/cdt/managedbuilder/internal/core/MultiResourceInfo.java
@@ -287,7 +287,7 @@ public abstract class MultiResourceInfo extends MultiItemsHolder implements
 	@Override
 	public IOption setOption(IHoldsOptions parent, IOption option, boolean value)
 			throws BuildException {
-		return setOption(parent, option, new Boolean(value), MODE_BOOL);
+		return setOption(parent, option, Boolean.valueOf(value), MODE_BOOL);
 	}
 
 	/* (non-Javadoc)
diff --git a/build/org.eclipse.cdt.managedbuilder.core/src/org/eclipse/cdt/managedbuilder/internal/core/Option.java b/build/org.eclipse.cdt.managedbuilder.core/src/org/eclipse/cdt/managedbuilder/internal/core/Option.java
index 67c3c3c4b1e..cb4ccfbe6b1 100644
--- a/build/org.eclipse.cdt.managedbuilder.core/src/org/eclipse/cdt/managedbuilder/internal/core/Option.java
+++ b/build/org.eclipse.cdt.managedbuilder.core/src/org/eclipse/cdt/managedbuilder/internal/core/Option.java
@@ -202,7 +202,7 @@ public class Option extends BuildObject implements IOption, IBuildPropertiesRest
 			unusedChildren = new String(option.unusedChildren);
 		}
 		if (option.isAbstract != null) {
-			isAbstract = new Boolean(option.isAbstract.booleanValue());
+			isAbstract = Boolean.valueOf(option.isAbstract.booleanValue());
 		}
 		if (option.command != null) {
 			command = new String(option.command);
@@ -211,7 +211,7 @@ public class Option extends BuildObject implements IOption, IBuildPropertiesRest
 			commandFalse = new String(option.commandFalse);
 		}
 		if (option.isForScannerDiscovery != null) {
-			isForScannerDiscovery = new Boolean(option.isForScannerDiscovery.booleanValue());
+			isForScannerDiscovery = Boolean.valueOf(option.isForScannerDiscovery.booleanValue());
 		}
 		if (option.tip != null) {
 			tip = new String(option.tip);
@@ -255,10 +255,10 @@ public class Option extends BuildObject implements IOption, IBuildPropertiesRest
 			switch (vType.intValue()) {
 			case BOOLEAN:
 				if (option.value != null) {
-					value = new Boolean(((Boolean)option.value).booleanValue());
+					value = Boolean.valueOf(((Boolean)option.value).booleanValue());
 				}
 				if (option.defaultValue != null) {
-					defaultValue = new Boolean(((Boolean)option.defaultValue).booleanValue());
+					defaultValue = Boolean.valueOf(((Boolean)option.defaultValue).booleanValue());
 				}
 				break;
 			case STRING:
@@ -364,7 +364,7 @@ public class Option extends BuildObject implements IOption, IBuildPropertiesRest
 		// isAbstract
 		String isAbs = element.getAttribute(IProjectType.IS_ABSTRACT);
 		if (isAbs != null){
-			isAbstract = new Boolean("true".equals(isAbs)); //$NON-NLS-1$
+			isAbstract = Boolean.valueOf("true".equals(isAbs)); //$NON-NLS-1$
 		}
 
 		// Get the command defined for the option
@@ -382,7 +382,7 @@ public class Option extends BuildObject implements IOption, IBuildPropertiesRest
 		// isForScannerDiscovery
 		String isForSD = element.getAttribute(USE_BY_SCANNER_DISCOVERY);
 		if (isForSD != null){
-			isForScannerDiscovery = new Boolean("true".equals(isForSD)); //$NON-NLS-1$
+			isForScannerDiscovery = Boolean.valueOf("true".equals(isForSD)); //$NON-NLS-1$
 		}
 
 		// Get the tooltip for the option
@@ -506,7 +506,7 @@ public class Option extends BuildObject implements IOption, IBuildPropertiesRest
 		if (element.getAttribute(IProjectType.IS_ABSTRACT) != null) {
 			String isAbs = element.getAttribute(IProjectType.IS_ABSTRACT);
 			if (isAbs != null){
-				isAbstract = new Boolean("true".equals(isAbs)); //$NON-NLS-1$
+				isAbstract = Boolean.valueOf("true".equals(isAbs)); //$NON-NLS-1$
 			}
 		}
 
@@ -524,7 +524,7 @@ public class Option extends BuildObject implements IOption, IBuildPropertiesRest
 		if (element.getAttribute(USE_BY_SCANNER_DISCOVERY) != null) {
 			String isForSD = element.getAttribute(USE_BY_SCANNER_DISCOVERY);
 			if (isForSD != null){
-				isForScannerDiscovery = new Boolean("true".equals(isForSD)); //$NON-NLS-1$
+				isForScannerDiscovery = Boolean.valueOf("true".equals(isForSD)); //$NON-NLS-1$
 			}
 		}
 
@@ -551,10 +551,10 @@ public class Option extends BuildObject implements IOption, IBuildPropertiesRest
 			case BOOLEAN:
 				// Convert the string to a boolean
 				if (element.getAttribute(VALUE) != null) {
-					value = new Boolean(element.getAttribute(VALUE));
+					value = Boolean.valueOf(element.getAttribute(VALUE));
 				}
 				if (element.getAttribute(DEFAULT_VALUE) != null) {
-					defaultValue = new Boolean(element.getAttribute(DEFAULT_VALUE));
+					defaultValue = Boolean.valueOf(element.getAttribute(DEFAULT_VALUE));
 				}
 				break;
 			case STRING:
@@ -596,7 +596,7 @@ public class Option extends BuildObject implements IOption, IBuildPropertiesRest
 						}
 						getNameMap().put(optId, SafeStringInterner.safeIntern(configElement.getAttribute(NAME)));
 						if (configElement.getAttribute(IS_DEFAULT) != null) {
-							Boolean isDefault = new Boolean(configElement.getAttribute(IS_DEFAULT));
+							Boolean isDefault = Boolean.valueOf(configElement.getAttribute(IS_DEFAULT));
 							if (isDefault.booleanValue()) {
 								defaultValue = optId;
 							}
@@ -1277,7 +1277,7 @@ public class Option extends BuildObject implements IOption, IBuildPropertiesRest
 	@Override
 	public boolean isForScannerDiscovery() {
 		if (isForScannerDiscovery == null) {
-			isForScannerDiscovery = new Boolean(superClass != null && superClass.isForScannerDiscovery());
+			isForScannerDiscovery = Boolean.valueOf(superClass != null && superClass.isForScannerDiscovery());
 		}
 		return isForScannerDiscovery;
 	}
@@ -1601,7 +1601,7 @@ public class Option extends BuildObject implements IOption, IBuildPropertiesRest
 				}
 				switch (valType) {
 				case BOOLEAN:
-					val = new Boolean(false);
+					val = Boolean.valueOf(false);
 					break;
 				case STRING:
 				case TREE:
@@ -1662,7 +1662,7 @@ public class Option extends BuildObject implements IOption, IBuildPropertiesRest
 				}
 				switch (valType) {
 				case BOOLEAN:
-					val = new Boolean(false);
+					val = Boolean.valueOf(false);
 					break;
 				case STRING:
 				case TREE:
@@ -1906,7 +1906,7 @@ public class Option extends BuildObject implements IOption, IBuildPropertiesRest
 	@Override
 	public void setValue(boolean value) throws BuildException {
 		if (/*!isExtensionElement() && */getValueType() == BOOLEAN){
-			this.value = new Boolean(value);
+			this.value = Boolean.valueOf(value);
 		} else {
 			throw new BuildException(ManagedMakeMessages.getResourceString("Option.error.bad_value_type")); //$NON-NLS-1$
 		}
@@ -2196,11 +2196,11 @@ public class Option extends BuildObject implements IOption, IBuildPropertiesRest
 					// Convert the string to a boolean
 					String val = element.getAttribute(VALUE);
 					if (val != null) {
-						value = new Boolean(val);
+						value = Boolean.valueOf(val);
 					}
 					val = element.getAttribute(DEFAULT_VALUE);
 					if (val != null) {
-						defaultValue = new Boolean(val);
+						defaultValue = Boolean.valueOf(val);
 					}
 					break;
 				case STRING:
@@ -2226,7 +2226,7 @@ public class Option extends BuildObject implements IOption, IBuildPropertiesRest
 						applicableValuesList.add(optId);
 						getCommandMap().put(optId, SafeStringInterner.safeIntern(enumElements[i].getAttribute(COMMAND)));
 						getNameMap().put(optId, SafeStringInterner.safeIntern(enumElements[i].getAttribute(NAME)));
-						Boolean isDefault = new Boolean(enumElements[i].getAttribute(IS_DEFAULT));
+						Boolean isDefault = Boolean.valueOf(enumElements[i].getAttribute(IS_DEFAULT));
 						if (isDefault.booleanValue()) {
 							defaultValue = optId;
 						}
diff --git a/build/org.eclipse.cdt.managedbuilder.core/src/org/eclipse/cdt/managedbuilder/internal/core/OptionReference.java b/build/org.eclipse.cdt.managedbuilder.core/src/org/eclipse/cdt/managedbuilder/internal/core/OptionReference.java
index 3d190081596..0f5b6ec695b 100644
--- a/build/org.eclipse.cdt.managedbuilder.core/src/org/eclipse/cdt/managedbuilder/internal/core/OptionReference.java
+++ b/build/org.eclipse.cdt.managedbuilder.core/src/org/eclipse/cdt/managedbuilder/internal/core/OptionReference.java
@@ -114,7 +114,7 @@ public class OptionReference implements IOption {
 		// value
 		switch (optValType) {
 		case BOOLEAN:
-			value = new Boolean(element.getAttribute(DEFAULT_VALUE));
+			value = Boolean.valueOf(element.getAttribute(DEFAULT_VALUE));
 			break;
 		case STRING:
 		case TREE:
@@ -143,7 +143,7 @@ public class OptionReference implements IOption {
 			for (int i = 0; i < nodes.getLength(); ++i) {
 				Node node = nodes.item(i);
 				if (node.getNodeType() == Node.ELEMENT_NODE) {
-					Boolean isBuiltIn = new Boolean(((Element)node).getAttribute(LIST_ITEM_BUILTIN));
+					Boolean isBuiltIn = Boolean.valueOf(((Element)node).getAttribute(LIST_ITEM_BUILTIN));
 					if (isBuiltIn.booleanValue()) {
 						getBuiltInList().add(((Element)node).getAttribute(LIST_ITEM_VALUE));
 					} else {
@@ -185,7 +185,7 @@ public class OptionReference implements IOption {
 			// value
 			switch (optValType) {
 			case BOOLEAN:
-				value = new Boolean(element.getAttribute(DEFAULT_VALUE));
+				value = Boolean.valueOf(element.getAttribute(DEFAULT_VALUE));
 				break;
 			case STRING:
 				value = element.getAttribute(DEFAULT_VALUE);
@@ -215,7 +215,7 @@ public class OptionReference implements IOption {
 				List<String> valueList = new ArrayList<String>();
 				IManagedConfigElement[] valueElements = element.getChildren(LIST_VALUE);
 				for (IManagedConfigElement valueElement : valueElements) {
-					Boolean isBuiltIn = new Boolean(valueElement.getAttribute(LIST_ITEM_BUILTIN));
+					Boolean isBuiltIn = Boolean.valueOf(valueElement.getAttribute(LIST_ITEM_BUILTIN));
 					if (isBuiltIn.booleanValue()) {
 						getBuiltInList().add(SafeStringInterner.safeIntern(valueElement.getAttribute(LIST_ITEM_VALUE)));
 					}
@@ -679,7 +679,7 @@ public class OptionReference implements IOption {
 	@Override
 	public void setValue(boolean value) throws BuildException {
 		if (getValueType() == BOOLEAN) {
-			this.value = new Boolean(value);
+			this.value = Boolean.valueOf(value);
 		}
 		else {
 			throw new BuildException(ManagedMakeMessages.getResourceString("Option.error.bad_value_type")); //$NON-NLS-1$
diff --git a/build/org.eclipse.cdt.managedbuilder.core/src/org/eclipse/cdt/managedbuilder/internal/core/OutputType.java b/build/org.eclipse.cdt.managedbuilder.core/src/org/eclipse/cdt/managedbuilder/internal/core/OutputType.java
index 3c8ca9403bc..7cf3cfc78f7 100644
--- a/build/org.eclipse.cdt.managedbuilder.core/src/org/eclipse/cdt/managedbuilder/internal/core/OutputType.java
+++ b/build/org.eclipse.cdt.managedbuilder.core/src/org/eclipse/cdt/managedbuilder/internal/core/OutputType.java
@@ -172,14 +172,14 @@ public class OutputType extends BuildObject implements IOutputType {
 			buildVariable = new String(outputType.buildVariable);
 		}
 		if (outputType.multipleOfType != null) {
-			multipleOfType = new Boolean(outputType.multipleOfType.booleanValue());
+			multipleOfType = Boolean.valueOf(outputType.multipleOfType.booleanValue());
 		}
 		if (outputType.primaryInputTypeId != null) {
 			primaryInputTypeId = new String(outputType.primaryInputTypeId);
 		}
 		primaryInputType = outputType.primaryInputType;
 		if (outputType.primaryOutput != null) {
-			primaryOutput = new Boolean(outputType.primaryOutput.booleanValue());
+			primaryOutput = Boolean.valueOf(outputType.primaryOutput.booleanValue());
 		}
 		if (outputType.outputPrefix != null) {
 			outputPrefix = new String(outputType.outputPrefix);
@@ -237,7 +237,7 @@ public class OutputType extends BuildObject implements IOutputType {
 		// multipleOfType
         String isMOT = element.getAttribute(IOutputType.MULTIPLE_OF_TYPE);
         if (isMOT != null){
-    		multipleOfType = new Boolean("true".equals(isMOT)); //$NON-NLS-1$
+    		multipleOfType = Boolean.valueOf("true".equals(isMOT)); //$NON-NLS-1$
         }
 
 		// primaryInputType
@@ -246,7 +246,7 @@ public class OutputType extends BuildObject implements IOutputType {
 		// primaryOutput
         String isPO = element.getAttribute(IOutputType.PRIMARY_OUTPUT);
         if (isPO != null){
-    		primaryOutput = new Boolean("true".equals(isPO)); //$NON-NLS-1$
+    		primaryOutput = Boolean.valueOf("true".equals(isPO)); //$NON-NLS-1$
         }
 
 		// outputPrefix
@@ -312,7 +312,7 @@ public class OutputType extends BuildObject implements IOutputType {
 		if (element.getAttribute(IOutputType.MULTIPLE_OF_TYPE) != null) {
 			String isMOT = element.getAttribute(IOutputType.MULTIPLE_OF_TYPE);
 			if (isMOT != null){
-				multipleOfType = new Boolean("true".equals(isMOT)); //$NON-NLS-1$
+				multipleOfType = Boolean.valueOf("true".equals(isMOT)); //$NON-NLS-1$
 			}
 		}
 
@@ -326,7 +326,7 @@ public class OutputType extends BuildObject implements IOutputType {
         if (element.getAttribute(IOutputType.PRIMARY_OUTPUT) != null) {
 			String isPO = element.getAttribute(IOutputType.PRIMARY_OUTPUT);
 			if (isPO != null){
-				primaryOutput = new Boolean("true".equals(isPO)); //$NON-NLS-1$
+				primaryOutput = Boolean.valueOf("true".equals(isPO)); //$NON-NLS-1$
 			}
         }
 
@@ -510,7 +510,7 @@ public class OutputType extends BuildObject implements IOutputType {
 	@Override
 	public void setMultipleOfType(boolean b) {
 		if (multipleOfType == null || !(b == multipleOfType.booleanValue())) {
-			multipleOfType = new Boolean(b);
+			multipleOfType = Boolean.valueOf(b);
 			setDirty(true);
 			setRebuildState(true);
 		}
@@ -820,7 +820,7 @@ public class OutputType extends BuildObject implements IOutputType {
 	@Override
 	public void setPrimaryOutput(boolean b) {
 		if (primaryOutput == null || !(b == primaryOutput.booleanValue())) {
-			primaryOutput = new Boolean(b);
+			primaryOutput = Boolean.valueOf(b);
 			setDirty(true);
 			setRebuildState(true);
 		}
diff --git a/build/org.eclipse.cdt.managedbuilder.core/src/org/eclipse/cdt/managedbuilder/internal/core/ProjectType.java b/build/org.eclipse.cdt.managedbuilder.core/src/org/eclipse/cdt/managedbuilder/internal/core/ProjectType.java
index 297bc920939..44a11bafa43 100644
--- a/build/org.eclipse.cdt.managedbuilder.core/src/org/eclipse/cdt/managedbuilder/internal/core/ProjectType.java
+++ b/build/org.eclipse.cdt.managedbuilder.core/src/org/eclipse/cdt/managedbuilder/internal/core/ProjectType.java
@@ -187,13 +187,13 @@ public class ProjectType extends BuildObject implements IProjectType, IBuildProp
 		// isAbstract
         String isAbs = element.getAttribute(IS_ABSTRACT);
         if (isAbs != null){
-    		isAbstract = new Boolean("true".equals(isAbs)); //$NON-NLS-1$
+    		isAbstract = Boolean.valueOf("true".equals(isAbs)); //$NON-NLS-1$
         }
 
 		// Is this a test project type
 		String isTestStr = element.getAttribute(IS_TEST);
         if (isTestStr != null){
-    		isTest = new Boolean("true".equals(isTestStr)); //$NON-NLS-1$
+    		isTest = Boolean.valueOf("true".equals(isTestStr)); //$NON-NLS-1$
         }
 
 		// Store the configuration element IFF there is a configuration name provider defined
@@ -382,14 +382,14 @@ public class ProjectType extends BuildObject implements IProjectType, IBuildProp
 	 */
 	@Override
 	public void setIsAbstract(boolean b) {
-		isAbstract = new Boolean(b);
+		isAbstract = Boolean.valueOf(b);
 	}
 
 	/**
 	 * Sets the isTest attribute
 	 */
 	public void setIsTest(boolean b) {
-		isTest = new Boolean(b);
+		isTest = Boolean.valueOf(b);
 	}
 
 	/*
diff --git a/build/org.eclipse.cdt.managedbuilder.core/src/org/eclipse/cdt/managedbuilder/internal/core/ResourceInfo.java b/build/org.eclipse.cdt.managedbuilder.core/src/org/eclipse/cdt/managedbuilder/internal/core/ResourceInfo.java
index 05a62621812..be2ef288ec3 100644
--- a/build/org.eclipse.cdt.managedbuilder.core/src/org/eclipse/cdt/managedbuilder/internal/core/ResourceInfo.java
+++ b/build/org.eclipse.cdt.managedbuilder.core/src/org/eclipse/cdt/managedbuilder/internal/core/ResourceInfo.java
@@ -336,7 +336,7 @@ public abstract class ResourceInfo extends BuildObject implements IResourceInfo
 			propagate(parent, option,
 					(oldVal ? Boolean.TRUE : Boolean.FALSE),
 					(value  ? Boolean.TRUE : Boolean.FALSE));
-			NotificationManager.getInstance().optionChanged(this, parent, option, new Boolean(oldVal));
+			NotificationManager.getInstance().optionChanged(this, parent, option, Boolean.valueOf(oldVal));
 		}
 		return retOpt;
 	}
diff --git a/build/org.eclipse.cdt.managedbuilder.core/src/org/eclipse/cdt/managedbuilder/internal/core/TargetPlatform.java b/build/org.eclipse.cdt.managedbuilder.core/src/org/eclipse/cdt/managedbuilder/internal/core/TargetPlatform.java
index dcf7bcf93e0..038548ef009 100644
--- a/build/org.eclipse.cdt.managedbuilder.core/src/org/eclipse/cdt/managedbuilder/internal/core/TargetPlatform.java
+++ b/build/org.eclipse.cdt.managedbuilder.core/src/org/eclipse/cdt/managedbuilder/internal/core/TargetPlatform.java
@@ -156,7 +156,7 @@ public class TargetPlatform extends BuildObject implements ITargetPlatform {
 			errorParserIds = new String(targetPlatform.errorParserIds);
 		}
 		if (targetPlatform.isAbstract != null) {
-			isAbstract = new Boolean(targetPlatform.isAbstract.booleanValue());
+			isAbstract = Boolean.valueOf(targetPlatform.isAbstract.booleanValue());
 		}
 		if (targetPlatform.osList != null) {
 			osList = new ArrayList<String>(targetPlatform.osList);
@@ -199,7 +199,7 @@ public class TargetPlatform extends BuildObject implements ITargetPlatform {
 		// isAbstract
         String isAbs = element.getAttribute(IProjectType.IS_ABSTRACT);
         if (isAbs != null){
-    		isAbstract = new Boolean("true".equals(isAbs)); //$NON-NLS-1$
+    		isAbstract = Boolean.valueOf("true".equals(isAbs)); //$NON-NLS-1$
         }
 
 		// Get the comma-separated list of valid OS
@@ -267,7 +267,7 @@ public class TargetPlatform extends BuildObject implements ITargetPlatform {
 		if (element.getAttribute(IProjectType.IS_ABSTRACT) != null) {
 			String isAbs = element.getAttribute(IProjectType.IS_ABSTRACT);
 			if (isAbs != null){
-				isAbstract = new Boolean("true".equals(isAbs)); //$NON-NLS-1$
+				isAbstract = Boolean.valueOf("true".equals(isAbs)); //$NON-NLS-1$
 			}
 		}
 
@@ -527,7 +527,7 @@ public class TargetPlatform extends BuildObject implements ITargetPlatform {
 	 */
 	@Override
 	public void setIsAbstract(boolean b) {
-		isAbstract = new Boolean(b);
+		isAbstract = Boolean.valueOf(b);
 		setDirty(true);
 	}
 
diff --git a/build/org.eclipse.cdt.managedbuilder.core/src/org/eclipse/cdt/managedbuilder/internal/core/Tool.java b/build/org.eclipse.cdt.managedbuilder.core/src/org/eclipse/cdt/managedbuilder/internal/core/Tool.java
index 511b248e1fa..2c1c3c28d9d 100644
--- a/build/org.eclipse.cdt.managedbuilder.core/src/org/eclipse/cdt/managedbuilder/internal/core/Tool.java
+++ b/build/org.eclipse.cdt.managedbuilder.core/src/org/eclipse/cdt/managedbuilder/internal/core/Tool.java
@@ -408,7 +408,7 @@ public class Tool extends HoldsOptions implements ITool, IOptionCategory, IMatch
 			errorParserIds = new String(tool.errorParserIds);
 		}
 		if (tool.isAbstract != null) {
-			isAbstract = new Boolean(tool.isAbstract.booleanValue());
+			isAbstract = Boolean.valueOf(tool.isAbstract.booleanValue());
 		}
 		if (tool.command != null) {
 			command = new String(tool.command);
@@ -435,10 +435,10 @@ public class Tool extends HoldsOptions implements ITool, IOptionCategory, IMatch
 			outputPrefix = new String(tool.outputPrefix);
 		}
 		if (tool.advancedInputCategory != null) {
-			advancedInputCategory = new Boolean(tool.advancedInputCategory.booleanValue());
+			advancedInputCategory = Boolean.valueOf(tool.advancedInputCategory.booleanValue());
 		}
 		if (tool.customBuildStep != null) {
-			customBuildStep = new Boolean(tool.customBuildStep.booleanValue());
+			customBuildStep = Boolean.valueOf(tool.customBuildStep.booleanValue());
 		}
 		if (tool.announcement != null) {
 			announcement = new String(tool.announcement);
@@ -701,7 +701,7 @@ public class Tool extends HoldsOptions implements ITool, IOptionCategory, IMatch
 		// isAbstract
         String isAbs = element.getAttribute(IProjectType.IS_ABSTRACT);
         if (isAbs != null){
-    		isAbstract = new Boolean("true".equals(isAbs)); //$NON-NLS-1$
+    		isAbstract = Boolean.valueOf("true".equals(isAbs)); //$NON-NLS-1$
         }
 
 		// Get the semicolon separated list of IDs of the error parsers
@@ -757,13 +757,13 @@ public class Tool extends HoldsOptions implements ITool, IOptionCategory, IMatch
 		// Get advancedInputCategory
         String advInput = element.getAttribute(ITool.ADVANCED_INPUT_CATEGORY);
         if (advInput != null){
-			advancedInputCategory = new Boolean("true".equals(advInput)); //$NON-NLS-1$
+			advancedInputCategory = Boolean.valueOf("true".equals(advInput)); //$NON-NLS-1$
         }
 
 		// Get customBuildStep
         String cbs = element.getAttribute(ITool.CUSTOM_BUILD_STEP);
         if (cbs != null){
-			customBuildStep = new Boolean("true".equals(cbs)); //$NON-NLS-1$
+			customBuildStep = Boolean.valueOf("true".equals(cbs)); //$NON-NLS-1$
         }
 
 		// Get the announcement text
@@ -842,7 +842,7 @@ public class Tool extends HoldsOptions implements ITool, IOptionCategory, IMatch
 		if (element.getAttribute(IProjectType.IS_ABSTRACT) != null) {
 			String isAbs = element.getAttribute(IProjectType.IS_ABSTRACT);
 			if (isAbs != null){
-				isAbstract = new Boolean("true".equals(isAbs)); //$NON-NLS-1$
+				isAbstract = Boolean.valueOf("true".equals(isAbs)); //$NON-NLS-1$
 			}
 		}
 
@@ -928,7 +928,7 @@ public class Tool extends HoldsOptions implements ITool, IOptionCategory, IMatch
 		if (element.getAttribute(ITool.ADVANCED_INPUT_CATEGORY) != null) {
 			String advInput = element.getAttribute(ITool.ADVANCED_INPUT_CATEGORY);
 			if (advInput != null){
-				advancedInputCategory = new Boolean("true".equals(advInput)); //$NON-NLS-1$
+				advancedInputCategory = Boolean.valueOf("true".equals(advInput)); //$NON-NLS-1$
 			}
 		}
 
@@ -936,7 +936,7 @@ public class Tool extends HoldsOptions implements ITool, IOptionCategory, IMatch
 		if (element.getAttribute(ITool.CUSTOM_BUILD_STEP) != null) {
 			String cbs = element.getAttribute(ITool.CUSTOM_BUILD_STEP);
 			if (cbs != null){
-				customBuildStep = new Boolean("true".equals(cbs)); //$NON-NLS-1$
+				customBuildStep = Boolean.valueOf("true".equals(cbs)); //$NON-NLS-1$
 			}
 		}
 
@@ -1673,7 +1673,7 @@ public class Tool extends HoldsOptions implements ITool, IOptionCategory, IMatch
 	 */
 	@Override
 	public void setIsAbstract(boolean b) {
-		isAbstract = new Boolean(b);
+		isAbstract = Boolean.valueOf(b);
 		setDirty(true);
 	}
 
@@ -2530,7 +2530,7 @@ public class Tool extends HoldsOptions implements ITool, IOptionCategory, IMatch
 	@Override
 	public void setAdvancedInputCategory(boolean b) {
 		if (advancedInputCategory == null || !(b == advancedInputCategory.booleanValue())) {
-			advancedInputCategory = new Boolean(b);
+			advancedInputCategory = Boolean.valueOf(b);
 			setDirty(true);
 		}
 	}
@@ -2541,7 +2541,7 @@ public class Tool extends HoldsOptions implements ITool, IOptionCategory, IMatch
 	@Override
 	public void setCustomBuildStep(boolean b) {
 		if (customBuildStep == null || !(b == customBuildStep.booleanValue())) {
-			customBuildStep = new Boolean(b);
+			customBuildStep = Boolean.valueOf(b);
 			setDirty(true);
 		}
 	}
diff --git a/build/org.eclipse.cdt.managedbuilder.core/src/org/eclipse/cdt/managedbuilder/internal/core/ToolChain.java b/build/org.eclipse.cdt.managedbuilder.core/src/org/eclipse/cdt/managedbuilder/internal/core/ToolChain.java
index e9cc15d3407..53b3994a521 100644
--- a/build/org.eclipse.cdt.managedbuilder.core/src/org/eclipse/cdt/managedbuilder/internal/core/ToolChain.java
+++ b/build/org.eclipse.cdt.managedbuilder.core/src/org/eclipse/cdt/managedbuilder/internal/core/ToolChain.java
@@ -341,7 +341,7 @@ public class ToolChain extends HoldsOptions implements IToolChain, IMatchKeyProv
 			secondaryOutputIds = new String(toolChain.secondaryOutputIds);
 		}
 		if (toolChain.isAbstract != null) {
-			isAbstract = new Boolean(toolChain.isAbstract.booleanValue());
+			isAbstract = Boolean.valueOf(toolChain.isAbstract.booleanValue());
 		}
 		if (toolChain.scannerConfigDiscoveryProfileId != null) {
 			scannerConfigDiscoveryProfileId = new String(toolChain.scannerConfigDiscoveryProfileId);
@@ -545,7 +545,7 @@ public class ToolChain extends HoldsOptions implements IToolChain, IMatchKeyProv
 		// isAbstract
 		String isAbs = element.getAttribute(IProjectType.IS_ABSTRACT);
 		if (isAbs != null){
-			isAbstract = new Boolean("true".equals(isAbs)); //$NON-NLS-1$
+			isAbstract = Boolean.valueOf("true".equals(isAbs)); //$NON-NLS-1$
 		}
 
 		// Get the semicolon separated list of IDs of the error parsers
@@ -665,7 +665,7 @@ public class ToolChain extends HoldsOptions implements IToolChain, IMatchKeyProv
 		if (element.getAttribute(IProjectType.IS_ABSTRACT) != null) {
 			String isAbs = element.getAttribute(IProjectType.IS_ABSTRACT);
 			if (isAbs != null){
-				isAbstract = new Boolean("true".equals(isAbs)); //$NON-NLS-1$
+				isAbstract = Boolean.valueOf("true".equals(isAbs)); //$NON-NLS-1$
 			}
 		}
 
@@ -1390,7 +1390,7 @@ public class ToolChain extends HoldsOptions implements IToolChain, IMatchKeyProv
 
 	@Override
 	public void setIsAbstract(boolean b) {
-		isAbstract = new Boolean(b);
+		isAbstract = Boolean.valueOf(b);
 		setDirty(true);
 	}
 
diff --git a/build/org.eclipse.cdt.managedbuilder.core/src/org/eclipse/cdt/managedbuilder/makegen/gnu/DefaultGCCDependencyCalculator2Commands.java b/build/org.eclipse.cdt.managedbuilder.core/src/org/eclipse/cdt/managedbuilder/makegen/gnu/DefaultGCCDependencyCalculator2Commands.java
index 2f097827a3c..c99a08dca26 100644
--- a/build/org.eclipse.cdt.managedbuilder.core/src/org/eclipse/cdt/managedbuilder/makegen/gnu/DefaultGCCDependencyCalculator2Commands.java
+++ b/build/org.eclipse.cdt.managedbuilder.core/src/org/eclipse/cdt/managedbuilder/makegen/gnu/DefaultGCCDependencyCalculator2Commands.java
@@ -117,7 +117,7 @@ public class DefaultGCCDependencyCalculator2Commands implements
 						new FileContextData(sourceLocation, outputLocation,
 								null, tool)).length > 0;
 
-		if (needExplicitRuleForFile) genericCommands = new Boolean(false);
+		if (needExplicitRuleForFile) genericCommands = Boolean.valueOf(false);
 	}
 
 	/**
@@ -156,7 +156,7 @@ public class DefaultGCCDependencyCalculator2Commands implements
 	 */
 	@Override
 	public boolean areCommandsGeneric() {
-		if (genericCommands == null) genericCommands = new Boolean(true);
+		if (genericCommands == null) genericCommands = Boolean.valueOf(true);
 		return genericCommands.booleanValue();
 	}
 
diff --git a/build/org.eclipse.cdt.managedbuilder.core/src/org/eclipse/cdt/managedbuilder/makegen/gnu/DefaultGCCDependencyCalculatorPreBuildCommands.java b/build/org.eclipse.cdt.managedbuilder.core/src/org/eclipse/cdt/managedbuilder/makegen/gnu/DefaultGCCDependencyCalculatorPreBuildCommands.java
index 6f02c44a3c5..6db504d1714 100644
--- a/build/org.eclipse.cdt.managedbuilder.core/src/org/eclipse/cdt/managedbuilder/makegen/gnu/DefaultGCCDependencyCalculatorPreBuildCommands.java
+++ b/build/org.eclipse.cdt.managedbuilder.core/src/org/eclipse/cdt/managedbuilder/makegen/gnu/DefaultGCCDependencyCalculatorPreBuildCommands.java
@@ -121,7 +121,7 @@ public class DefaultGCCDependencyCalculatorPreBuildCommands implements IManagedD
 						new FileContextData(sourceLocation, outputLocation,
 								null, tool)).length > 0;
 
-		if (needExplicitRuleForFile) genericCommands = new Boolean(false);
+		if (needExplicitRuleForFile) genericCommands = Boolean.valueOf(false);
 	}
 
 	/**
@@ -158,14 +158,14 @@ public class DefaultGCCDependencyCalculatorPreBuildCommands implements IManagedD
 		if (genericCommands != null) return genericCommands.booleanValue();
 		//  If the context is a Configuration, yes
 		if (buildContext instanceof IConfiguration || buildContext instanceof IFolderInfo) {
-			genericCommands = new Boolean(true);
+			genericCommands = Boolean.valueOf(true);
 			return true;
 		}
 		//  If the context is a Resource Configuration, determine if it overrides any
 		//  of its parent configuration's options that would affect dependency file
 		//  generation.
 		// TODO
-		genericCommands = new Boolean(false);
+		genericCommands = Boolean.valueOf(false);
 		return false;
 	}
 
diff --git a/build/org.eclipse.cdt.managedbuilder.core/src/org/eclipse/cdt/managedbuilder/projectconverter/UpdateManagedProject12.java b/build/org.eclipse.cdt.managedbuilder.core/src/org/eclipse/cdt/managedbuilder/projectconverter/UpdateManagedProject12.java
index 2102d71bd12..6cf70ec0696 100644
--- a/build/org.eclipse.cdt.managedbuilder.core/src/org/eclipse/cdt/managedbuilder/projectconverter/UpdateManagedProject12.java
+++ b/build/org.eclipse.cdt.managedbuilder.core/src/org/eclipse/cdt/managedbuilder/projectconverter/UpdateManagedProject12.java
@@ -373,7 +373,7 @@ class UpdateManagedProject12 {
 			try {
 				switch (newOpt.getValueType()) {
 					case IOption.BOOLEAN:
-						Boolean bool = new Boolean(optRef.getAttribute(IOption.DEFAULT_VALUE));
+						Boolean bool = Boolean.valueOf(optRef.getAttribute(IOption.DEFAULT_VALUE));
 						configuration.setOption(tool, newOpt, bool.booleanValue());
 						break;
 					case IOption.STRING:
@@ -416,7 +416,7 @@ class UpdateManagedProject12 {
 						for (int i = 0; i < nodes.getLength(); ++i) {
 							Node node = nodes.item(i);
 							if (node.getNodeType() == Node.ELEMENT_NODE) {
-								Boolean isBuiltIn = new Boolean(((Element)node).getAttribute(IOption.LIST_ITEM_BUILTIN));
+								Boolean isBuiltIn = Boolean.valueOf(((Element)node).getAttribute(IOption.LIST_ITEM_BUILTIN));
 								if (!isBuiltIn.booleanValue()) {
 									values.add(((Element)node).getAttribute(IOption.LIST_ITEM_VALUE));
 								}
diff --git a/build/org.eclipse.cdt.managedbuilder.core/src/org/eclipse/cdt/managedbuilder/projectconverter/UpdateManagedProject20.java b/build/org.eclipse.cdt.managedbuilder.core/src/org/eclipse/cdt/managedbuilder/projectconverter/UpdateManagedProject20.java
index 9b4f1e17bc4..520f5969d77 100644
--- a/build/org.eclipse.cdt.managedbuilder.core/src/org/eclipse/cdt/managedbuilder/projectconverter/UpdateManagedProject20.java
+++ b/build/org.eclipse.cdt.managedbuilder.core/src/org/eclipse/cdt/managedbuilder/projectconverter/UpdateManagedProject20.java
@@ -417,7 +417,7 @@ class UpdateManagedProject20 {
 				switch(type){
 					case IOption.BOOLEAN:{
 						if(optRef.hasAttribute(IOption.DEFAULT_VALUE)){
-							Boolean bool = new Boolean(optRef.getAttribute(IOption.DEFAULT_VALUE));
+							Boolean bool = Boolean.valueOf(optRef.getAttribute(IOption.DEFAULT_VALUE));
 							configuration.setOption(tool,option,bool.booleanValue());
 						}
 						break;
@@ -439,7 +439,7 @@ class UpdateManagedProject20 {
 						for (int j = 0; j < nodes.getLength(); ++j) {
 							Node node = nodes.item(j);
 							if (node.getNodeType() == Node.ELEMENT_NODE) {
-								Boolean isBuiltIn = new Boolean(((Element)node).getAttribute(IOption.LIST_ITEM_BUILTIN));
+								Boolean isBuiltIn = Boolean.valueOf(((Element)node).getAttribute(IOption.LIST_ITEM_BUILTIN));
 								if (!isBuiltIn.booleanValue()) {
 									values.add(((Element)node).getAttribute(IOption.LIST_ITEM_VALUE));
 								}
diff --git a/build/org.eclipse.cdt.managedbuilder.ui/src/org/eclipse/cdt/managedbuilder/ui/properties/ToolSettingsPrefStore.java b/build/org.eclipse.cdt.managedbuilder.ui/src/org/eclipse/cdt/managedbuilder/ui/properties/ToolSettingsPrefStore.java
index a9209d7886a..7a5ae729bbb 100644
--- a/build/org.eclipse.cdt.managedbuilder.ui/src/org/eclipse/cdt/managedbuilder/ui/properties/ToolSettingsPrefStore.java
+++ b/build/org.eclipse.cdt.managedbuilder.ui/src/org/eclipse/cdt/managedbuilder/ui/properties/ToolSettingsPrefStore.java
@@ -49,7 +49,7 @@ public class ToolSettingsPrefStore implements IPreferenceStore {
 	private IResourceInfo rcInfo = null;
 	private IOptionCategory optCategory;
 	private ToolListElement selectedElement;
-	private ListenerList listenerList;
+	private ListenerList<IPropertyChangeListener> listenerList;
 	private boolean dirtyFlag;
 
 	public static ToolSettingsPrefStore getDefault() {
@@ -181,10 +181,12 @@ public class ToolSettingsPrefStore implements IPreferenceStore {
 			}
 		} else {
 			Object val = getOptionValue(name);
-			if(val instanceof String)
-				return (String)val;
-			else if(val instanceof Collection)
-				return listToString((String[])((Collection)val).toArray(new String[0]));
+			if (val instanceof String) {
+				return (String) val;
+			} else if (val instanceof Collection) {
+				Collection<?> collection = (Collection<String>) val;
+				return listToString(collection.toArray(new String[collection.size()]));
+			}
 		}
 
 		return getDefaultString(name);
@@ -290,7 +292,7 @@ public class ToolSettingsPrefStore implements IPreferenceStore {
 
 	@Override
 	public void setValue(String name, boolean value) {
-		setOptionValue(name,new Boolean(value));
+		setOptionValue(name, Boolean.valueOf(value));
 	}
 
 	protected void setOptionValue(String name, Object value){
@@ -300,21 +302,21 @@ public class ToolSettingsPrefStore implements IPreferenceStore {
 			IHoldsOptions holder = (IHoldsOptions)opt[0];
 			IOption newOption = null;
 			try{
-				switch(option.getValueType()){
+				switch (option.getValueType()){
 					case IOption.STRING:
-						if(value instanceof String){
+						if (value instanceof String) {
 							newOption = rcInfo.setOption(holder, option, (String)value);
 						}
 						break;
 					case IOption.BOOLEAN:
-						if(value instanceof Boolean){
-							boolean val = ((Boolean)value).booleanValue();
+						if (value instanceof Boolean){
+							boolean val = ((Boolean) value).booleanValue();
 							newOption = rcInfo.setOption(holder,option,val);
 						}
 						break;
 					case IOption.ENUMERATED:
 					case IOption.TREE:
-						if(value instanceof String){
+						if (value instanceof String){
 							String val = (String)value;
 							String enumId = option.getId(val);
 							newOption = rcInfo.setOption(holder, option,
@@ -336,19 +338,19 @@ public class ToolSettingsPrefStore implements IPreferenceStore {
 					case IOption.UNDEF_LIBRARY_PATHS:
 					case IOption.UNDEF_LIBRARY_FILES:
 					case IOption.UNDEF_MACRO_FILES:
-						if(value instanceof String){
-							String val[] = parseString((String)value);
-							newOption = rcInfo.setOption(holder,option,val);
+						if (value instanceof String) {
+							String val[] = parseString((String) value);
+							newOption = rcInfo.setOption(holder, option, val);
 						}
 						break;
 					default:
 						break;
 				}
 
-				if(newOption != option){
+				if (newOption != option) {
 					//TODO: ???
 				}
-			} catch (BuildException e){
+			} catch (BuildException e) {
 			}
 		}
 	}
@@ -362,7 +364,7 @@ public class ToolSettingsPrefStore implements IPreferenceStore {
 	}
 
 	public static String listToString(String items[], String separator){
-		StringBuffer path = new StringBuffer(""); //$NON-NLS-1$
+		StringBuilder path = new StringBuilder();
 
 		for (int i = 0; i < items.length; i++) {
 			path.append(items[i]);
diff --git a/core/org.eclipse.cdt.core/model/org/eclipse/cdt/core/settings/model/util/CDataSerializer.java b/core/org.eclipse.cdt.core/model/org/eclipse/cdt/core/settings/model/util/CDataSerializer.java
index d674cb24ed1..2a14bda2e33 100644
--- a/core/org.eclipse.cdt.core/model/org/eclipse/cdt/core/settings/model/util/CDataSerializer.java
+++ b/core/org.eclipse.cdt.core/model/org/eclipse/cdt/core/settings/model/util/CDataSerializer.java
@@ -375,7 +375,7 @@ public class CDataSerializer {
 			setAttribute(el, PATH, path.toString());
 		}
 
-//		setAttribute(el, EXCLUDED, Boolean.valueOf(data.isExcluded()).toString());
+//		setAttribute(el, EXCLUDED, String.valueOf(data.isExcluded()));
 
 		CLanguageData lDatas[] = data.getLanguageDatas();
 		ICStorageElement child;
@@ -394,7 +394,7 @@ public class CDataSerializer {
 			setAttribute(el, PATH, path.toString());
 		}
 
-//		setAttribute(el, EXCLUDED, Boolean.valueOf(data.isExcluded()).toString());
+//		setAttribute(el, EXCLUDED, String.valueOf(data.isExcluded()));
 
 		CLanguageData lData = data.getLanguageData();
 		if(lData != null){
diff --git a/core/org.eclipse.cdt.core/model/org/eclipse/cdt/core/settings/model/util/CDataUtil.java b/core/org.eclipse.cdt.core/model/org/eclipse/cdt/core/settings/model/util/CDataUtil.java
index 75c8f95bdb6..c50bb1409c5 100644
--- a/core/org.eclipse.cdt.core/model/org/eclipse/cdt/core/settings/model/util/CDataUtil.java
+++ b/core/org.eclipse.cdt.core/model/org/eclipse/cdt/core/settings/model/util/CDataUtil.java
@@ -1114,7 +1114,7 @@ public class CDataUtil {
 	}
 
 	public static void setBoolean(ICStorageElement el, String attr, boolean value) {
-		el.setAttribute(attr, Boolean.valueOf(value).toString());
+		el.setAttribute(attr, String.valueOf(value));
 	}
 
 	public static int getInteger(ICStorageElement el, String attr, int defaultValue) {
diff --git a/core/org.eclipse.cdt.core/model/org/eclipse/cdt/internal/core/model/Binary.java b/core/org.eclipse.cdt.core/model/org/eclipse/cdt/internal/core/model/Binary.java
index 1bed0efea7a..7816d5657d5 100644
--- a/core/org.eclipse.cdt.core/model/org/eclipse/cdt/internal/core/model/Binary.java
+++ b/core/org.eclipse.cdt.core/model/org/eclipse/cdt/internal/core/model/Binary.java
@@ -110,7 +110,7 @@ public class Binary extends Openable implements IBinary {
 			if (hasDebug == null || hasChanged()) {
 				IBinaryObject obj = getBinaryObject();
 				if (obj != null) {
-					hasDebug = new Boolean(obj.hasDebug()).toString();
+					hasDebug = String.valueOf(obj.hasDebug());
 				}
 			}
 		}
@@ -199,7 +199,7 @@ public class Binary extends Openable implements IBinary {
 			if (endian == null || hasChanged()) {
 				IBinaryObject obj = getBinaryObject();
 				if (obj != null) {
-					endian = new Boolean(obj.isLittleEndian()).toString();
+					endian = String.valueOf(obj.isLittleEndian());
 				}
 			}
 		}
diff --git a/core/org.eclipse.cdt.core/parser/org/eclipse/cdt/internal/core/index/provider/IndexProviderManager.java b/core/org.eclipse.cdt.core/parser/org/eclipse/cdt/internal/core/index/provider/IndexProviderManager.java
index 72fd8aab128..eac8c6547e6 100644
--- a/core/org.eclipse.cdt.core/parser/org/eclipse/cdt/internal/core/index/provider/IndexProviderManager.java
+++ b/core/org.eclipse.cdt.core/parser/org/eclipse/cdt/internal/core/index/provider/IndexProviderManager.java
@@ -404,7 +404,7 @@ public final class IndexProviderManager implements IElementChangedListener {
 		if (!provisionMap.containsKey(key)) {
 			try {
 				ICProject cproject= CoreModel.getDefault().create(project);
-				provisionMap.put(key, new Boolean(provider.providesFor(cproject)));
+				provisionMap.put(key, Boolean.valueOf(provider.providesFor(cproject)));
 			} catch (CoreException e) {
 				CCorePlugin.log(e);
 				provisionMap.put(key, Boolean.FALSE);
diff --git a/core/org.eclipse.cdt.core/utils/org/eclipse/cdt/utils/envvar/PrefsStorableEnvironment.java b/core/org.eclipse.cdt.core/utils/org/eclipse/cdt/utils/envvar/PrefsStorableEnvironment.java
index e23c35f7193..5e61200c360 100644
--- a/core/org.eclipse.cdt.core/utils/org/eclipse/cdt/utils/envvar/PrefsStorableEnvironment.java
+++ b/core/org.eclipse.cdt.core/utils/org/eclipse/cdt/utils/envvar/PrefsStorableEnvironment.java
@@ -383,8 +383,8 @@ public class PrefsStorableEnvironment extends StorableEnvironment {
 		checkBackingSerializeInfo();
 		Map<String, IEnvironmentVariable> map = getAllVariablesMap();
 
-		element.setAttribute(ATTRIBUTE_APPEND, Boolean.valueOf(fAppend).toString());
-		element.setAttribute(ATTRIBUTE_APPEND_CONTRIBUTED, Boolean.valueOf(fAppendContributedEnv).toString());
+		element.setAttribute(ATTRIBUTE_APPEND, String.valueOf(fAppend));
+		element.setAttribute(ATTRIBUTE_APPEND_CONTRIBUTED, String.valueOf(fAppendContributedEnv));
 		if(!map.isEmpty()){
 			Iterator<IEnvironmentVariable> iter = map.values().iterator();
 			while(iter.hasNext()){
diff --git a/core/org.eclipse.cdt.core/utils/org/eclipse/cdt/utils/envvar/StorableEnvironment.java b/core/org.eclipse.cdt.core/utils/org/eclipse/cdt/utils/envvar/StorableEnvironment.java
index 69d360d44a1..c3044c9b9dc 100644
--- a/core/org.eclipse.cdt.core/utils/org/eclipse/cdt/utils/envvar/StorableEnvironment.java
+++ b/core/org.eclipse.cdt.core/utils/org/eclipse/cdt/utils/envvar/StorableEnvironment.java
@@ -130,8 +130,8 @@ public class StorableEnvironment {
 	 * @param element
 	 */
 	public void serialize(ICStorageElement element){
-		element.setAttribute(ATTRIBUTE_APPEND, Boolean.valueOf(fAppend).toString());
-		element.setAttribute(ATTRIBUTE_APPEND_CONTRIBUTED, Boolean.valueOf(fAppendContributedEnv).toString());
+		element.setAttribute(ATTRIBUTE_APPEND, String.valueOf(fAppend));
+		element.setAttribute(ATTRIBUTE_APPEND_CONTRIBUTED, String.valueOf(fAppendContributedEnv));
 		if(fVariables != null){
 			Iterator<IEnvironmentVariable> iter = fVariables.values().iterator();
 			while(iter.hasNext()){
diff --git a/core/org.eclipse.cdt.ui/src/org/eclipse/cdt/internal/ui/editor/ToggleMarkOccurrencesAction.java b/core/org.eclipse.cdt.ui/src/org/eclipse/cdt/internal/ui/editor/ToggleMarkOccurrencesAction.java
index 5e81630f560..642ce0bc3ab 100644
--- a/core/org.eclipse.cdt.ui/src/org/eclipse/cdt/internal/ui/editor/ToggleMarkOccurrencesAction.java
+++ b/core/org.eclipse.cdt.ui/src/org/eclipse/cdt/internal/ui/editor/ToggleMarkOccurrencesAction.java
@@ -11,7 +11,6 @@
  *******************************************************************************/
 package org.eclipse.cdt.internal.ui.editor;
 
-
 import org.eclipse.jface.action.IAction;
 import org.eclipse.jface.preference.IPreferenceStore;
 import org.eclipse.jface.util.IPropertyChangeListener;
@@ -26,9 +25,9 @@ import org.eclipse.cdt.ui.PreferenceConstants;
 import org.eclipse.cdt.internal.ui.CPluginImages;
 import org.eclipse.cdt.internal.ui.ICHelpContextIds;
 
-
 /**
- * A toolbar action which toggles the {@linkplain org.eclipse.cdt.ui.PreferenceConstants#EDITOR_MARK_OCCURRENCES mark occurrences preference}.
+ * A toolbar action which toggles the
+ * {@linkplain org.eclipse.cdt.ui.PreferenceConstants#EDITOR_MARK_OCCURRENCES mark occurrences preference}.
  *
  * @since 5.0
  */
@@ -46,17 +45,11 @@ public class ToggleMarkOccurrencesAction extends TextEditorAction implements IPr
 		update();
 	}
 
-	/*
-	 * @see IAction#actionPerformed
-	 */
 	@Override
 	public void run() {
 		fStore.setValue(PreferenceConstants.EDITOR_MARK_OCCURRENCES, isChecked());
 	}
 
-	/*
-	 * @see TextEditorAction#update
-	 */
 	@Override
 	public void update() {
 		ITextEditor editor= getTextEditor();
@@ -69,21 +62,15 @@ public class ToggleMarkOccurrencesAction extends TextEditorAction implements IPr
 		setEnabled(editor != null);
 	}
 
-	/*
-	 * @see TextEditorAction#setEditor(ITextEditor)
-	 */
 	@Override
 	public void setEditor(ITextEditor editor) {
-
 		super.setEditor(editor);
 
 		if (editor != null) {
-
 			if (fStore == null) {
 				fStore= CUIPlugin.getDefault().getPreferenceStore();
 				fStore.addPropertyChangeListener(this);
 			}
-
 		} else if (fStore != null) {
 			fStore.removePropertyChangeListener(this);
 			fStore= null;
@@ -92,12 +79,9 @@ public class ToggleMarkOccurrencesAction extends TextEditorAction implements IPr
 		update();
 	}
 
-	/*
-	 * @see IPropertyChangeListener#propertyChange(PropertyChangeEvent)
-	 */
 	@Override
 	public void propertyChange(PropertyChangeEvent event) {
 		if (event.getProperty().equals(PreferenceConstants.EDITOR_MARK_OCCURRENCES))
-			setChecked(Boolean.valueOf(event.getNewValue().toString()).booleanValue());
+			setChecked(Boolean.parseBoolean(event.getNewValue().toString()));
 	}
 }
diff --git a/core/org.eclipse.cdt.ui/src/org/eclipse/cdt/internal/ui/preferences/formatter/LineWrappingTabPage.java b/core/org.eclipse.cdt.ui/src/org/eclipse/cdt/internal/ui/preferences/formatter/LineWrappingTabPage.java
index 60c6732d5d6..f614aee927a 100644
--- a/core/org.eclipse.cdt.ui/src/org/eclipse/cdt/internal/ui/preferences/formatter/LineWrappingTabPage.java
+++ b/core/org.eclipse.cdt.ui/src/org/eclipse/cdt/internal/ui/preferences/formatter/LineWrappingTabPage.java
@@ -257,9 +257,9 @@ public class LineWrappingTabPage extends FormatterTabPage {
             try {
                 wrappingStyle= new Integer(DefaultCodeFormatterConstants.getWrappingStyle(value));
                 indentStyle= new Integer(DefaultCodeFormatterConstants.getIndentStyle(value));
-                forceWrapping= new Boolean(DefaultCodeFormatterConstants.getForceWrapping(value));
+                forceWrapping= Boolean.valueOf(DefaultCodeFormatterConstants.getForceWrapping(value));
             } catch (IllegalArgumentException e) {
-				forceWrapping= new Boolean(false);
+				forceWrapping= Boolean.valueOf(false);
 				indentStyle= new Integer(DefaultCodeFormatterConstants.INDENT_DEFAULT);
 				wrappingStyle= new Integer(DefaultCodeFormatterConstants.WRAP_NO_SPLIT);
 			} 
diff --git a/core/org.eclipse.cdt.ui/src/org/eclipse/cdt/ui/actions/CustomFiltersActionGroup.java b/core/org.eclipse.cdt.ui/src/org/eclipse/cdt/ui/actions/CustomFiltersActionGroup.java
index 425c024c1dd..1e97df737fd 100644
--- a/core/org.eclipse.cdt.ui/src/org/eclipse/cdt/ui/actions/CustomFiltersActionGroup.java
+++ b/core/org.eclipse.cdt.ui/src/org/eclipse/cdt/ui/actions/CustomFiltersActionGroup.java
@@ -284,7 +284,7 @@ public class CustomFiltersActionGroup extends ActionGroup {
 		fLRUFilterIdsStack.remove(filterId);
 		fLRUFilterIdsStack.add(0, filterId);
 
-		fEnabledFilterIds.put(filterId, new Boolean(state));
+		fEnabledFilterIds.put(filterId, Boolean.valueOf(state));
 		storeViewDefaults();
 
 		updateViewerFilters(true);
@@ -423,7 +423,7 @@ public class CustomFiltersActionGroup extends ActionGroup {
 		fEnabledFilterIds= new HashMap<String, Boolean>(filterDescs.length);
 		for (FilterDescriptor filterDesc : filterDescs) {
 			String id= filterDesc.getId();
-			Boolean isEnabled= new Boolean(filterDesc.isEnabled());
+			Boolean isEnabled= Boolean.valueOf(filterDesc.isEnabled());
 			//if (fEnabledFilterIds.containsKey(id))
 			//	CUIPlugin.log(new Status("WARNING: Duplicate id for extension-point \"org.eclipse.jdt.ui.CElementFilters\"")); //$NON-NLS-1$
 			fEnabledFilterIds.put(id, isEnabled);
@@ -523,7 +523,7 @@ public class CustomFiltersActionGroup extends ActionGroup {
 		Iterator<String> iter= fEnabledFilterIds.keySet().iterator();
 		while (iter.hasNext()) {
 			String id= iter.next();
-			Boolean isEnabled= new Boolean(store.getBoolean(id));
+			Boolean isEnabled= Boolean.valueOf(store.getBoolean(id));
 			fEnabledFilterIds.put(id, isEnabled);
 		}
 
@@ -577,7 +577,7 @@ public class CustomFiltersActionGroup extends ActionGroup {
 	 */
 	public void saveState(IMemento memento) {
 		IMemento customFilters= memento.createChild(TAG_CUSTOM_FILTERS);
-		customFilters.putString(TAG_USER_DEFINED_PATTERNS_ENABLED, new Boolean(fUserDefinedPatternsEnabled).toString());
+		customFilters.putString(TAG_USER_DEFINED_PATTERNS_ENABLED, String.valueOf(fUserDefinedPatternsEnabled));
 		saveUserDefinedPatterns(customFilters);
 		saveXmlDefinedFilters(customFilters);
 		saveLRUFilters(customFilters);
@@ -671,7 +671,7 @@ public class CustomFiltersActionGroup extends ActionGroup {
 			IMemento[] children= xmlDefinedFilters.getChildren(TAG_CHILD);
 			for (IMemento element : children) {
 				String id= element.getString(TAG_FILTER_ID);
-				Boolean isEnabled= new Boolean(element.getString(TAG_IS_ENABLED));
+				Boolean isEnabled= Boolean.valueOf(element.getString(TAG_IS_ENABLED));
 				fEnabledFilterIds.put(id, isEnabled);
 			}
 		}
diff --git a/core/org.eclipse.cdt.ui/templateengine/org/eclipse/cdt/ui/templateengine/uitree/UIElementTreeBuilderHelper.java b/core/org.eclipse.cdt.ui/templateengine/org/eclipse/cdt/ui/templateengine/uitree/UIElementTreeBuilderHelper.java
index e228370880e..41ee8777539 100644
--- a/core/org.eclipse.cdt.ui/templateengine/org/eclipse/cdt/ui/templateengine/uitree/UIElementTreeBuilderHelper.java
+++ b/core/org.eclipse.cdt.ui/templateengine/org/eclipse/cdt/ui/templateengine/uitree/UIElementTreeBuilderHelper.java
@@ -101,11 +101,11 @@ public class UIElementTreeBuilderHelper implements IUIElementTreeBuilderHelper {
 		String id= uiAttributes.get(UIElement.ID);
 		String type= uiAttributes.get(UIElement.TYPE);
 
-		if (type == null || type.length()==0 ) {
+		if (type == null || type.length() == 0) {
 			return null;
 		}
 
-		if (new Boolean(uiAttributes.get(InputUIElement.HIDDEN)).booleanValue()) {
+		if (Boolean.parseBoolean(uiAttributes.get(InputUIElement.HIDDEN))) {
 			return null;
 		}
 
@@ -116,19 +116,19 @@ public class UIElementTreeBuilderHelper implements IUIElementTreeBuilderHelper {
 		} else if (type.equalsIgnoreCase(InputUIElement.SELECTTYPE)) {
 			String defaultValue= element.getAttribute(InputUIElement.DEFAULT);
 
-			Map<String,String> value2name= new LinkedHashMap<String,String>();
-			for(Element item : TemplateEngine.getChildrenOfElement(element)) {
+			Map<String, String> value2name= new LinkedHashMap<>();
+			for (Element item : TemplateEngine.getChildrenOfElement(element)) {
 				String label= item.getAttribute(InputUIElement.COMBOITEM_LABEL); // item displayed in Combo
 				String value= item.getAttribute(InputUIElement.COMBOITEM_NAME); // value stored when its selected
-				if(value.length() == 0) {
+				if (value.length() == 0) {
 					value= item.getAttribute(InputUIElement.COMBOITEM_VALUE);
 				}
-				if(label==null || value==null) {
+				if (label == null || value == null) {
 					String msg = MessageFormat.format(Messages.getString("UIElementTreeBuilderHelper.InvalidEmptyLabel"), //$NON-NLS-1$
 							new Object[] {id});
 					CUIPlugin.log(TEMPLATE_ENGINE_ERROR, new CoreException(new Status(IStatus.ERROR, CUIPlugin.PLUGIN_ID, msg)));
 				} else {
-					if(value2name.put(value, label)!=null) {
+					if (value2name.put(value, label) != null) {
 						String msg = MessageFormat.format(Messages.getString("UIElementTreeBuilderHelper.InvalidNonUniqueValue"), //$NON-NLS-1$
 								new Object[] {value, id});
 						CUIPlugin.log(TEMPLATE_ENGINE_ERROR, new CoreException(new Status(IStatus.ERROR, CUIPlugin.PLUGIN_ID, msg)));
diff --git a/core/org.eclipse.cdt.ui/templateengine/org/eclipse/cdt/ui/templateengine/uitree/uiwidgets/UIBooleanWidget.java b/core/org.eclipse.cdt.ui/templateengine/org/eclipse/cdt/ui/templateengine/uitree/uiwidgets/UIBooleanWidget.java
index 534c4d85830..e51b005e01c 100644
--- a/core/org.eclipse.cdt.ui/templateengine/org/eclipse/cdt/ui/templateengine/uitree/uiwidgets/UIBooleanWidget.java
+++ b/core/org.eclipse.cdt.ui/templateengine/org/eclipse/cdt/ui/templateengine/uitree/uiwidgets/UIBooleanWidget.java
@@ -74,7 +74,7 @@ public class UIBooleanWidget extends InputUIElement {
 	 */
 	@Override
 	public void setValues(Map<String, String> valueMap) {
-		booleanValue = new Boolean(valueMap.get(uiAttributes.get(UIElement.ID))).booleanValue();
+		booleanValue = Boolean.valueOf(valueMap.get(uiAttributes.get(UIElement.ID))).booleanValue();
 	}
 
 	/*
@@ -102,7 +102,7 @@ public class UIBooleanWidget extends InputUIElement {
 		booleanContainer.setLayoutData(gridcData);
 		button = new Button(booleanContainer, SWT.CHECK);
 		button.setData(".uid", uiAttributes.get(UIElement.ID)); //$NON-NLS-1$
-		button.setSelection(new Boolean(booleanValue).booleanValue());
+		button.setSelection(Boolean.valueOf(booleanValue).booleanValue());
 		button.addSelectionListener(new SelectionAdapter() {
 			@Override
 			public void widgetSelected(SelectionEvent e) {
diff --git a/debug/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/internal/core/RegisterGroupsPersistance.java b/debug/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/internal/core/RegisterGroupsPersistance.java
index 2a811c7b9a8..ac3b737b0a8 100644
--- a/debug/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/internal/core/RegisterGroupsPersistance.java
+++ b/debug/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/internal/core/RegisterGroupsPersistance.java
@@ -242,7 +242,7 @@ public class RegisterGroupsPersistance {
 		Document document = DebugPlugin.newDocument();
 		Element element = document.createElement(ELEMENT_REGISTER_GROUP);
 		element.setAttribute(ATTR_REGISTER_GROUP_NAME, group.getName());
-		element.setAttribute(ATTR_REGISTER_GROUP_ENABLED, Boolean.valueOf(group.isEnabled()).toString());
+		element.setAttribute(ATTR_REGISTER_GROUP_ENABLED, String.valueOf(group.isEnabled()));
 		IRegisterDescriptor[] registerDescriptors = group.getChildren();
 		for (int i = 0; i < registerDescriptors.length; ++i) {
 			Element child = document.createElement(ELEMENT_REGISTER);
diff --git a/debug/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/internal/core/sourcelookup/CDirectorySourceLocation.java b/debug/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/internal/core/sourcelookup/CDirectorySourceLocation.java
index 7db9452a4b8..a39dbc8e58a 100644
--- a/debug/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/internal/core/sourcelookup/CDirectorySourceLocation.java
+++ b/debug/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/internal/core/sourcelookup/CDirectorySourceLocation.java
@@ -284,7 +284,7 @@ public class CDirectorySourceLocation implements IDirectorySourceLocation {
     		node.setAttribute(ATTR_DIRECTORY, getDirectory().toOSString());
     		if (getAssociation() != null)
     			node.setAttribute(ATTR_ASSOCIATION, getAssociation().toOSString());
-    		node.setAttribute(ATTR_SEARCH_SUBFOLDERS, Boolean.valueOf(searchSubfolders()).toString());
+    		node.setAttribute(ATTR_SEARCH_SUBFOLDERS, String.valueOf(searchSubfolders()));
 			return CDebugUtils.serializeDocument(document);
         } catch (ParserConfigurationException e) {
         	ex = e;
diff --git a/debug/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/internal/core/sourcelookup/CProjectSourceLocation.java b/debug/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/internal/core/sourcelookup/CProjectSourceLocation.java
index 3815368ee17..6b6b3bf596e 100644
--- a/debug/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/internal/core/sourcelookup/CProjectSourceLocation.java
+++ b/debug/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/internal/core/sourcelookup/CProjectSourceLocation.java
@@ -211,7 +211,7 @@ public class CProjectSourceLocation implements IProjectSourceLocation {
             Element node = document.createElement(ELEMENT_NAME);
             document.appendChild(node);
     		node.setAttribute(ATTR_PROJECT, getProject().getName());
-    		node.setAttribute(ATTR_GENERIC, Boolean.valueOf(isGeneric()).toString());
+    		node.setAttribute(ATTR_GENERIC, String.valueOf(isGeneric()));
 			return CDebugUtils.serializeDocument(document);
         } catch (ParserConfigurationException e) {
         	ex = e;
diff --git a/debug/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/internal/core/sourcelookup/CSourceLocator.java b/debug/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/internal/core/sourcelookup/CSourceLocator.java
index b5665a74b0b..48d697599f1 100644
--- a/debug/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/internal/core/sourcelookup/CSourceLocator.java
+++ b/debug/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/internal/core/sourcelookup/CSourceLocator.java
@@ -276,7 +276,7 @@ public class CSourceLocator implements ICSourceLocator, IPersistableSourceLocato
 			ICSourceLocation[] locations = getSourceLocations();
 			saveDisabledGenericSourceLocations(locations, document, node);
 			saveAdditionalSourceLocations(locations, document, node);
-			node.setAttribute(ATTR_DUPLICATE_FILES, Boolean.valueOf(searchForDuplicateFiles()).toString());
+			node.setAttribute(ATTR_DUPLICATE_FILES, String.valueOf(searchForDuplicateFiles()));
 			return CDebugUtils.serializeDocument(document);
 		} catch (ParserConfigurationException e) {
 			ex = e;
diff --git a/debug/org.eclipse.cdt.debug.ui/src/org/eclipse/cdt/debug/internal/ui/breakpoints/CBreakpointPreferenceStore.java b/debug/org.eclipse.cdt.debug.ui/src/org/eclipse/cdt/debug/internal/ui/breakpoints/CBreakpointPreferenceStore.java
index 66cf699e1ae..55cae377932 100644
--- a/debug/org.eclipse.cdt.debug.ui/src/org/eclipse/cdt/debug/internal/ui/breakpoints/CBreakpointPreferenceStore.java
+++ b/debug/org.eclipse.cdt.debug.ui/src/org/eclipse/cdt/debug/internal/ui/breakpoints/CBreakpointPreferenceStore.java
@@ -351,9 +351,9 @@ public class CBreakpointPreferenceStore implements IPersistentPreferenceStore {
     public void setValue(String name, boolean value) {
         boolean oldValue = getBoolean(name);
         if (oldValue != value) {
-            fProperties.put( name, new Boolean(value) );
+            fProperties.put( name, Boolean.valueOf(value) );
             setDirty(true);
-            firePropertyChangeEvent(name, new Boolean(oldValue), new Boolean(value) );
+            firePropertyChangeEvent(name, Boolean.valueOf(oldValue), Boolean.valueOf(value) );
         }
     }
 
diff --git a/dsf-gdb/org.eclipse.cdt.dsf.gdb/src/org/eclipse/cdt/dsf/mi/service/MIBreakpointDMData.java b/dsf-gdb/org.eclipse.cdt.dsf.gdb/src/org/eclipse/cdt/dsf/mi/service/MIBreakpointDMData.java
index adefd1b13b0..7bf6fd1dd48 100644
--- a/dsf-gdb/org.eclipse.cdt.dsf.gdb/src/org/eclipse/cdt/dsf/mi/service/MIBreakpointDMData.java
+++ b/dsf-gdb/org.eclipse.cdt.dsf.gdb/src/org/eclipse/cdt/dsf/mi/service/MIBreakpointDMData.java
@@ -99,7 +99,7 @@ public class MIBreakpointDMData implements IBreakpointDMData {
 				fProperties.put(MIBreakpoints.ADDRESS,         dsfMIBreakpoint.getAddress());
 				fProperties.put(MIBreakpoints.CONDITION,       dsfMIBreakpoint.getCondition());
 				fProperties.put(MIBreakpoints.IGNORE_COUNT,    dsfMIBreakpoint.getIgnoreCount());
-				fProperties.put(MIBreakpoints.IS_ENABLED,      new Boolean(dsfMIBreakpoint.isEnabled()));
+				fProperties.put(MIBreakpoints.IS_ENABLED,      Boolean.valueOf(dsfMIBreakpoint.isEnabled()));
 				fProperties.put(MIBreakpoints.COMMANDS,        dsfMIBreakpoint.getCommands());
 	
 				// MI-specific breakpoint attributes
@@ -108,8 +108,8 @@ public class MIBreakpointDMData implements IBreakpointDMData {
 				fProperties.put(THREAD_ID,    dsfMIBreakpoint.getThreadId());
 				fProperties.put(FULL_NAME,    dsfMIBreakpoint.getFullName());
 				fProperties.put(HITS,         dsfMIBreakpoint.getTimes());
-				fProperties.put(IS_TEMPORARY, new Boolean(dsfMIBreakpoint.isTemporary()));
-				fProperties.put(IS_HARDWARE,  new Boolean(dsfMIBreakpoint.isHardware()));
+				fProperties.put(IS_TEMPORARY, Boolean.valueOf(dsfMIBreakpoint.isTemporary()));
+				fProperties.put(IS_HARDWARE,  Boolean.valueOf(dsfMIBreakpoint.isHardware()));
 				fProperties.put(LOCATION,     formatLocation());
 				break;
 			}
@@ -137,7 +137,7 @@ public class MIBreakpointDMData implements IBreakpointDMData {
 				fProperties.put(MIBreakpoints.ADDRESS,         dsfMIBreakpoint.getAddress());
 				fProperties.put(MIBreakpoints.CONDITION,       dsfMIBreakpoint.getCondition());
 				fProperties.put(MIBreakpoints.PASS_COUNT,      dsfMIBreakpoint.getPassCount());
-				fProperties.put(MIBreakpoints.IS_ENABLED,      new Boolean(dsfMIBreakpoint.isEnabled()));
+				fProperties.put(MIBreakpoints.IS_ENABLED,      Boolean.valueOf(dsfMIBreakpoint.isEnabled()));
 				fProperties.put(MIBreakpoints.COMMANDS,        dsfMIBreakpoint.getCommands());
 	
 				// MI-specific breakpoint attributes
@@ -146,8 +146,8 @@ public class MIBreakpointDMData implements IBreakpointDMData {
 				fProperties.put(THREAD_ID,    dsfMIBreakpoint.getThreadId());
 				fProperties.put(FULL_NAME,    dsfMIBreakpoint.getFullName());
 				fProperties.put(HITS,         dsfMIBreakpoint.getTimes());
-				fProperties.put(IS_TEMPORARY, new Boolean(dsfMIBreakpoint.isTemporary()));
-				fProperties.put(IS_HARDWARE,  new Boolean(dsfMIBreakpoint.isHardware()));
+				fProperties.put(IS_TEMPORARY, Boolean.valueOf(dsfMIBreakpoint.isTemporary()));
+				fProperties.put(IS_HARDWARE,  Boolean.valueOf(dsfMIBreakpoint.isHardware()));
 				fProperties.put(LOCATION,     formatLocation());
 				break;
 			}
@@ -162,7 +162,7 @@ public class MIBreakpointDMData implements IBreakpointDMData {
 				fProperties.put(MIBreakpoints.ADDRESS,         dsfMIBreakpoint.getAddress());
 				fProperties.put(MIBreakpoints.CONDITION,       dsfMIBreakpoint.getCondition());
 				fProperties.put(MIBreakpoints.PRINTF_STRING,   dsfMIBreakpoint.getPrintfString());
-				fProperties.put(MIBreakpoints.IS_ENABLED,      new Boolean(dsfMIBreakpoint.isEnabled()));
+				fProperties.put(MIBreakpoints.IS_ENABLED,      Boolean.valueOf(dsfMIBreakpoint.isEnabled()));
 				fProperties.put(MIBreakpoints.COMMANDS,        dsfMIBreakpoint.getCommands());
 	
 				// MI-specific breakpoint attributes
@@ -171,8 +171,8 @@ public class MIBreakpointDMData implements IBreakpointDMData {
 				fProperties.put(THREAD_ID,    dsfMIBreakpoint.getThreadId());
 				fProperties.put(FULL_NAME,    dsfMIBreakpoint.getFullName());
 				fProperties.put(HITS,         dsfMIBreakpoint.getTimes());
-				fProperties.put(IS_TEMPORARY, new Boolean(dsfMIBreakpoint.isTemporary()));
-				fProperties.put(IS_HARDWARE,  new Boolean(dsfMIBreakpoint.isHardware()));
+				fProperties.put(IS_TEMPORARY, Boolean.valueOf(dsfMIBreakpoint.isTemporary()));
+				fProperties.put(IS_HARDWARE,  Boolean.valueOf(dsfMIBreakpoint.isHardware()));
 				fProperties.put(LOCATION,     formatLocation());
 				break;
 			}