Skip to content

Commit 76cef2b

Browse files
committed
[java] Converting CustomLocator from abstract class to interface
1 parent 996ea54 commit 76cef2b

File tree

3 files changed

+5
-5
lines changed

3 files changed

+5
-5
lines changed

java/client/src/org/openqa/selenium/remote/locators/CustomLocator.java

+3-3
Original file line numberDiff line numberDiff line change
@@ -25,13 +25,13 @@
2525
* (essentially {@code {"using": "locator-name", "value": "arguments"}})
2626
* and calls it in the context of the server.
2727
*/
28-
public abstract class CustomLocator {
28+
public interface CustomLocator {
2929

3030
/**
3131
* @return The locator name, which is the value of the {@code using}
3232
* property of the JSON payload.
3333
*/
34-
public abstract String getLocatorName();
34+
String getLocatorName();
3535

36-
public abstract By createBy(Object usingParameter);
36+
By createBy(Object usingParameter);
3737
}

java/server/src/org/openqa/selenium/grid/node/locators/ById.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@
3333
*/
3434

3535
@AutoService(CustomLocator.class)
36-
public class ById extends CustomLocator {
36+
public class ById implements CustomLocator {
3737
@Override
3838
public String getLocatorName() {
3939
return "id";

java/server/src/org/openqa/selenium/grid/node/locators/ByName.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@
2929
*/
3030

3131
@AutoService(CustomLocator.class)
32-
public class ByName extends CustomLocator {
32+
public class ByName implements CustomLocator {
3333
@Override
3434
public String getLocatorName() {
3535
return "name";

0 commit comments

Comments
 (0)