C# Class Selenium.WebElements

Inheritance: Selenium.List, ComInterfaces._WebElements
Show file Open project: florentbr/SeleniumBasic Class Usage Examples

Public Methods

Method Description
Add ( WebElement element ) : void

Adds a web element

Attribute ( string attributeName, bool withAttributeOnly = true ) : Selenium.List

Returns a list with the attribute for each element

ExecuteAsyncScript ( string script, int timeout = -1 ) : Selenium.List

Execute an asynchronous piece of JavaScript against each web element and returns all the results;

ExecuteScript ( string script, bool ignoreNulls = true ) : Selenium.List

Execute a piece of JavaScript against each web element and returns all the results;

First ( ) : WebElement

Returns the first item

Last ( ) : WebElement

Returns the last item

Text ( int offsetStart, int offsetEnd, bool trim = true ) : Selenium.List

Returns a list containing the text for each element

Values ( object defaultValue = null, int offsetStart, int offsetEnd ) : Selenium.List

Returns a list containing the text parsed to a number for each element

this ( int index ) : WebElement

Get the WebElement at the provided index

Private Methods

Method Description
Add ( RemoteSession session, Selenium.List rawElements ) : void
ComInterfaces ( ) : IEnumerator
WebElements ( ) : Selenium.Core
WebElements ( Selenium.List webElements ) : Selenium.Core
WebElements ( RemoteSession session, Selenium.List rawElements ) : Selenium.Core
this ( int index ) : WebElementComInterfaces._WebElements.Selenium.Core

Get the WebElement at the provided index

Method Details

Add() public method

Adds a web element
public Add ( WebElement element ) : void
element WebElement
return void

Attribute() public method

Returns a list with the attribute for each element
public Attribute ( string attributeName, bool withAttributeOnly = true ) : Selenium.List
attributeName string Attribute name
withAttributeOnly bool True to skip elements without the attribute
return Selenium.List

ExecuteAsyncScript() public method

Execute an asynchronous piece of JavaScript against each web element and returns all the results;
public ExecuteAsyncScript ( string script, int timeout = -1 ) : Selenium.List
script string Javascript script
timeout int
return Selenium.List

ExecuteScript() public method

Execute a piece of JavaScript against each web element and returns all the results;
public ExecuteScript ( string script, bool ignoreNulls = true ) : Selenium.List
script string Javascript script
ignoreNulls bool Null elements are skiped
return Selenium.List

First() public method

Returns the first item
public First ( ) : WebElement
return WebElement

Last() public method

Returns the last item
public Last ( ) : WebElement
return WebElement

Text() public method

Returns a list containing the text for each element
public Text ( int offsetStart, int offsetEnd, bool trim = true ) : Selenium.List
offsetStart int
offsetEnd int
trim bool
return Selenium.List

Values() public method

Returns a list containing the text parsed to a number for each element
public Values ( object defaultValue = null, int offsetStart, int offsetEnd ) : Selenium.List
defaultValue object Default value in case the text can't be parsed.
offsetStart int
offsetEnd int
return Selenium.List

this() public method

Get the WebElement at the provided index
public this ( int index ) : WebElement
index int Base zero index
return WebElement