Skip to content

Commit 5297908

Browse files
authored
[java] deprecate all html5 offline storage implementations See #10397 (#13373)
these are currently implemented by executing JavaScript
1 parent aac6d64 commit 5297908

File tree

9 files changed

+23
-2
lines changed

9 files changed

+23
-2
lines changed

java/src/org/openqa/selenium/chromium/ChromiumDriver.java

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -292,11 +292,13 @@ public void register(Predicate<URI> whenThisMatches, Supplier<Credentials> useTh
292292
}
293293

294294
@Override
295+
@Deprecated
295296
public LocalStorage getLocalStorage() {
296297
return webStorage.getLocalStorage();
297298
}
298299

299300
@Override
301+
@Deprecated
300302
public SessionStorage getSessionStorage() {
301303
return webStorage.getSessionStorage();
302304
}

java/src/org/openqa/selenium/firefox/FirefoxDriver.java

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -254,11 +254,13 @@ public void setFileDetector(FileDetector detector) {
254254
}
255255

256256
@Override
257+
@Deprecated
257258
public LocalStorage getLocalStorage() {
258259
return webStorage.getLocalStorage();
259260
}
260261

261262
@Override
263+
@Deprecated
262264
public SessionStorage getSessionStorage() {
263265
return webStorage.getSessionStorage();
264266
}

java/src/org/openqa/selenium/html5/AppCacheStatus.java

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@
1818
package org.openqa.selenium.html5;
1919

2020
/** Represents the application cache status. */
21+
@Deprecated
2122
public enum AppCacheStatus {
2223
UNCACHED(0),
2324
IDLE(1),

java/src/org/openqa/selenium/html5/LocalStorage.java

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,4 +21,5 @@
2121
* Represents the local storage for the site currently opened in the browser. Each site has its own
2222
* separate storage area.
2323
*/
24+
@Deprecated
2425
public interface LocalStorage extends Storage {}

java/src/org/openqa/selenium/html5/SessionStorage.java

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,4 +23,5 @@
2323
* unique set of session storage, one for each origin. Sites can add data to the session storage and
2424
* it will be accessible to any page from the same site opened in that window.
2525
*/
26+
@Deprecated
2627
public interface SessionStorage extends Storage {}

java/src/org/openqa/selenium/html5/Storage.java

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,7 @@
2020
import java.util.Set;
2121

2222
/** Represents common operations available for all web storage types (session or local). */
23+
@Deprecated
2324
public interface Storage {
2425

2526
String getItem(String key);

java/src/org/openqa/selenium/html5/WebStorage.java

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@
1717

1818
package org.openqa.selenium.html5;
1919

20+
@Deprecated
2021
public interface WebStorage {
2122

2223
LocalStorage getLocalStorage();

java/src/org/openqa/selenium/remote/html5/RemoteLocalStorage.java

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,13 @@
2525
import org.openqa.selenium.remote.DriverCommand;
2626
import org.openqa.selenium.remote.ExecuteMethod;
2727

28-
/** Executes the commands to access HTML5 localStorage on the remote webdriver server. */
28+
/**
29+
* Executes the commands to access HTML5 localStorage on the remote webdriver server.
30+
*
31+
* @deprecated LocalStorage can be managed by executing JavaScript. @see #executeScript(String,
32+
* Object...)
33+
*/
34+
@Deprecated
2935
public class RemoteLocalStorage implements LocalStorage {
3036
private final ExecuteMethod executeMethod;
3137

java/src/org/openqa/selenium/remote/html5/RemoteSessionStorage.java

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,13 @@
2525
import org.openqa.selenium.remote.DriverCommand;
2626
import org.openqa.selenium.remote.ExecuteMethod;
2727

28-
/** Executes the commands to access HTML5 sessionStorage on the remote webdriver server. */
28+
/**
29+
* Executes the commands to access HTML5 sessionStorage on the remote webdriver server.
30+
*
31+
* @deprecated LocalStorage can be managed by executing JavaScript. @see #executeScript(String,
32+
* Object...)
33+
*/
34+
@Deprecated
2935
public class RemoteSessionStorage implements SessionStorage {
3036
private final ExecuteMethod executeMethod;
3137

0 commit comments

Comments
 (0)