// 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.Data.WindowsInstaller.Rows
{
using WixToolset.Data.Tuples;
///
/// Specialization of a row for the WixChain table.
///
public sealed class WixChainRow : Row
{
///
/// Creates a WixChain row that does not belong to a table.
///
/// Original source lines for this row.
/// TableDefinition this row belongs to and should get its column definitions from.
public WixChainRow(SourceLineNumber sourceLineNumbers, TableDefinition tableDef) :
base(sourceLineNumbers, tableDef)
{
}
///
/// Creates a WixChainRow row that belongs to a table.
///
/// Original source lines for this row.
/// Table this row belongs to and should get its column definitions from.
public WixChainRow(SourceLineNumber sourceLineNumbers, Table table) :
base(sourceLineNumbers, table)
{
}
///
/// Gets or sets the raw chain attributes.
///
public WixChainAttributes Attributes
{
get { return (WixChainAttributes)this.Fields[0].Data; }
set { this.Fields[0].Data = value; }
}
///
/// Gets the disable rollback state of a chain.
///
public bool DisableRollback
{
get { return 0 != (this.Attributes & WixChainAttributes.DisableRollback); }
}
///
/// Gets disable system restore state of a chain.
///
public bool DisableSystemRestore
{
get { return 0 != (this.Attributes & WixChainAttributes.DisableSystemRestore); }
}
///
/// Gets parallel cache of a chain.
///
public bool ParallelCache
{
get { return 0 != (this.Attributes & WixChainAttributes.ParallelCache); }
}
}
}