// Copyright (c) .NET Foundation and contributors. All rights reserved. Licensed under the Microsoft Reciprocal License. See LICENSE.TXT file in the project root for full license information.
namespace WixToolset.Core
{
using System;
using System.Diagnostics.CodeAnalysis;
///
/// Summary information values for the CharCount property in transforms.
///
[Flags]
[SuppressMessage("Microsoft.Naming", "CA1711:IdentifiersShouldNotHaveIncorrectSuffix")]
public enum TransformFlags
{
/// Ignore error when adding a row that exists.
ErrorAddExistingRow = 0x1,
/// Ignore error when deleting a row that does not exist.
ErrorDeleteMissingRow = 0x2,
/// Ignore error when adding a table that exists.
ErrorAddExistingTable = 0x4,
/// Ignore error when deleting a table that does not exist.
ErrorDeleteMissingTable = 0x8,
/// Ignore error when updating a row that does not exist.
ErrorUpdateMissingRow = 0x10,
/// Ignore error when transform and database code pages do not match, and their code pages are neutral.
ErrorChangeCodePage = 0x20,
/// Default language must match base database.
ValidateLanguage = 0x10000,
/// Product must match base database.
ValidateProduct = 0x20000,
/// Check major version only.
ValidateMajorVersion = 0x80000,
/// Check major and minor versions only.
ValidateMinorVersion = 0x100000,
/// Check major, minor, and update versions.
ValidateUpdateVersion = 0x200000,
/// Installed version lt base version.
ValidateNewLessBaseVersion = 0x400000,
/// Installed version lte base version.
ValidateNewLessEqualBaseVersion = 0x800000,
/// Installed version eq base version.
ValidateNewEqualBaseVersion = 0x1000000,
/// Installed version gte base version.
ValidateNewGreaterEqualBaseVersion = 0x2000000,
/// Installed version gt base version.
ValidateNewGreaterBaseVersion = 0x4000000,
/// UpgradeCode must match base database.
ValidateUpgradeCode = 0x8000000,
/// Masks all version checks on ProductVersion.
ProductVersionMask = ValidateMajorVersion | ValidateMinorVersion | ValidateUpdateVersion,
/// Masks all operations on ProductVersion.
ProductVersionOperatorMask = ValidateNewLessBaseVersion | ValidateNewLessEqualBaseVersion | ValidateNewEqualBaseVersion | ValidateNewGreaterEqualBaseVersion | ValidateNewGreaterBaseVersion,
/// Default value for instance transforms.
InstanceTransformDefault = ErrorAddExistingRow | ErrorDeleteMissingRow | ErrorAddExistingTable | ErrorDeleteMissingTable | ErrorUpdateMissingRow | ErrorChangeCodePage | ValidateProduct | ValidateUpdateVersion | ValidateNewGreaterEqualBaseVersion,
/// Default value for language transforms.
LanguageTransformDefault = ErrorAddExistingRow | ErrorDeleteMissingRow | ErrorAddExistingTable | ErrorDeleteMissingTable | ErrorUpdateMissingRow | ErrorChangeCodePage | ValidateProduct,
/// Default value for patch transforms.
PatchTransformDefault = ErrorAddExistingRow | ErrorDeleteMissingRow | ErrorAddExistingTable | ErrorDeleteMissingTable | ErrorUpdateMissingRow | ValidateProduct | ValidateUpdateVersion | ValidateNewEqualBaseVersion | ValidateUpgradeCode,
}
}