Answers for "where do you use overriding in framework"

0

where do you use overriding in framework

Set<Integer> set = new HashSet<>();
List<Integer> list = new ArrayList<>();
set.add(4);  ==> HashSet overrides add() method from Collection Interface
list.add(8); ==> ArrayList overrides add() method from Collection Interface

WebDriver driver1 = new ChromeDriver();
driver1.get("xxxxxx"); ChromeDriver overrides get/findElement/etc.
                                      methods from WebDriver Interface.

WebDriver driver2 = new FirefoxDriver();
driver2.get("xxxxxx"); FirefoxDriver overrides 
get/findElement/etc. methods from WebDriver Interface.
Posted by: Guest on January-14-2021

Code answers related to "where do you use overriding in framework"

Code answers related to "Java"

Java Answers by Framework

Browse Popular Code Answers by Language