Class CustomTableRow
Inheritance
Inherited Members
Namespace: Mediachase.BusinessFoundation.Data.Sql
Assembly: Mediachase.BusinessFoundation.Data.dll
Version: 13.30.0Syntax
public class CustomTableRow
Constructors
CustomTableRow(Table)
Initializes a new instance of the CustomTableRow class.
Declaration
public CustomTableRow(Table table)
Parameters
Type | Name | Description |
---|---|---|
Table | table | The table. |
CustomTableRow(Table, PrimaryKeyId)
Initializes a new instance of the CustomTableRow class.
Declaration
public CustomTableRow(Table table, PrimaryKeyId primaryKeyId)
Parameters
Type | Name | Description |
---|---|---|
Table | table | The table. |
PrimaryKeyId | primaryKeyId | The primary key id. |
CustomTableRow(Table, IDataReader)
Initializes a new instance of the CustomTableRow class.
Declaration
public CustomTableRow(Table table, IDataReader reader)
Parameters
Type | Name | Description |
---|---|---|
Table | table | The table. |
System.Data.IDataReader | reader | The reader. |
CustomTableRow(TableConfig)
Initializes a new instance of the CustomTableRow class.
Declaration
public CustomTableRow(TableConfig config)
Parameters
Type | Name | Description |
---|---|---|
TableConfig | config | The config. |
CustomTableRow(TableConfig, IDataReader)
Initializes a new instance of the CustomTableRow class.
Declaration
public CustomTableRow(TableConfig config, IDataReader reader)
Parameters
Type | Name | Description |
---|---|---|
TableConfig | config | The config. |
System.Data.IDataReader | reader | The reader. |
CustomTableRow(TableConfig, Int32)
Initializes a new instance of the CustomTableRow class.
Declaration
public CustomTableRow(TableConfig config, int primaryKeyId)
Parameters
Type | Name | Description |
---|---|---|
TableConfig | config | The config. |
System.Int32 | primaryKeyId | The primary key id. |
Properties
Columns
Gets the columns.
Declaration
public string[] Columns { get; protected set; }
Property Value
Type | Description |
---|---|
System.String[] | The columns. |
Config
Declaration
protected TableConfig Config { get; }
Property Value
Type | Description |
---|---|
TableConfig |
Item[Int32]
Gets or sets the System.Object at the specified index.
Declaration
public object this[int index] { get; set; }
Parameters
Type | Name | Description |
---|---|---|
System.Int32 | index |
Property Value
Type | Description |
---|---|
System.Object |
Item[String]
Gets or sets the System.Object with the specified column name.
Declaration
public object this[string columnName] { get; set; }
Parameters
Type | Name | Description |
---|---|---|
System.String | columnName |
Property Value
Type | Description |
---|---|
System.Object |
Names
Declaration
protected Hashtable Names { get; set; }
Property Value
Type | Description |
---|---|
System.Collections.Hashtable |
Primary
Gets the primary.
Declaration
protected Table Primary { get; }
Property Value
Type | Description |
---|---|
Table | The primary. |
PrimaryKeyId
Gets or sets the primary key id.
Declaration
public PrimaryKeyId? PrimaryKeyId { get; set; }
Property Value
Type | Description |
---|---|
System.Nullable<PrimaryKeyId> | The primary key id. |
State
Declaration
protected DataRowState State { get; set; }
Property Value
Type | Description |
---|---|
System.Data.DataRowState |
Values
Declaration
protected object[] Values { get; set; }
Property Value
Type | Description |
---|---|
System.Object[] |
Methods
Contains(String)
Determines whether [contains] [the specified column name].
Declaration
public bool Contains(string columnName)
Parameters
Type | Name | Description |
---|---|---|
System.String | columnName | Name of the column. |
Returns
Type | Description |
---|---|
System.Boolean |
|
CreateColumns()
Creates the columns.
Declaration
protected void CreateColumns()
CreateColumns(String, TableConfig)
Declaration
protected void CreateColumns(string prefix, TableConfig config)
Parameters
Type | Name | Description |
---|---|---|
System.String | prefix | |
TableConfig | config |
CreateParameterList()
Creates the parameter list.
Declaration
protected SqlParameter[] CreateParameterList()
Returns
Type | Description |
---|---|
System.Data.SqlClient.SqlParameter[] |
Delete()
Deletes this instance.
Declaration
public virtual void Delete()
Delete(TableConfig, PrimaryKeyId)
Deletes the specified primary key id.
Declaration
public static void Delete(TableConfig config, PrimaryKeyId primaryKeyId)
Parameters
Type | Name | Description |
---|---|---|
TableConfig | config | The config. |
PrimaryKeyId | primaryKeyId | The primary key id. |
Extract(Table, String)
Extracts the specified table.
Declaration
public CustomTableRow Extract(Table table, string prefix)
Parameters
Type | Name | Description |
---|---|---|
Table | table | The table. |
System.String | prefix | The prefix. |
Returns
Type | Description |
---|---|
CustomTableRow |
Extract(TableConfig, String)
Extracts the specified config.
Declaration
public CustomTableRow Extract(TableConfig config, string prefix)
Parameters
Type | Name | Description |
---|---|---|
TableConfig | config | The config. |
System.String | prefix | The prefix. |
Returns
Type | Description |
---|---|
CustomTableRow |
Extract(String)
Extracts the specified prefix.
Declaration
public CustomTableRow Extract(string prefix)
Parameters
Type | Name | Description |
---|---|---|
System.String | prefix | The prefix. |
Returns
Type | Description |
---|---|
CustomTableRow |
GetExtendedTables()
Gets the extended tables.
Declaration
public Table[] GetExtendedTables()
Returns
Type | Description |
---|---|
Table[] |
GetJoinedTables()
Gets the joined tables.
Declaration
public JoinedTable[] GetJoinedTables()
Returns
Type | Description |
---|---|
JoinedTable[] |
GetReader(Table, FilterElement[])
Gets the reader.
Declaration
public static IDataReader GetReader(Table table, params FilterElement[] filters)
Parameters
Type | Name | Description |
---|---|---|
Table | table | The table. |
FilterElement[] | filters | The filters. |
Returns
Type | Description |
---|---|
System.Data.IDataReader |
GetReader(Table, FilterElementCollection, SortingElementCollection)
Gets the reader.
Declaration
public static IDataReader GetReader(Table table, FilterElementCollection filters, SortingElementCollection sorting)
Parameters
Type | Name | Description |
---|---|---|
Table | table | The table. |
FilterElementCollection | filters | The filters. |
SortingElementCollection | sorting | The sorting. |
Returns
Type | Description |
---|---|
System.Data.IDataReader |
GetReader(Table, Table[])
Gets the reader.
Declaration
public static IDataReader GetReader(Table table, params Table[] reader)
Parameters
Type | Name | Description |
---|---|---|
Table | table | The table. |
Table[] | reader | The reader. |
Returns
Type | Description |
---|---|
System.Data.IDataReader |
GetReader(TableConfig, FilterElement[])
Gets the reader.
Declaration
public static IDataReader GetReader(TableConfig config, params FilterElement[] filters)
Parameters
Type | Name | Description |
---|---|---|
TableConfig | config | The config. |
FilterElement[] | filters | The filters. |
Returns
Type | Description |
---|---|
System.Data.IDataReader |
GetReader(TableConfig, FilterElementCollection, SortingElementCollection)
Gets the reader.
Declaration
public static IDataReader GetReader(TableConfig config, FilterElementCollection filters, SortingElementCollection sorting)
Parameters
Type | Name | Description |
---|---|---|
TableConfig | config | The config. |
FilterElementCollection | filters | The filters. |
SortingElementCollection | sorting | The sorting. |
Returns
Type | Description |
---|---|
System.Data.IDataReader |
GetTable()
Gets the table.
Declaration
public Table GetTable()
Returns
Type | Description |
---|---|
Table |
GetTable(Table, FilterElement[])
Gets the table.
Declaration
public static DataTable GetTable(Table table, params FilterElement[] filters)
Parameters
Type | Name | Description |
---|---|---|
Table | table | The table. |
FilterElement[] | filters | The filters. |
Returns
Type | Description |
---|---|
System.Data.DataTable |
GetTable(TableConfig)
Gets the table.
Declaration
public static DataTable GetTable(TableConfig config)
Parameters
Type | Name | Description |
---|---|---|
TableConfig | config | The config. |
Returns
Type | Description |
---|---|
System.Data.DataTable |
GetTable(TableConfig, FilterElement[])
Gets the table.
Declaration
public static DataTable GetTable(TableConfig config, params FilterElement[] filters)
Parameters
Type | Name | Description |
---|---|---|
TableConfig | config | The config. |
FilterElement[] | filters | The filters. |
Returns
Type | Description |
---|---|
System.Data.DataTable |
GetTotalCount(Table, FilterElement[])
Gets the total count.
Declaration
public static int GetTotalCount(Table table, params FilterElement[] filters)
Parameters
Type | Name | Description |
---|---|---|
Table | table | The table. |
FilterElement[] | filters | The filters. |
Returns
Type | Description |
---|---|
System.Int32 |
GetTotalCount(TableConfig, FilterElement[])
Gets the total count.
Declaration
public static int GetTotalCount(TableConfig config, params FilterElement[] filters)
Parameters
Type | Name | Description |
---|---|---|
TableConfig | config | The config. |
FilterElement[] | filters | The filters. |
Returns
Type | Description |
---|---|
System.Int32 |
IndexOf(String)
Indexes the of.
Declaration
public int IndexOf(string ColumnName)
Parameters
Type | Name | Description |
---|---|---|
System.String | ColumnName | Name of the column. |
Returns
Type | Description |
---|---|
System.Int32 |
List(Table)
Lists the specified table.
Declaration
[Obsolete("This method is no longer used. Use overload with proper paging instead. Will remain at least until November 2019.")]
public static CustomTableRow[] List(Table table)
Parameters
Type | Name | Description |
---|---|---|
Table | table | The table. |
Returns
Type | Description |
---|---|
CustomTableRow[] |
List(Table, FilterElement[])
Lists the specified table.
Declaration
public static CustomTableRow[] List(Table table, params FilterElement[] filters)
Parameters
Type | Name | Description |
---|---|---|
Table | table | The table. |
FilterElement[] | filters | The filters. |
Returns
Type | Description |
---|---|
CustomTableRow[] |
List(Table, FilterElementCollection, SortingElementCollection)
Lists the specified table.
Declaration
public static CustomTableRow[] List(Table table, FilterElementCollection filters, SortingElementCollection sorting)
Parameters
Type | Name | Description |
---|---|---|
Table | table | The table. |
FilterElementCollection | filters | The filters. |
SortingElementCollection | sorting | The sorting. |
Returns
Type | Description |
---|---|
CustomTableRow[] |
List(Table, FilterElementCollection, SortingElementCollection, Int32, Int32)
Lists the specified table.
Declaration
public static CustomTableRow[] List(Table table, FilterElementCollection filters, SortingElementCollection sorting, int start, int count)
Parameters
Type | Name | Description |
---|---|---|
Table | table | The table. |
FilterElementCollection | filters | The filters. |
SortingElementCollection | sorting | The sorting. |
System.Int32 | start | The start. |
System.Int32 | count | The count. |
Returns
Type | Description |
---|---|
CustomTableRow[] |
List(Table, SortingElement[])
Lists the specified table.
Declaration
[Obsolete("This method is no longer used. Use overload with proper paging instead. Will remain at least until November 2019.")]
public static CustomTableRow[] List(Table table, params SortingElement[] sorting)
Parameters
Type | Name | Description |
---|---|---|
Table | table | The table. |
SortingElement[] | sorting | The sorting. |
Returns
Type | Description |
---|---|
CustomTableRow[] |
List(Table, SortingElementCollection, Int32, Int32)
Lists the specified table.
Declaration
public static CustomTableRow[] List(Table table, SortingElementCollection sorting, int start, int count)
Parameters
Type | Name | Description |
---|---|---|
Table | table | The table. |
SortingElementCollection | sorting | The sorting. |
System.Int32 | start | The start. |
System.Int32 | count | The count. |
Returns
Type | Description |
---|---|
CustomTableRow[] |
List(TableConfig)
Lists the specified config.
Declaration
[Obsolete("This method is no longer used. Use overload with proper paging instead. Will remain at least until November 2019.")]
public static CustomTableRow[] List(TableConfig config)
Parameters
Type | Name | Description |
---|---|---|
TableConfig | config | The config. |
Returns
Type | Description |
---|---|
CustomTableRow[] |
List(TableConfig, FilterElement[])
Lists the specified config.
Declaration
public static CustomTableRow[] List(TableConfig config, params FilterElement[] filters)
Parameters
Type | Name | Description |
---|---|---|
TableConfig | config | The config. |
FilterElement[] | filters | The filters. |
Returns
Type | Description |
---|---|
CustomTableRow[] |
List(TableConfig, FilterElementCollection, SortingElementCollection)
Lists the specified config.
Declaration
public static CustomTableRow[] List(TableConfig config, FilterElementCollection filters, SortingElementCollection sorting)
Parameters
Type | Name | Description |
---|---|---|
TableConfig | config | The config. |
FilterElementCollection | filters | The filters. |
SortingElementCollection | sorting | The sorting. |
Returns
Type | Description |
---|---|
CustomTableRow[] |
List(TableConfig, FilterElementCollection, SortingElementCollection, Int32, Int32)
Lists the specified config.
Declaration
public static CustomTableRow[] List(TableConfig config, FilterElementCollection filters, SortingElementCollection sorting, int start, int count)
Parameters
Type | Name | Description |
---|---|---|
TableConfig | config | The config. |
FilterElementCollection | filters | The filters. |
SortingElementCollection | sorting | The sorting. |
System.Int32 | start | The start. |
System.Int32 | count | The count. |
Returns
Type | Description |
---|---|
CustomTableRow[] |
List(TableConfig, SortingElement[])
Lists the specified config.
Declaration
[Obsolete("This method is no longer used. Use overload with proper paging instead. Will remain at least until November 2019.")]
public static CustomTableRow[] List(TableConfig config, params SortingElement[] sorting)
Parameters
Type | Name | Description |
---|---|---|
TableConfig | config | The config. |
SortingElement[] | sorting | The sorting. |
Returns
Type | Description |
---|---|
CustomTableRow[] |
List(TableConfig, SortingElementCollection, Int32, Int32)
Lists the specified config.
Declaration
public static CustomTableRow[] List(TableConfig config, SortingElementCollection sorting, int start, int count)
Parameters
Type | Name | Description |
---|---|---|
TableConfig | config | The config. |
SortingElementCollection | sorting | The sorting. |
System.Int32 | start | The start. |
System.Int32 | count | The count. |
Returns
Type | Description |
---|---|
CustomTableRow[] |
Load(Dictionary<String, Object>)
Declaration
public virtual void Load(Dictionary<string, object> rowSource)
Parameters
Type | Name | Description |
---|---|---|
System.Collections.Generic.Dictionary<System.String, System.Object> | rowSource |
Load(IDataReader)
Loads the specified reader.
Declaration
public virtual void Load(IDataReader reader)
Parameters
Type | Name | Description |
---|---|---|
System.Data.IDataReader | reader | The reader. |
Update()
Updates this instance.
Declaration
public virtual void Update()