congrats Icon
New! Tabnine Pro 14-day free trial
Start a free trial
Tabnine Logo
FirefoxDriver.findElements
Code IndexAdd Tabnine to your IDE (free)

How to use
findElements
method
in
org.openqa.selenium.firefox.FirefoxDriver

Best Java code snippets using org.openqa.selenium.firefox.FirefoxDriver.findElements (Showing top 10 results out of 315)

origin: org.openqa.selenium.webdriver/webdriver-firefox

public List<WebElement> findElementsByXPath(String using) {
  return findElements("selectElementsUsingXPath", using);
}
origin: org.openqa.selenium.webdriver/webdriver-firefox

public List<WebElement> findElementsById(String using) {
  return findElements("selectElementsUsingId", using);
}
origin: org.openqa.selenium.webdriver/webdriver-firefox

public List<WebElement> findElementsByLinkText(String using) {
 return findElements("selectElementsUsingLink", using);
}
origin: org.openqa.selenium.webdriver/webdriver-firefox

public List<WebElement> findElementsByName(String using) {
  return findElements("selectElementsUsingName", using);
}
origin: org.openqa.selenium.webdriver/webdriver-firefox

public List<WebElement> findElementsByPartialLinkText(String using) {
 return findElements("selectElementsUsingPartialLinkText", using);
}
origin: org.openqa.selenium.webdriver/webdriver-firefox

public List<WebElement> findElementsByTagName(String using) {
 return findElements("selectElementsUsingTagName", using);
}

origin: stackoverflow.com

List<WebElement> listAllRadioButtons= driver.findElements(By.cssSelector("input[type='radio']"));
List<WebElement> listAllRadioButtonsChecked= driver.findElements(By.cssSelector("input[type='radio']:checked"));
List<WebElement> listAllRadioButtonsFromTable = driver.findElements(By.cssSelector("table>tbody>tr>td>input[type='radio']"));
List<WebElement> listAllRadioButtonsFromTableChecked = driver.findElements(By.cssSelector("table>tbody>tr>td>input[type='radio']:checked"));
List<WebElement> listCol = driver.findElements(By.cssSelector("table>tbody>tr>td:nth-child("+colNumber+")"));
List<WebElement> listColRadioButton = driver.findElements(By.cssSelector("table>tbody>tr>td:nth-child("+colNumber+")>input[type='radio']"));
List<WebElement> listColRadioButtonChecked = driver.findElements(By.cssSelector("table>tbody>tr>td:nth-child("+colNumber+")>input[type='radio']:checked"));
List<WebElement> listRowRadioButton = driver.findElements(By.cssSelector("table>tbody>tr:nth-child("+rowNumber+")>td>input[type='radio']"));
List<WebElement> listRowRadioButtonChecked = driver.findElements(By.cssSelector("table>tbody>tr:nth-child("+rowNumber+")>td>input[type='radio']:checked"));        
origin: org.openqa.selenium.webdriver/webdriver-firefox

public List<WebElement> findElementsByClassName(String using) {
 if (using == null)
  throw new IllegalArgumentException("Cannot find elements when the class name expression is null.");
 if (using.matches(".*\\s+.*")) {
  throw new IllegalLocatorException(
    "Compound class names are not supported. Consider searching for one class name and filtering the results.");
 }
   
 return findElements("selectElementsUsingClassName", using);
}
origin: stackoverflow.com

 FirefoxDriver driver = new FirefoxDriver();
driver.get("https://www.google.com");
List<WebElement> links = driver.findElements(By.cssSelector("#gbw a.gb_P"));
for (WebElement link : links)
{
  System.out.println(link.getText().trim());
}
origin: stackoverflow.com

 FirefoxDriver driver = new FirefoxDriver();
driver.get("https://www.youtube.com/watch?v=JcbBNpYkuW4");

WebElement element = driver.findElementByCssSelector("#watch-discussion");
System.out.println(element.getText()); // this prints: loading..

// scrolll down so that comments start to load
driver.executeScript("window.scrollBy(0,500)", "");

Thread.sleep(20000);

List<WebElement> iframes = driver.findElements(By.xpath("//iframe"));

for(WebElement e : iframes) {       
  if(e.getAttribute("id") != null && e.getAttribute("id").startsWith("I0_")) {
  // switch to iframe which contains comments
  driver.switchTo().frame(e);
  break;
  }
}

// fetch all comments
List<WebElement> comments = driver.findElements(By.xpath("//div[@class='Ct']"));
for(WebElement e : comments) {      
  System.out.println(e.getText());
}
org.openqa.selenium.firefoxFirefoxDriverfindElements

Popular methods of FirefoxDriver

  • <init>
  • manage
  • get
  • getTitle
  • quit
  • connectTo
  • findElement
  • findElementByCssSelector
  • ExecuteScript
  • FindElement
  • FindElementByXPath
  • Manage
  • FindElementByXPath,
  • Manage,
  • Quit,
  • close,
  • convertToJsObject,
  • convertToJsObjects,
  • dropCapabilities,
  • execute,
  • executeScript

Popular in Java

  • Updating database using SQL prepared statement
  • orElseThrow (Optional)
    Return the contained value, if present, otherwise throw an exception to be created by the provided s
  • startActivity (Activity)
  • getSystemService (Context)
  • SocketTimeoutException (java.net)
    This exception is thrown when a timeout expired on a socket read or accept operation.
  • DecimalFormat (java.text)
    A concrete subclass of NumberFormat that formats decimal numbers. It has a variety of features desig
  • Hashtable (java.util)
    A plug-in replacement for JDK1.5 java.util.Hashtable. This version is based on org.cliffc.high_scale
  • Scanner (java.util)
    A parser that parses a text string of primitive types and strings with the help of regular expressio
  • JarFile (java.util.jar)
    JarFile is used to read jar entries and their associated data from jar files.
  • FileUtils (org.apache.commons.io)
    General file manipulation utilities. Facilities are provided in the following areas: * writing to a
  • Top 17 PhpStorm Plugins
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimAtomGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyStudentsTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now