protected virtual string GetDefaultOutputPath(string configurationName, string platformName)
{
if (configurationName == null)
throw new ArgumentNullException("configurationName");
if (platformName == null)
throw new ArgumentNullException("platformName");
if (string.IsNullOrEmpty(configurationName))
throw new ArgumentException("configurationName cannot be null or empty");
if (string.IsNullOrEmpty(platformName))
throw new ArgumentException("platformName cannot be null or empty");
//Contract.Ensures(!string.IsNullOrEmpty(Contract.Result<string>()));
string outputBasePath = ProjectManager.OutputBaseRelativePath;
if (outputBasePath[outputBasePath.Length - 1] == Path.DirectorySeparatorChar || outputBasePath[outputBasePath.Length - 1] == Path.AltDirectorySeparatorChar)
outputBasePath = Path.GetDirectoryName(outputBasePath);
string platformProperty = GetPlatformPropertyFromPlatformName(platformName);
if (!string.Equals(platformProperty, ProjectFileValues.AnyCPU, StringComparison.OrdinalIgnoreCase))
outputBasePath = Path.Combine(outputBasePath, platformProperty);
return Path.Combine(outputBasePath, configurationName) + Path.DirectorySeparatorChar;
}