What is java actually?

I work in selenium. This problem is more specific to Java than selenium

The example I provided is selenium webdriver explicitwait,

new ExpectedCondition<WebElement>(){
        @Override
        public WebElement apply(WebDriver d) 
        {
            return d.findElement(By.id("myDynamicElement"));
        }});

What the hell is he doing? How to write logic without assigning the reference of the object to the class expectedcondition???

thank you.

Solution

What happens here is to create an anonymous class that inherits from expectedcondition In the body of this course, he will cover the method apply (...)

The content of this article comes from the network collection of netizens. It is used as a learning reference. The copyright belongs to the original author.
THE END
分享
二维码
< <上一篇
下一篇>>