Skip to main content

Row Class

Row containing data for a table.

Methods

MethodDescription
BestEffortSetField(field, value)Sets the value of a particular field in the row without validating.
CopyTo(target)Copies this row to the target row.
FieldAsInteger()Gets the field as an integer.
FieldAsNullableInteger()Gets the field as an integer that could be null.
FieldAsString()Gets the field as a string.
GetKey()Get the value used to represent the row in a keyed row collection.
GetPrimaryKey(delimiter)Get the primary key of this row.
GetPrimaryKey(delimiter, nullReplacement)Get the primary key of this row.
IsColumnEmpty(field)Returns true if the specified field is null or an empty string.
IsColumnNull(field)Returns true if the specified field is null.
IsIdentical(row)Tests if the passed in row is identical.
ToString()Returns a string representation of the Row.

Properties

PropertyDescription
FieldsGets the fields contained by this row.
ItemGets or sets the value of a particular field in the row.
NumberGets the unique number for the row.
OperationGets or sets the row transform operation.
SourceLineNumbersGets the source file and line number for the row.
TableGets the table this row belongs to.
TableDefinitionGets the table definition for this row.

WixToolset.Data.dll version 5.0.0+41e11442b2ca93e444b60213b5ae99dcbab787d8

BestEffortSetField(field, value) Method

Sets the value of a particular field in the row without validating.

Declaration

public bool BestEffortSetField(
int field,
System.Object value
)

Parameters

ParameterTypeDescription
fieldintfield index.
valueSystem.ObjectValue of a field in the row.

Return value

bool True if successful, false if validation failed.

CopyTo(target) Method

Copies this row to the target row.

Declaration

public void CopyTo(
Row target
)

Parameters

ParameterTypeDescription
targetRowRow to copy data to.

FieldAsInteger() Method

Gets the field as an integer.

Declaration

public int FieldAsInteger()

Return value

int Field's data as an integer.

FieldAsNullableInteger() Method

Gets the field as an integer that could be null.

Declaration

public System.Nullable<System.Int32> FieldAsNullableInteger()

Return value

System.Nullable<System.Int32> Field's data as an integer that could be null.

FieldAsString() Method

Gets the field as a string.

Declaration

public string FieldAsString()

Return value

string Field's data as a string.

GetKey() Method

Get the value used to represent the row in a keyed row collection.

Declaration

public string GetKey()

Return value

string Primary key or row number if no primary key is available.

GetPrimaryKey(delimiter) Method

Get the primary key of this row.

Declaration

public string GetPrimaryKey(
System.Char delimiter
)

Parameters

ParameterTypeDescription
delimiterSystem.CharDelimiter character for multiple column primary keys.

Return value

string The primary key or null if the row's table has no primary key columns.

GetPrimaryKey(delimiter, nullReplacement) Method

Get the primary key of this row.

Declaration

public string GetPrimaryKey(
System.Char delimiter,
string nullReplacement
)

Parameters

ParameterTypeDescription
delimiterSystem.CharDelimiter character for multiple column primary keys.
nullReplacementstringString to represent null values in the primary key.

Return value

string The primary key or null if the row's table has no primary key columns.

IsColumnEmpty(field) Method

Returns true if the specified field is null or an empty string.

Declaration

public bool IsColumnEmpty(
int field
)

Parameters

ParameterTypeDescription
fieldintIndex of the field to check.

Return value

bool true if the specified field is null or an empty string, false otherwise.

IsColumnNull(field) Method

Returns true if the specified field is null.

Declaration

public bool IsColumnNull(
int field
)

Parameters

ParameterTypeDescription
fieldintIndex of the field to check.

Return value

bool true if the specified field is null, false otherwise.

IsIdentical(row) Method

Tests if the passed in row is identical.

Declaration

public bool IsIdentical(
Row row
)

Parameters

ParameterTypeDescription
rowRowRow to compare against.

Return value

bool True if two rows are identical.

ToString() Method

Returns a string representation of the Row.

Declaration

public string ToString()

Return value

string A string representation of the Row.

Fields Property

Gets the fields contained by this row.

Declaration

public Field[] Fields { get; set; } 

Item Property

Gets or sets the value of a particular field in the row.

Declaration

public System.Object Item[
int field
] { get; set; }

Parameters

ParameterTypeDescription
fieldintfield index.

Number Property

Gets the unique number for the row.

Declaration

public System.Int64 Number { get; set; } 

Operation Property

Gets or sets the row transform operation.

Declaration

public RowOperation Operation { get; set; } 

SourceLineNumbers Property

Gets the source file and line number for the row.

Declaration

public WixToolset.Data.SourceLineNumber SourceLineNumbers { get; set; } 

Table Property

Gets the table this row belongs to.

Declaration

public Table Table { get; set; } 

TableDefinition Property

Gets the table definition for this row.

Declaration

public TableDefinition TableDefinition { get; set; } 

Remarks

A Row always has a TableDefinition, even if the Row does not belong to a Table.