public abstract class ServiceWorkerWebSettings extends Object
WebSettings
but only settings relevant to
Service Workers are supported.Constructor and Description |
---|
ServiceWorkerWebSettings() |
Modifier and Type | Method and Description |
---|---|
abstract boolean |
getAllowContentAccess()
Gets whether Service Workers support content URL access.
|
abstract boolean |
getAllowFileAccess()
Gets whether Service Workers support file access.
|
abstract boolean |
getBlockNetworkLoads()
Gets whether Service Workers are prohibited from loading any resources from the network.
|
abstract int |
getCacheMode()
Gets the current setting for overriding the cache mode.
|
abstract void |
setAllowContentAccess(boolean allow)
Enables or disables content URL access from Service Workers, see
WebSettings.setAllowContentAccess(boolean) . |
abstract void |
setAllowFileAccess(boolean allow)
Enables or disables file access within Service Workers, see
WebSettings.setAllowFileAccess(boolean) . |
abstract void |
setBlockNetworkLoads(boolean flag)
Sets whether Service Workers should not load resources from the network,
see
WebSettings.setBlockNetworkLoads(boolean) . |
abstract void |
setCacheMode(int mode)
Overrides the way the cache is used, see
WebSettings.setCacheMode(int) . |
public abstract void setCacheMode(int mode)
WebSettings.setCacheMode(int)
.mode
- the mode to use. One of WebSettings.LOAD_DEFAULT
,
WebSettings.LOAD_CACHE_ELSE_NETWORK
, WebSettings.LOAD_NO_CACHE
or WebSettings.LOAD_CACHE_ONLY
. The default value is
WebSettings.LOAD_DEFAULT
.public abstract int getCacheMode()
setCacheMode(int)
public abstract void setAllowContentAccess(boolean allow)
WebSettings.setAllowContentAccess(boolean)
.public abstract boolean getAllowContentAccess()
setAllowContentAccess(boolean)
public abstract void setAllowFileAccess(boolean allow)
WebSettings.setAllowFileAccess(boolean)
.public abstract boolean getAllowFileAccess()
setAllowFileAccess(boolean)
public abstract void setBlockNetworkLoads(boolean flag)
WebSettings.setBlockNetworkLoads(boolean)
.flag
- true means block network loads by the Service Workerspublic abstract boolean getBlockNetworkLoads()
setBlockNetworkLoads(boolean)