Row Class
Row containing data for a table.
Methods
Method | Description |
---|---|
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
Property | Description |
---|---|
Fields | Gets the fields contained by this row. |
Item | Gets or sets the value of a particular field in the row. |
Number | Gets the unique number for the row. |
Operation | Gets or sets the row transform operation. |
SourceLineNumbers | Gets the source file and line number for the row. |
Table | Gets the table this row belongs to. |
TableDefinition | Gets the table definition for this row. |
WixToolset.Data.dll
version 5.0.2+aa65968c419420d32e3e1b647aea0082f5ca5b78
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
Parameter | Type | Description |
---|---|---|
field | int | field index. |
value | System.Object | Value 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
Parameter | Type | Description |
---|---|---|
target | Row | Row 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
Parameter | Type | Description |
---|---|---|
delimiter | System.Char | Delimiter 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
Parameter | Type | Description |
---|---|---|
delimiter | System.Char | Delimiter character for multiple column primary keys. |
nullReplacement | string | String 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
Parameter | Type | Description |
---|---|---|
field | int | Index 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
Parameter | Type | Description |
---|---|---|
field | int | Index 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
Parameter | Type | Description |
---|---|---|
row | Row | Row 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
Parameter | Type | Description |
---|---|---|
field | int | field 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.