Class Table
Defines a
Implements
Inherited Members
Namespace: Legerity.Web.Elements.Core
Assembly: Legerity.Web.dll
Syntax
public class Table : WebElementWrapper, IElementWrapper<RemoteWebElement>
Constructors
| Improve this Doc View SourceTable(IWebElement)
Initializes a new instance of the Table class.
Declaration
public Table(IWebElement element)
Parameters
Type | Name | Description |
---|---|---|
IWebElement | element | The |
Table(RemoteWebElement)
Initializes a new instance of the Table class.
Declaration
public Table(RemoteWebElement element)
Parameters
Type | Name | Description |
---|---|---|
RemoteWebElement | element | The |
Properties
| Improve this Doc View SourceDataRows
Gets the collection of rows associated with the table only containing the data values (not headers).
Declaration
public virtual IEnumerable<TableRow> DataRows { get; }
Property Value
Type | Description |
---|---|
IEnumerable<TableRow> |
Headers
Gets the header names for the table.
Declaration
public virtual IEnumerable<string> Headers { get; }
Property Value
Type | Description |
---|---|
IEnumerable<System.String> |
IsFirstRowHeaders
Gets or sets a value indicating whether the first row in the table is a header row.
Declaration
public virtual bool IsFirstRowHeaders { get; set; }
Property Value
Type | Description |
---|---|
System.Boolean |
Rows
Gets the collection of rows associated with the table. If a header row exists, that will be included.
Declaration
public virtual IEnumerable<TableRow> Rows { get; }
Property Value
Type | Description |
---|---|
IEnumerable<TableRow> |
Methods
| Improve this Doc View SourceGetColumnDataByHeader(String)
Retrieves the column values for a specific column by header name.
Declaration
public virtual IEnumerable<string> GetColumnDataByHeader(string header)
Parameters
Type | Name | Description |
---|---|---|
System.String | header | The column header name. |
Returns
Type | Description |
---|---|
IEnumerable<System.String> | A collection of values for each row in the column. |
GetColumnDataByIndex(Int32)
Retrieves the column values for a specific column by index.
Declaration
public virtual IEnumerable<string> GetColumnDataByIndex(int idx)
Parameters
Type | Name | Description |
---|---|---|
System.Int32 | idx | The specified column index of data to retrieve. |
Returns
Type | Description |
---|---|
IEnumerable<System.String> | A collection of values for each row in the column. |
GetRowDataByIndex(Int32)
Retrieves the column names and associated column values for a specific row in the table by index.
Declaration
public virtual IReadOnlyDictionary<string, string> GetRowDataByIndex(int idx)
Parameters
Type | Name | Description |
---|---|---|
System.Int32 | idx | The specified row data index to retrieve data for. |
Returns
Type | Description |
---|---|
IReadOnlyDictionary<System.String, System.String> | A dictionary of key-value pairs containing the column header and the column value for the row. |
Operators
| Improve this Doc View SourceImplicit(RemoteWebElement to Table)
Allows conversion of a
Declaration
public static implicit operator Table(RemoteWebElement element)
Parameters
Type | Name | Description |
---|---|---|
RemoteWebElement | element | The |
Returns
Type | Description |
---|---|
Table | The Table. |