- Selenium WebDriver 3 Practical Guide
- Unmesh Gundecha Satya Avasarala
- 107字
- 2021-08-13 16:08:06
The findElements method
For finding multiple elements matching the same locator criteria on a web page, the findElements() method can be used. It returns a list of WebElements found for a given locating mechanism. The method declaration of the findElements() method is as follows:
java.util.List findElements(By by)
The input parameter is the same as the findElement() method, which is an instance of the By class. The difference lies in the return type. Here, if no element is found, an empty list is returned and if there are multiple WebElements present that satisfy the locating mechanism, all of them are returned to the caller in a list.
推薦閱讀
- Hands-On Chatbots and Conversational UI Development
- SD-WAN架構(gòu)與技術(shù)(第2版)
- 智慧城市中的移動互聯(lián)網(wǎng)技術(shù)
- 正在爆發(fā)的互聯(lián)網(wǎng)革命
- 面向云平臺的物聯(lián)網(wǎng)多源異構(gòu)信息融合方法
- Socket.IO Real-time Web Application Development
- Microservice Patterns and Best Practices
- 網(wǎng)絡環(huán)境中基于用戶視角的信息質(zhì)量評價研究
- 基于性能的保障理論與方法
- Implementing NetScaler VPX?
- Dart Cookbook
- 互聯(lián)網(wǎng)安全的40個智慧洞見(2016)
- 計算機網(wǎng)絡技術(shù)
- 商業(yè)的本質(zhì)和互聯(lián)網(wǎng)
- 區(qū)塊鏈技術(shù)與應用:打造分布式商業(yè)新生態(tài)