Skip to content

Commit be56861

Browse files
committed
[java] JSpecify annotations for org.openqa.selenium.interactions
1 parent 17a5dba commit be56861

File tree

4 files changed

+14
-3
lines changed

4 files changed

+14
-3
lines changed

java/src/org/openqa/selenium/interactions/CompositeAction.java

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,9 +19,11 @@
1919

2020
import java.util.ArrayList;
2121
import java.util.List;
22+
import org.jspecify.annotations.NullMarked;
2223
import org.openqa.selenium.internal.Require;
2324

2425
/** An action for aggregating actions and triggering all of them at the same time. */
26+
@NullMarked
2527
public class CompositeAction implements Action {
2628

2729
private final List<Action> actionsList = new ArrayList<>();

java/src/org/openqa/selenium/interactions/Interaction.java

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,10 +17,13 @@
1717

1818
package org.openqa.selenium.interactions;
1919

20+
import org.jspecify.annotations.NullMarked;
21+
2022
/**
2123
* Used as the basis of {@link Sequence}s for the W3C WebDriver spec <a
2224
* href="https://www.w3.org/TR/webdriver/#actions">Action commands</a>.
2325
*/
26+
@NullMarked
2427
public abstract class Interaction {
2528

2629
private final InputSource source;

java/src/org/openqa/selenium/interactions/Locatable.java

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,9 @@
1717

1818
package org.openqa.selenium.interactions;
1919

20+
import org.jspecify.annotations.NullMarked;
21+
22+
@NullMarked
2023
public interface Locatable {
2124
Coordinates getCoordinates();
2225
}

java/src/org/openqa/selenium/interactions/MoveTargetOutOfBoundsException.java

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17,22 +17,25 @@
1717

1818
package org.openqa.selenium.interactions;
1919

20+
import org.jspecify.annotations.NullMarked;
21+
import org.jspecify.annotations.Nullable;
2022
import org.openqa.selenium.WebDriverException;
2123

2224
/**
2325
* Indicates that the target provided to the actions move() method is invalid - outside of the size
2426
* of the window.
2527
*/
28+
@NullMarked
2629
public class MoveTargetOutOfBoundsException extends WebDriverException {
27-
public MoveTargetOutOfBoundsException(String message) {
30+
public MoveTargetOutOfBoundsException(@Nullable String message) {
2831
super(message);
2932
}
3033

31-
public MoveTargetOutOfBoundsException(Throwable cause) {
34+
public MoveTargetOutOfBoundsException(@Nullable Throwable cause) {
3235
super(cause);
3336
}
3437

35-
public MoveTargetOutOfBoundsException(String message, Throwable cause) {
38+
public MoveTargetOutOfBoundsException(@Nullable String message, @Nullable Throwable cause) {
3639
super(message, cause);
3740
}
3841
}

0 commit comments

Comments
 (0)