summaryrefslogtreecommitdiffstats
path: root/core/java/android/webkit/WebSettings.java
diff options
context:
space:
mode:
authorSteve Block <steveblock@google.com>2012-04-24 23:12:47 +0100
committerSteve Block <steveblock@google.com>2012-04-26 13:59:52 +0100
commit4e584df4cee8334bc371c04a67bcd0a32e2f9480 (patch)
treeb3fcc91f5dbdd62acd44cf6dc22803be8e42a533 /core/java/android/webkit/WebSettings.java
parente9e260fbc0892885790eeccb4d803f7d81f261aa (diff)
downloadframeworks_base-4e584df4cee8334bc371c04a67bcd0a32e2f9480.zip
frameworks_base-4e584df4cee8334bc371c04a67bcd0a32e2f9480.tar.gz
frameworks_base-4e584df4cee8334bc371c04a67bcd0a32e2f9480.tar.bz2
Fix JavaDoc style for several WebView classes
This fixes the JavaDoc style for the following classes ... - CacheManager.java - CookieManager.java - GeolocationPermissions.java - WebResourceResponse.java - WebSettings.java - WebStorage.java - WebView.java In particular, this applies the guidelines at https://wiki.corp.google.com/twiki/bin/view/Main/APIDocumentation This should help to ensure that future JavaDoc comments use correct style, rather than using incorrect style for consistency. Note that this change does not attempt to improve the content of the JavaDoc comments. This will be done in later changes. Bug: 5461416 Change-Id: I79e9b15a8cf3597195d58e154a7eb1bcc462944c
Diffstat (limited to 'core/java/android/webkit/WebSettings.java')
-rw-r--r--core/java/android/webkit/WebSettings.java574
1 files changed, 342 insertions, 232 deletions
diff --git a/core/java/android/webkit/WebSettings.java b/core/java/android/webkit/WebSettings.java
index 1bbf00f..901372b 100644
--- a/core/java/android/webkit/WebSettings.java
+++ b/core/java/android/webkit/WebSettings.java
@@ -33,10 +33,12 @@ import android.os.Build;
public abstract class WebSettings {
/**
* Enum for controlling the layout of html.
- * NORMAL means no rendering changes.
- * SINGLE_COLUMN moves all content into one column that is the width of the
- * view.
- * NARROW_COLUMNS makes all columns no wider than the screen if possible.
+ * <ul>
+ * <li>NORMAL means no rendering changes.</li>
+ * <li>SINGLE_COLUMN moves all content into one column that is the width of the
+ * view.</li>
+ * <li>NARROW_COLUMNS makes all columns no wider than the screen if possible.</li>
+ * </ul>
*/
// XXX: These must match LayoutAlgorithm in Settings.h in WebCore.
public enum LayoutAlgorithm {
@@ -51,11 +53,14 @@ public abstract class WebSettings {
/**
* Enum for specifying the text size.
- * SMALLEST is 50%
- * SMALLER is 75%
- * NORMAL is 100%
- * LARGER is 150%
- * LARGEST is 200%
+ * <ul>
+ * <li>SMALLEST is 50%</li>
+ * <li>SMALLER is 75%</li>
+ * <li>NORMAL is 100%</li>
+ * <li>LARGER is 150%</li>
+ * <li>LARGEST is 200%</li>
+ * </ul>
+ *
* @deprecated Use {@link WebSettings#setTextZoom(int)} and {@link WebSettings#getTextZoom()} instead.
*/
public enum TextSize {
@@ -72,9 +77,11 @@ public abstract class WebSettings {
/**
* Enum for specifying the WebView's desired density.
- * FAR makes 100% looking like in 240dpi
- * MEDIUM makes 100% looking like in 160dpi
- * CLOSE makes 100% looking like in 120dpi
+ * <ul>
+ * <li>FAR makes 100% looking like in 240dpi</li>
+ * <li>MEDIUM makes 100% looking like in 160dpi</li>
+ * <li>CLOSE makes 100% looking like in 120dpi</li>
+ * </ul>
*/
public enum ZoomDensity {
FAR(150), // 240dpi
@@ -87,24 +94,24 @@ public abstract class WebSettings {
}
/**
- * Default cache usage pattern Use with {@link #setCacheMode}.
+ * Default cache usage pattern. Use with {@link #setCacheMode}.
*/
public static final int LOAD_DEFAULT = -1;
/**
- * Normal cache usage pattern Use with {@link #setCacheMode}.
+ * Normal cache usage pattern. Use with {@link #setCacheMode}.
*/
public static final int LOAD_NORMAL = 0;
/**
- * Use cache if content is there, even if expired (eg, history nav)
+ * Use cache if content is there, even if expired (eg, history nav).
* If it is not in the cache, load from network.
* Use with {@link #setCacheMode}.
*/
public static final int LOAD_CACHE_ELSE_NETWORK = 1;
/**
- * Don't use the cache, load from network
+ * Don't use the cache, load from network.
* Use with {@link #setCacheMode}.
*/
public static final int LOAD_NO_CACHE = 2;
@@ -139,6 +146,7 @@ public abstract class WebSettings {
/**
* Hidden constructor to prevent clients from creating a new settings
* instance or deriving the class.
+ *
* @hide
*/
protected WebSettings() {
@@ -146,6 +154,7 @@ public abstract class WebSettings {
/**
* Enables dumping the pages navigation cache to a text file.
+ *
* @deprecated This method is now obsolete.
*/
@Deprecated
@@ -154,7 +163,8 @@ public abstract class WebSettings {
}
/**
- * Returns true if dumping the navigation cache is enabled.
+ * Gets whether dumping the navigation cache is enabled.
+ *
* @deprecated This method is now obsolete.
*/
@Deprecated
@@ -167,16 +177,19 @@ public abstract class WebSettings {
* controls and gestures. The particular zoom mechanisms that should be used
* can be set with {@link #setBuiltInZoomControls}. This setting does not
* affect zooming performed using the {@link WebView#zoomIn()} and
- * {@link WebView#zoomOut()} methods.
- * @param support Whether the WebView should support zoom.
+ * {@link WebView#zoomOut()} methods. The default is true.
+ *
+ * @param support whether the WebView should support zoom
*/
public void setSupportZoom(boolean support) {
throw new MustOverrideException();
}
/**
- * Returns true if the WebView supports zoom. The default is true.
- * @return True if the WebView supports zoom.
+ * Gets whether the WebView supports zoom.
+ *
+ * @return true if the WebView supports zoom
+ * @see #setSupportZoom
*/
public boolean supportZoom() {
throw new MustOverrideException();
@@ -187,11 +200,12 @@ public abstract class WebSettings {
* built-in zoom mechanisms comprise on-screen zoom controls, which are
* displayed over the WebView's content, and the use of a pinch gesture to
* control zooming. Whether or not these on-screen controls are displayed
- * can be set with {@link #setDisplayZoomControls}.
+ * can be set with {@link #setDisplayZoomControls}. The default is false.
* <p>
* The built-in mechanisms are the only currently supported zoom
* mechanisms, so it is recommended that this setting is always enabled.
- * @param enabled Whether the WebView should use its built-in zoom mechanisms.
+ *
+ * @param enabled whether the WebView should use its built-in zoom mechanisms
*/
// This method was intended to select between the built-in zoom mechanisms
// and the separate zoom controls. The latter were obtained using
@@ -201,9 +215,10 @@ public abstract class WebSettings {
}
/**
- * Returns true if the zoom mechanisms built into WebView are being used.
- * The default is false.
- * @return True if the zoom mechanisms built into WebView are being used.
+ * Gets whether the zoom mechanisms built into WebView are being used.
+ *
+ * @return true if the zoom mechanisms built into WebView are being used
+ * @see #setBuiltInZoomControls
*/
public boolean getBuiltInZoomControls() {
throw new MustOverrideException();
@@ -212,24 +227,28 @@ public abstract class WebSettings {
/**
* Sets whether the WebView should display on-screen zoom controls when
* using the built-in zoom mechanisms. See {@link #setBuiltInZoomControls}.
- * @param enabled Whether the WebView should display on-screen zoom controls.
+ * The default is true.
+ *
+ * @param enabled whether the WebView should display on-screen zoom controls
*/
public void setDisplayZoomControls(boolean enabled) {
throw new MustOverrideException();
}
/**
- * Returns true if the WebView displays on-screen zoom controls when using
- * the built-in zoom mechanisms. The default is true.
- * @return True if the WebView displays on-screen zoom controls when using
+ * Gets whether the WebView displays on-screen zoom controls when using
* the built-in zoom mechanisms.
+ *
+ * @return true if the WebView displays on-screen zoom controls when using
+ * the built-in zoom mechanisms
+ * @see #setDisplayZoomControls
*/
public boolean getDisplayZoomControls() {
throw new MustOverrideException();
}
/**
- * Enable or disable file access within WebView. File access is enabled by
+ * Enables or disables file access within WebView. File access is enabled by
* default. Note that this enables or disables file system access only.
* Assets and resources are still accessible using file:///android_asset and
* file:///android_res.
@@ -239,44 +258,48 @@ public abstract class WebSettings {
}
/**
- * Returns true if this WebView supports file access.
+ * Gets whether this WebView supports file access.
+ *
+ * @see #setAllowFileAccess
*/
public boolean getAllowFileAccess() {
throw new MustOverrideException();
}
/**
- * Enable or disable content url access within WebView. Content url access
- * allows WebView to load content from a content provider installed in the
- * system. The default is enabled.
+ * Enables or disables content URL access within WebView. Content URL
+ * access allows WebView to load content from a content provider installed
+ * in the system. The default is enabled.
*/
public void setAllowContentAccess(boolean allow) {
throw new MustOverrideException();
}
/**
- * Returns true if this WebView supports content url access.
+ * Gets whether this WebView supports content URL access.
+ *
+ * @see #setAllowContentAccess
*/
public boolean getAllowContentAccess() {
throw new MustOverrideException();
}
/**
- * Set whether the WebView loads a page with overview mode.
+ * Sets whether the WebView loads a page with overview mode.
*/
public void setLoadWithOverviewMode(boolean overview) {
throw new MustOverrideException();
}
/**
- * Returns true if this WebView loads page with overview mode
+ * Gets whether this WebView loads pages with overview mode.
*/
public boolean getLoadWithOverviewMode() {
throw new MustOverrideException();
}
/**
- * Set whether the WebView will enable smooth transition while panning or
+ * Sets whether the WebView will enable smooth transition while panning or
* zooming or while the window hosting the WebView does not have focus.
* If it is true, WebView will choose a solution to maximize the performance.
* e.g. the WebView's content may not be updated during the transition.
@@ -285,18 +308,22 @@ public abstract class WebSettings {
public void setEnableSmoothTransition(boolean enable) {
throw new MustOverrideException();
}
+
/**
- * Returns true if the WebView enables smooth transition while panning or
+ * Gets whether the WebView enables smooth transition while panning or
* zooming.
+ *
+ * @see #setEnableSmoothTransition
*/
public boolean enableSmoothTransition() {
throw new MustOverrideException();
}
/**
- * Set whether the WebView uses its background for over scroll background.
+ * Sets whether the WebView uses its background for over scroll background.
* If true, it will use the WebView's background. If false, it will use an
* internal pattern. Default is true.
+ *
* @deprecated This method is now obsolete.
*/
@Deprecated
@@ -305,8 +332,10 @@ public abstract class WebSettings {
}
/**
- * Returns true if this WebView uses WebView's background instead of
+ * Gets whether this WebView uses WebView's background instead of
* internal pattern for over scroll background.
+ *
+ * @see #setUseWebViewBackgroundForOverscrollBackground
* @deprecated This method is now obsolete.
*/
@Deprecated
@@ -315,77 +344,82 @@ public abstract class WebSettings {
}
/**
- * Store whether the WebView is saving form data.
+ * Sets whether the WebView is saving form data.
*/
public void setSaveFormData(boolean save) {
throw new MustOverrideException();
}
/**
- * Return whether the WebView is saving form data and displaying prior
- * entries/autofill++. Always false in private browsing mode.
+ * Gets whether the WebView is saving form data and displaying prior
+ * entries/autofill++. Always false in private browsing mode.
*/
public boolean getSaveFormData() {
throw new MustOverrideException();
}
/**
- * Store whether the WebView is saving password.
+ * Stores whether the WebView is saving password.
*/
public void setSavePassword(boolean save) {
throw new MustOverrideException();
}
/**
- * Return whether the WebView is saving password.
+ * Gets whether the WebView is saving password.
*/
public boolean getSavePassword() {
throw new MustOverrideException();
}
/**
- * Set the text zoom of the page in percent. Default is 100.
- * @param textZoom A percent value for increasing or decreasing the text.
+ * Sets the text zoom of the page in percent. Default is 100.
+ *
+ * @param textZoom the percent value for increasing or decreasing the text
*/
public synchronized void setTextZoom(int textZoom) {
throw new MustOverrideException();
}
/**
- * Get the text zoom of the page in percent.
- * @return A percent value describing the text zoom.
- * @see setTextSizeZoom
+ * Gets the text zoom of the page in percent.
+ *
+ * @return a percent value describing the text zoom
+ * @see #setTextSizeZoom
*/
public synchronized int getTextZoom() {
throw new MustOverrideException();
}
/**
- * Set the text size of the page.
- * @param t A TextSize value for increasing or decreasing the text.
+ * Sets the text size of the page.
+ *
+ * @param t the TextSize value for increasing or decreasing the text
* @see WebSettings.TextSize
- * @deprecated Use {@link #setTextZoom(int)} instead
+ * @deprecated Use {@link #setTextZoom(int)} instead.
*/
public synchronized void setTextSize(TextSize t) {
throw new MustOverrideException();
}
/**
- * Get the text size of the page. If the text size was previously specified
+ * Gets the text size of the page. If the text size was previously specified
* in percent using {@link #setTextZoom(int)}, this will return
* the closest matching {@link TextSize}.
- * @return A TextSize enum value describing the text size.
+ *
+ * @return a TextSize enum value describing the text size
* @see WebSettings.TextSize
- * @deprecated Use {@link #getTextZoom()} instead
+ * @deprecated Use {@link #getTextZoom()} instead.
*/
public synchronized TextSize getTextSize() {
throw new MustOverrideException();
}
/**
- * Set the default zoom density of the page. This should be called from UI
+ * Sets the default zoom density of the page. This should be called from UI
* thread.
- * @param zoom A ZoomDensity value
+ *
+ * @param zoom a ZoomDensity value
* @see WebSettings.ZoomDensity
*/
public void setDefaultZoom(ZoomDensity zoom) {
@@ -393,9 +427,9 @@ public abstract class WebSettings {
}
/**
- * Get the default zoom density of the page. This should be called from UI
+ * Gets the default zoom density of the page. This should be called from UI
* thread.
- * @return A ZoomDensity value
+ * @return a ZoomDensity value
* @see WebSettings.ZoomDensity
*/
public ZoomDensity getDefaultZoom() {
@@ -410,15 +444,17 @@ public abstract class WebSettings {
}
/**
- * Returns true if light touches are enabled.
+ * Gets whether light touches are enabled.
*/
public boolean getLightTouchEnabled() {
throw new MustOverrideException();
}
/**
- * @deprecated This setting controlled a rendering optimization
- * that is no longer present. Setting it now has no effect.
+ * Controlled a rendering optimization that is no longer present. Setting
+ * it now has no effect.
+ *
+ * @deprecated This setting now has no effect.
*/
@Deprecated
public synchronized void setUseDoubleTree(boolean use) {
@@ -426,8 +462,10 @@ public abstract class WebSettings {
}
/**
- * @deprecated This setting controlled a rendering optimization
- * that is no longer present. Setting it now has no effect.
+ * Controlled a rendering optimization that is no longer present. Setting
+ * it now has no effect.
+ *
+ * @deprecated This setting now has no effect.
*/
@Deprecated
public synchronized boolean getUseDoubleTree() {
@@ -436,10 +474,10 @@ public abstract class WebSettings {
}
/**
- * Tell the WebView about user-agent string.
- * @param ua 0 if the WebView should use an Android user-agent string,
- * 1 if the WebView should use a desktop user-agent string.
+ * Tells the WebView about user-agent string.
*
+ * @param ua 0 if the WebView should use an Android user-agent string,
+ * 1 if the WebView should use a desktop user-agent string
* @deprecated Please use setUserAgentString instead.
*/
@Deprecated
@@ -448,11 +486,11 @@ public abstract class WebSettings {
}
/**
- * Return user-agent as int
- * @return int 0 if the WebView is using an Android user-agent string.
- * 1 if the WebView is using a desktop user-agent string.
- * -1 if the WebView is using user defined user-agent string.
+ * Gets the user-agent as an int.
*
+ * @return 0 if the WebView is using an Android user-agent string,
+ * 1 if the WebView is using a desktop user-agent string,
+ * -1 if the WebView is using user defined user-agent string
* @deprecated Please use getUserAgentString instead.
*/
@Deprecated
@@ -461,30 +499,34 @@ public abstract class WebSettings {
}
/**
- * Tell the WebView to use the wide viewport
+ * Tells the WebView to use the wide viewport.
*/
public synchronized void setUseWideViewPort(boolean use) {
throw new MustOverrideException();
}
/**
- * @return True if the WebView is using a wide viewport
+ * Gets whether the WebView is using a wide viewport.
+ *
+ * @return true if the WebView is using a wide viewport
*/
public synchronized boolean getUseWideViewPort() {
throw new MustOverrideException();
}
/**
- * Tell the WebView whether it supports multiple windows. TRUE means
- * that {@link WebChromeClient#onCreateWindow(WebView, boolean,
- * boolean, Message)} is implemented by the host application.
+ * Tells the WebView whether it supports multiple windows. TRUE means
+ * that {@link WebChromeClient#onCreateWindow(WebView, boolean,
+ * boolean, Message)} is implemented by the host application.
*/
public synchronized void setSupportMultipleWindows(boolean support) {
throw new MustOverrideException();
}
/**
- * @return True if the WebView is supporting multiple windows. This means
+ * Gets whether the WebView is supporting multiple windows.
+ *
+ * @return true if the WebView is supporting multiple windows. This means
* that {@link WebChromeClient#onCreateWindow(WebView, boolean,
* boolean, Message)} is implemented by the host application.
*/
@@ -493,9 +535,10 @@ public abstract class WebSettings {
}
/**
- * Set the underlying layout algorithm. This will cause a relayout of the
- * WebView.
- * @param l A LayoutAlgorithm enum specifying the algorithm to use.
+ * Sets the underlying layout algorithm. This will cause a relayout of the
+ * WebView. The default is NARROW_COLUMNS.
+ *
+ * @param l a LayoutAlgorithm enum specifying the algorithm to use
* @see WebSettings.LayoutAlgorithm
*/
public synchronized void setLayoutAlgorithm(LayoutAlgorithm l) {
@@ -503,9 +546,11 @@ public abstract class WebSettings {
}
/**
- * Return the current layout algorithm. The default is NARROW_COLUMNS.
- * @return LayoutAlgorithm enum value describing the layout algorithm
- * being used.
+ * Gets the current layout algorithm.
+ *
+ * @return a LayoutAlgorithm enum value describing the layout algorithm
+ * being used
+ * @see #setLayoutAlgorithm
* @see WebSettings.LayoutAlgorithm
*/
public synchronized LayoutAlgorithm getLayoutAlgorithm() {
@@ -513,164 +558,193 @@ public abstract class WebSettings {
}
/**
- * Set the standard font family name.
- * @param font A font family name.
+ * Sets the standard font family name. The default is "sans-serif".
+ *
+ * @param font a font family name
*/
public synchronized void setStandardFontFamily(String font) {
throw new MustOverrideException();
}
/**
- * Get the standard font family name. The default is "sans-serif".
- * @return The standard font family name as a string.
+ * Gets the standard font family name.
+ *
+ * @return the standard font family name as a string
+ * @see #setStandardFontFamily
*/
public synchronized String getStandardFontFamily() {
throw new MustOverrideException();
}
/**
- * Set the fixed font family name.
- * @param font A font family name.
+ * Sets the fixed font family name. The default is "monospace".
+ *
+ * @param font a font family name
*/
public synchronized void setFixedFontFamily(String font) {
throw new MustOverrideException();
}
/**
- * Get the fixed font family name. The default is "monospace".
- * @return The fixed font family name as a string.
+ * Gets the fixed font family name.
+ *
+ * @return the fixed font family name as a string
+ * @see #setFixedFontFamily
*/
public synchronized String getFixedFontFamily() {
throw new MustOverrideException();
}
/**
- * Set the sans-serif font family name.
- * @param font A font family name.
+ * Sets the sans-serif font family name.
+ *
+ * @param font a font family name
*/
public synchronized void setSansSerifFontFamily(String font) {
throw new MustOverrideException();
}
/**
- * Get the sans-serif font family name.
- * @return The sans-serif font family name as a string.
+ * Gets the sans-serif font family name.
+ *
+ * @return the sans-serif font family name as a string
*/
public synchronized String getSansSerifFontFamily() {
throw new MustOverrideException();
}
/**
- * Set the serif font family name. The default is "sans-serif".
- * @param font A font family name.
+ * Sets the serif font family name. The default is "sans-serif".
+ *
+ * @param font a font family name
*/
public synchronized void setSerifFontFamily(String font) {
throw new MustOverrideException();
}
/**
- * Get the serif font family name. The default is "serif".
- * @return The serif font family name as a string.
+ * Gets the serif font family name. The default is "serif".
+ *
+ * @return the serif font family name as a string
+ * @see #setSerifFontFamily
*/
public synchronized String getSerifFontFamily() {
throw new MustOverrideException();
}
/**
- * Set the cursive font family name.
- * @param font A font family name.
+ * Sets the cursive font family name. The default is "cursive".
+ *
+ * @param font a font family name
*/
public synchronized void setCursiveFontFamily(String font) {
throw new MustOverrideException();
}
/**
- * Get the cursive font family name. The default is "cursive".
- * @return The cursive font family name as a string.
+ * Gets the cursive font family name.
+ *
+ * @return the cursive font family name as a string
+ * @see #setCursiveFontFamily
*/
public synchronized String getCursiveFontFamily() {
throw new MustOverrideException();
}
/**
- * Set the fantasy font family name.
- * @param font A font family name.
+ * Sets the fantasy font family name. The default is "fantasy".
+ *
+ * @param font a font family name
*/
public synchronized void setFantasyFontFamily(String font) {
throw new MustOverrideException();
}
/**
- * Get the fantasy font family name. The default is "fantasy".
- * @return The fantasy font family name as a string.
+ * Gets the fantasy font family name.
+ *
+ * @return the fantasy font family name as a string
+ * @see #setFantasyFontFamily
*/
public synchronized String getFantasyFontFamily() {
throw new MustOverrideException();
}
/**
- * Set the minimum font size.
- * @param size A non-negative integer between 1 and 72.
- * Any number outside the specified range will be pinned.
+ * Sets the minimum font size. The default is 8.
+ *
+ * @param size a non-negative integer between 1 and 72. Any number outside
+ * the specified range will be pinned.
*/
public synchronized void setMinimumFontSize(int size) {
throw new MustOverrideException();
}
/**
- * Get the minimum font size. The default is 8.
- * @return A non-negative integer between 1 and 72.
+ * Gets the minimum font size.
+ *
+ * @return a non-negative integer between 1 and 72
+ * @see #setMinimumFontSize
*/
public synchronized int getMinimumFontSize() {
throw new MustOverrideException();
}
/**
- * Set the minimum logical font size.
- * @param size A non-negative integer between 1 and 72.
- * Any number outside the specified range will be pinned.
+ * Sets the minimum logical font size. The default is 8.
+ *
+ * @param size a non-negative integer between 1 and 72. Any number outside
+ * the specified range will be pinned.
*/
public synchronized void setMinimumLogicalFontSize(int size) {
throw new MustOverrideException();
}
/**
- * Get the minimum logical font size. The default is 8.
- * @return A non-negative integer between 1 and 72.
+ * Gets the minimum logical font size.
+ *
+ * @return a non-negative integer between 1 and 72
+ * @see #setMinimumLogicalFontSize
*/
public synchronized int getMinimumLogicalFontSize() {
throw new MustOverrideException();
}
/**
- * Set the default font size.
- * @param size A non-negative integer between 1 and 72.
- * Any number outside the specified range will be pinned.
+ * Sets the default font size. The default is 16.
+ *
+ * @param size a non-negative integer between 1 and 72. Any number outside
+ * the specified range will be pinned.
*/
public synchronized void setDefaultFontSize(int size) {
throw new MustOverrideException();
}
/**
- * Get the default font size. The default is 16.
- * @return A non-negative integer between 1 and 72.
+ * Gets the default font size.
+ *
+ * @return a non-negative integer between 1 and 72
+ * @see #setDefaultFontSize
*/
public synchronized int getDefaultFontSize() {
throw new MustOverrideException();
}
/**
- * Set the default fixed font size.
- * @param size A non-negative integer between 1 and 72.
- * Any number outside the specified range will be pinned.
+ * Sets the default fixed font size. The default is 16.
+ *
+ * @param size a non-negative integer between 1 and 72. Any number outside
+ * the specified range will be pinned.
*/
public synchronized void setDefaultFixedFontSize(int size) {
throw new MustOverrideException();
}
/**
- * Get the default fixed font size. The default is 16.
- * @return A non-negative integer between 1 and 72.
+ * Gets the default fixed font size.
+ *
+ * @return a non-negative integer between 1 and 72
+ * @see #setDefaultFixedFontSize
*/
public synchronized int getDefaultFixedFontSize() {
throw new MustOverrideException();
@@ -683,16 +757,20 @@ public abstract class WebSettings {
* of images specified using network URI schemes. Note that if the value of this
* setting is changed from false to true, all images resources referenced
* by content currently displayed by the WebView are loaded automatically.
- * @param flag Whether the WebView should load image resources.
+ * The default is true.
+ *
+ * @param flag whether the WebView should load image resources
*/
public synchronized void setLoadsImagesAutomatically(boolean flag) {
throw new MustOverrideException();
}
/**
- * Returns true if the WebView loads image resources. This includes
- * images embedded using the data URI scheme. The default is true.
- * @return True if the WebView loads image resources.
+ * Gets whether the WebView loads image resources. This includes
+ * images embedded using the data URI scheme.
+ *
+ * @return true if the WebView loads image resources
+ * @see #setLoadsImagesAutomatically
*/
public synchronized boolean getLoadsImagesAutomatically() {
throw new MustOverrideException();
@@ -707,9 +785,10 @@ public abstract class WebSettings {
* will also prevent network images from loading, even if this flag is set
* to false. When the value of this setting is changed from true to false,
* network images resources referenced by content currently displayed by
- * the WebView are fetched automatically.
- * @param flag Whether the WebView should not load image resources from
- * the network.
+ * the WebView are fetched automatically. The default is false.
+ *
+ * @param flag whether the WebView should not load image resources from the
+ * network
* @see #setBlockNetworkLoads
*/
public synchronized void setBlockNetworkImage(boolean flag) {
@@ -717,9 +796,10 @@ public abstract class WebSettings {
}
/**
- * Returns true if the WebView does not load image resources from the network.
- * The default is false.
- * @return True if the WebView does not load image resources from the network.
+ * Gets whether the WebView does not load image resources from the network.
+ *
+ * @return true if the WebView does not load image resources from the network
+ * @see #setBlockNetworkImage
*/
public synchronized boolean getBlockNetworkImage() {
throw new MustOverrideException();
@@ -735,9 +815,12 @@ public abstract class WebSettings {
* If the application does not have the
* {@link android.Manifest.permission#INTERNET} permission, attempts to set
* a value of false will cause a {@link java.lang.SecurityException}
- * to be thrown.
- * @param flag Whether the WebView should not load any resources
- * from the network.
+ * to be thrown. The default value is false if the application has the
+ * {@link android.Manifest.permission#INTERNET} permission, otherwise it is
+ * true.
+ *
+ * @param flag whether the WebView should not load any resources from the
+ * network
* @see android.webkit.WebView#reload
*/
public synchronized void setBlockNetworkLoads(boolean flag) {
@@ -745,50 +828,52 @@ public abstract class WebSettings {
}
/**
- * Returns true if the WebView does not load any resources from the network.
- * The default value is false if the application has the
- * {@link android.Manifest.permission#INTERNET} permission, otherwise it is
- * true.
- * @return True if the WebView does not load any resources from the network.
+ * Gets whether the WebView does not load any resources from the network.
+ *
+ * @return true if the WebView does not load any resources from the network
+ * @see #setBlockNetworkLoads
*/
public synchronized boolean getBlockNetworkLoads() {
throw new MustOverrideException();
}
/**
- * Tell the WebView to enable javascript execution.
- * @param flag True if the WebView should execute javascript.
+ * Tells the WebView to enable JavaScript execution.
+ * <b>The default is false.</b>
+ *
+ * @param flag true if the WebView should execute JavaScript
*/
public synchronized void setJavaScriptEnabled(boolean flag) {
throw new MustOverrideException();
}
/**
- * Configure scripting (such as XmlHttpRequest) access from file scheme URLs
+ * Configures scripting (such as XmlHttpRequest) access from file scheme URLs
* to any origin. Note, calling this method with a true argument value also
* implies calling setAllowFileAccessFromFileURLs with a true. The default
* value is false for API level {@link android.os.Build.VERSION_CODES#JELLY_BEAN}
* and higher and true otherwise.
*
- . * @param flag True if the WebView should allow scripting access from file
- * scheme URLs to any origin
+ * @param flag true if the WebView should allow scripting access from file
+ * scheme URLs to any origin
*/
public abstract void setAllowUniversalAccessFromFileURLs(boolean flag);
/**
- * Configure scripting (such as XmlHttpRequest) access from file scheme URLs
+ * Configures scripting (such as XmlHttpRequest) access from file scheme URLs
* to file origin. The default value is false for API level
* {@link android.os.Build.VERSION_CODES#JELLY_BEAN} and higher and true
* otherwise.
*
- * @param flag True if the WebView should allow scripting access from file
- * scheme URLs to file origin
+ * @param flag true if the WebView should allow scripting access from file
+ * scheme URLs to file origin
*/
public abstract void setAllowFileAccessFromFileURLs(boolean flag);
/**
- * Tell the WebView to enable plugins.
- * @param flag True if the WebView should load plugins.
+ * Tells the WebView to enable plugins.
+ *
+ * @param flag true if the WebView should load plugins
* @deprecated This method has been deprecated in favor of
* {@link #setPluginState}
*/
@@ -798,22 +883,24 @@ public abstract class WebSettings {
}
/**
- * Tell the WebView to enable, disable, or have plugins on demand. On
+ * Tells the WebView to enable, disable, or have plugins on demand. On
* demand mode means that if a plugin exists that can handle the embedded
* content, a placeholder icon will be shown instead of the plugin. When
* the placeholder is clicked, the plugin will be enabled.
- * @param state One of the PluginState values.
+ *
+ * @param state a PluginState value
*/
public synchronized void setPluginState(PluginState state) {
throw new MustOverrideException();
}
/**
- * Set a custom path to plugins used by the WebView. This method is
+ * Sets a custom path to plugins used by the WebView. This method is
* obsolete since each plugin is now loaded from its own package.
- * @param pluginsPath String path to the directory containing plugins.
+ *
+ * @param pluginsPath a String path to the directory containing plugins
* @deprecated This method is no longer used as plugins are loaded from
- * their own APK via the system's package manager.
+ * their own APK via the system's package manager.
*/
@Deprecated
public synchronized void setPluginsPath(String pluginsPath) {
@@ -821,91 +908,101 @@ public abstract class WebSettings {
}
/**
- * Set the path to where database storage API databases should be saved.
- * Nota that the WebCore Database Tracker only allows the path to be set once.
- * This will update WebCore when the Sync runs in the C++ side.
- * @param databasePath String path to the directory where databases should
- * be saved. May be the empty string but should never be null.
+ * Sets the path to where database storage API databases should be saved.
+ * Note that the WebCore Database Tracker only allows the path to be set once.
+ *
+ * @param databasePath a String path to the directory where databases should
+ * be saved. May be the empty string but should never
+ * be null.
*/
+ // This will update WebCore when the Sync runs in the C++ side.
public synchronized void setDatabasePath(String databasePath) {
throw new MustOverrideException();
}
/**
- * Set the path where the Geolocation permissions database should be saved.
- * This will update WebCore when the Sync runs in the C++ side.
- * @param databasePath String path to the directory where the Geolocation
- * permissions database should be saved. May be the empty string but
- * should never be null.
+ * Sets the path where the Geolocation permissions database should be saved.
+ *
+ * @param databasePath a String path to the directory where the Geolocation
+ * permissions database should be saved. May be the
+ * empty string but should never be null.
*/
+ // This will update WebCore when the Sync runs in the C++ side.
public synchronized void setGeolocationDatabasePath(String databasePath) {
throw new MustOverrideException();
}
/**
- * Tell the WebView to enable Application Caches API.
- * @param flag True if the WebView should enable Application Caches.
+ * Tells the WebView to enable Application Caches API.
+ *
+ * @param flag true if the WebView should enable Application Caches
*/
public synchronized void setAppCacheEnabled(boolean flag) {
throw new MustOverrideException();
}
/**
- * Set a custom path to the Application Caches files. The client
+ * Sets a custom path to the Application Caches files. The client
* must ensure it exists before this call.
- * @param appCachePath String path to the directory containing Application
- * Caches files. The appCache path can be the empty string but should not
- * be null. Passing null for this parameter will result in a no-op.
+ *
+ * @param appCachePath a String path to the directory containing
+ * Application Caches files. The appCache path can be
+ * the empty string but should not be null. Passing
+ * null for this parameter will result in a no-op.
*/
public synchronized void setAppCachePath(String appCachePath) {
throw new MustOverrideException();
}
/**
- * Set the maximum size for the Application Caches content.
- * @param appCacheMaxSize the maximum size in bytes.
+ * Sets the maximum size for the Application Caches content.
+ *
+ * @param appCacheMaxSize the maximum size in bytes
*/
public synchronized void setAppCacheMaxSize(long appCacheMaxSize) {
throw new MustOverrideException();
}
/**
- * Set whether the database storage API is enabled.
- * @param flag boolean True if the WebView should use the database storage
- * API.
+ * Sets whether the database storage API is enabled.
+ *
+ * @param flag true if the WebView should use the database storage API
*/
public synchronized void setDatabaseEnabled(boolean flag) {
throw new MustOverrideException();
}
/**
- * Set whether the DOM storage API is enabled.
- * @param flag boolean True if the WebView should use the DOM storage
- * API.
+ * Sets whether the DOM storage API is enabled.
+ *
+ * @param flag true if the WebView should use the DOM storage API
*/
public synchronized void setDomStorageEnabled(boolean flag) {
throw new MustOverrideException();
}
/**
- * Returns true if the DOM Storage API's are enabled.
- * @return True if the DOM Storage API's are enabled.
+ * Gets whether the DOM Storage APIs are enabled.
+ *
+ * @return true if the DOM Storage APIs are enabled
*/
public synchronized boolean getDomStorageEnabled() {
throw new MustOverrideException();
}
/**
- * Return the path to where database storage API databases are saved for
+ * Gets the path to where database storage API databases are saved for
* the current WebView.
- * @return the String path to the database storage API databases.
+ *
+ * @return the String path to the database storage API databases
*/
public synchronized String getDatabasePath() {
throw new MustOverrideException();
}
/**
- * Returns true if database storage API is enabled.
- * @return True if the database storage API is enabled.
+ * Gets whether the database storage API is enabled.
+ *
+ * @return true if the database storage API is enabled
*/
public synchronized boolean getDatabaseEnabled() {
throw new MustOverrideException();
@@ -913,43 +1010,47 @@ public abstract class WebSettings {
/**
* Sets whether Geolocation is enabled.
- * @param flag Whether Geolocation should be enabled.
+ *
+ * @param flag whether Geolocation should be enabled
*/
public synchronized void setGeolocationEnabled(boolean flag) {
throw new MustOverrideException();
}
/**
- * Return true if javascript is enabled. <b>Note: The default is false.</b>
- * @return True if javascript is enabled.
+ * Gets whether JavaScript is enabled.
+ *
+ * @return true if JavaScript is enabled
+ * @see #setJavaScriptEnabled
*/
public synchronized boolean getJavaScriptEnabled() {
throw new MustOverrideException();
}
/**
- * Return true if scripting access {see @setAllowUniversalAccessFromFileURLs} from
- * file URLs to any origin is enabled. The default value is false for API level
- * {@link android.os.Build.VERSION_CODES#JELLY_BEAN} and higher and true otherwise.
+ * Gets whether scripting access {see @setAllowUniversalAccessFromFileURLs} from
+ * file URLs to any origin is enabled.
*
- * @return True if the WebView allows scripting access from file scheme requests
- * to any origin
+ * @return true if the WebView allows scripting access from file scheme requests
+ * to any origin
+ * @see #setAllowUniversalAccessFromFileURLs
*/
public abstract boolean getAllowUniversalAccessFromFileURLs();
/**
- * Return true if scripting access {see @setAllowFileAccessFromFileURLs} from file
- * URLs to file origin is enabled. The default value is false for API level
- * {@link android.os.Build.VERSION_CODES#JELLY_BEAN} and higher, and true otherwise.
+ * Gets whether scripting access {see @setAllowFileAccessFromFileURLs} from file
+ * URLs to file origin is enabled.
*
- * @return True if the WebView allows scripting access from file scheme requests
- * to file origin
+ * @return true if the WebView allows scripting access from file scheme requests
+ * to file origin
+ * @see #setAllowFileAccessFromFileURLs
*/
public abstract boolean getAllowFileAccessFromFileURLs();
/**
- * Return true if plugins are enabled.
- * @return True if plugins are enabled.
+ * Gets whether plugins are enabled.
+ *
+ * @return true if plugins are enabled
* @deprecated This method has been replaced by {@link #getPluginState}
*/
@Deprecated
@@ -958,17 +1059,19 @@ public abstract class WebSettings {
}
/**
- * Return the current plugin state.
- * @return A value corresponding to the enum PluginState.
+ * Gets the current plugin state.
+ *
+ * @return a value corresponding to the enum PluginState
*/
public synchronized PluginState getPluginState() {
throw new MustOverrideException();
}
/**
- * Returns the directory that contains the plugin libraries. This method is
+ * Gets the directory that contains the plugin libraries. This method is
* obsolete since each plugin is now loaded from its own package.
- * @return An empty string.
+ *
+ * @return an empty string
* @deprecated This method is no longer used as plugins are loaded from
* their own APK via the system's package manager.
*/
@@ -979,41 +1082,47 @@ public abstract class WebSettings {
}
/**
- * Tell javascript to open windows automatically. This applies to the
- * javascript function window.open().
- * @param flag True if javascript can open windows automatically.
+ * Tells JavaScript to open windows automatically. This applies to the
+ * JavaScript function window.open(). The default is false.
+ *
+ * @param flag true if JavaScript can open windows automatically
*/
public synchronized void setJavaScriptCanOpenWindowsAutomatically(boolean flag) {
throw new MustOverrideException();
}
/**
- * Return true if javascript can open windows automatically. The default
- * is false.
- * @return True if javascript can open windows automatically during
- * window.open().
+ * Gets whether JavaScript can open windows automatically.
+ *
+ * @return true if JavaScript can open windows automatically during
+ * window.open()
+ * @see #setJavaScriptCanOpenWindowsAutomatically
*/
public synchronized boolean getJavaScriptCanOpenWindowsAutomatically() {
throw new MustOverrideException();
}
/**
- * Set the default text encoding name to use when decoding html pages.
- * @param encoding The text encoding name.
+ * Sets the default text encoding name to use when decoding html pages.
+ * The default is "Latin-1".
+ *
+ * @param encoding the text encoding name
*/
public synchronized void setDefaultTextEncodingName(String encoding) {
throw new MustOverrideException();
}
/**
- * Get the default text encoding name. The default is "Latin-1".
- * @return The default text encoding name as a string.
+ * Gets the default text encoding name.
+ *
+ * @return the default text encoding name as a string
+ * @see #setDefaultTextEncodingName
*/
public synchronized String getDefaultTextEncodingName() {
throw new MustOverrideException();
}
/**
- * Set the WebView's user-agent string. If the string "ua" is null or empty,
+ * Sets the WebView's user-agent string. If the string "ua" is null or empty,
* it will use the system default user-agent string.
*/
public synchronized void setUserAgentString(String ua) {
@@ -1021,46 +1130,47 @@ public abstract class WebSettings {
}
/**
- * Return the WebView's user-agent string.
+ * Gets the WebView's user-agent string.
*/
public synchronized String getUserAgentString() {
throw new MustOverrideException();
}
/**
- * Tell the WebView whether it needs to set a node to have focus when
+ * Tells the WebView whether it needs to set a node to have focus when
* {@link WebView#requestFocus(int, android.graphics.Rect)} is called.
*
- * @param flag
+ * @param flag whether the WebView needs to set a node
*/
public void setNeedInitialFocus(boolean flag) {
throw new MustOverrideException();
}
/**
- * Set the priority of the Render thread. Unlike the other settings, this
+ * Sets the priority of the Render thread. Unlike the other settings, this
* one only needs to be called once per process. The default is NORMAL.
*
- * @param priority RenderPriority, can be normal, high or low.
+ * @param priority a RenderPriority
*/
public synchronized void setRenderPriority(RenderPriority priority) {
throw new MustOverrideException();
}
/**
- * Override the way the cache is used. The way the cache is used is based
+ * Overrides the way the cache is used. The way the cache is used is based
* on the navigation option. For a normal page load, the cache is checked
* and content is re-validated as needed. When navigating back, content is
* not revalidated, instead the content is just pulled from the cache.
* This function allows the client to override this behavior.
- * @param mode One of the LOAD_ values.
+ *
+ * @param mode one of the LOAD_ values
*/
public void setCacheMode(int mode) {
throw new MustOverrideException();
}
/**
- * Return the current setting for overriding the cache mode. For a full
+ * Gets the current setting for overriding the cache mode. For a full
* description, see the {@link #setCacheMode(int)} function.
*/
public int getCacheMode() {