|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectnet.sourceforge.htmlunit.corejs.javascript.ScriptableObject
com.gargoylesoftware.htmlunit.javascript.SimpleScriptable
com.gargoylesoftware.htmlunit.javascript.host.OfflineResourceList
public class OfflineResourceList
A collection of offline resources as defined in the HTML5 spec. Intended to support offline web applications.
NOTE: This class is essentially a skeleton implementation providing minimal compatibility while we wait for the HTML5 dust to settle. The first real browser we should worry about supporting with this implementation will probably be either Firefox 3.5 or Firefox 4.
Nested Class Summary |
---|
Nested classes/interfaces inherited from interface java.util.Map |
---|
Map.Entry<K,V> |
Field Summary | |
---|---|
static short |
STATUS_CHECKING
The application cache manifest is being fetched and checked for updates. |
static short |
STATUS_DOWNLOADING
Resources are being downloaded to be added to the cache. |
static short |
STATUS_IDLE
The application cache is not in the process of being updated. |
static short |
STATUS_OBSOLETE
The application cache group is now obsolete. |
static short |
STATUS_UNCACHED
The object isn't associated with an application cache. |
static short |
STATUS_UPDATEREADY
There is a new version of the application cache available. |
Fields inherited from class net.sourceforge.htmlunit.corejs.javascript.ScriptableObject |
---|
CONST, DONTENUM, EMPTY, PERMANENT, READONLY, UNINITIALIZED_CONST |
Fields inherited from interface net.sourceforge.htmlunit.corejs.javascript.Scriptable |
---|
NOT_FOUND |
Constructor Summary | |
---|---|
OfflineResourceList()
|
Method Summary | |
---|---|
void |
jsxFunction_add(String uri)
Adds an item to the dynamically managed entries. |
boolean |
jsxFunction_hasItem(String uri)
Returns true if the specified URI represents a resource that's in the application cache's list. |
String |
jsxFunction_item(int index)
Returns the URI of the item at the specific offset into the list of cached resources. |
void |
jsxFunction_remove(String uri)
Removes an item from the list of dynamically managed entries. |
void |
jsxFunction_swapCache()
Swaps in the newest version of the application cache. |
void |
jsxFunction_update()
Begins the application cache update process. |
int |
jsxGet_length()
Returns the number of entries in the dynamically managed offline resource list. |
Object |
jsxGet_oncached()
Returns the event listener to be called when caching is complete. |
Object |
jsxGet_onchecking()
Returns the event listener to be called when fetching the application cache manifest and checking for updates. |
Object |
jsxGet_ondownloading()
Returns the event listener to be called when resources are being downloaded into the cache. |
Object |
jsxGet_onerror()
Returns the event listener to be called when an error occurs during the caching process. |
Object |
jsxGet_onnoupdate()
Returns the event listener to be called when there is no update to download. |
Object |
jsxGet_onprogress()
Returns the event listener to be called periodically throughout the download process. |
Object |
jsxGet_onupdateready()
Returns the event listener to be called when a resource update is ready. |
short |
jsxGet_status()
Returns the status of the application cache. |
void |
jsxSet_oncached(Object o)
Sets the event listener to be called when caching is complete. |
void |
jsxSet_onchecking(Object o)
Sets the event listener to be called when fetching the application cache manifest and checking for updates. |
void |
jsxSet_ondownloading(Object o)
Sets the event listener to be called when resources are being downloaded into the cache. |
void |
jsxSet_onerror(Object o)
Sets the event listener to be called when an error occurs during the caching process. |
void |
jsxSet_onnoupdate(Object o)
Sets the event listener to be called when there is no update to download. |
void |
jsxSet_onprogress(Object o)
Sets the event listener to be called periodically throughout the download process. |
void |
jsxSet_onupdateready(Object o)
Sets the event listener to be called when a resource update is ready. |
Methods inherited from class com.gargoylesoftware.htmlunit.javascript.SimpleScriptable |
---|
clone, defineFunctionProperties, defineProperty, equivalentValues, get, getBrowserVersion, getClassName, getDefaultValue, getDomNodeOrDie, getDomNodeOrNull, getPrototype, getScriptableFor, getStartingScope, getTransformerScriptableFor, getWindow, getWindow, getWithPreemption, hasInstance, initParentScope, makeScriptableFor, setCaseSensitive, setDomNode, setDomNode, setHtmlElement |
Methods inherited from class net.sourceforge.htmlunit.corejs.javascript.ScriptableObject |
---|
applyDescriptorToAttributeBitset, associateValue, avoidObjectDetection, buildDataDescriptor, callMethod, callMethod, clear, containsKey, containsValue, defineClass, defineClass, defineClass, defineConst, defineConstProperty, defineOwnProperties, defineOwnProperty, defineProperty, defineProperty, defineProperty, delete, delete, deleteProperty, deleteProperty, ensureScriptable, ensureScriptableObject, entrySet, get, get, getAllIds, getArrayPrototype, getAssociatedValue, getAttributes, getAttributes, getAttributes, getAttributes, getClassPrototype, getDefaultValue, getFunctionPrototype, getGetterOrSetter, getIds, getObjectPrototype, getOwnPropertyDescriptor, getParentScope, getProperty, getProperty, getPropertyIds, getPrototype, getSlot, getTopLevelScope, getTopScopeValue, getTypeOf, has, has, hasProperty, hasProperty, isAccessorDescriptor, isConst, isDataDescriptor, isEmpty, isExtensible, isFalse, isGenericDescriptor, isGetterOrSetter, isSealed, isTrue, keySet, preventExtensions, put, put, put, putAll, putConst, putConstProperty, putProperty, putProperty, redefineProperty, remove, sealObject, setAttributes, setAttributes, setAttributes, setAttributes, setGetterOrSetter, setParentScope, setPrototype, size, values |
Methods inherited from class java.lang.Object |
---|
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface java.util.Map |
---|
equals, hashCode |
Field Detail |
---|
public static final short STATUS_UNCACHED
public static final short STATUS_IDLE
public static final short STATUS_CHECKING
public static final short STATUS_DOWNLOADING
public static final short STATUS_UPDATEREADY
public static final short STATUS_OBSOLETE
Constructor Detail |
---|
public OfflineResourceList()
Method Detail |
---|
public Object jsxGet_onchecking()
public void jsxSet_onchecking(Object o)
o
- the event listener to be called when fetching the application cache manifest and checking for updatespublic Object jsxGet_onerror()
public void jsxSet_onerror(Object o)
o
- the event listener to be called when an error occurs during the caching processpublic Object jsxGet_onnoupdate()
public void jsxSet_onnoupdate(Object o)
o
- the event listener to be called when there is no update to downloadpublic Object jsxGet_ondownloading()
public void jsxSet_ondownloading(Object o)
o
- the event listener to be called when resources are being downloaded into the cachepublic Object jsxGet_onprogress()
public void jsxSet_onprogress(Object o)
o
- the event listener to be called periodically throughout the download processpublic Object jsxGet_onupdateready()
public void jsxSet_onupdateready(Object o)
o
- the event listener to be called when a resource update is readypublic Object jsxGet_oncached()
public void jsxSet_oncached(Object o)
o
- the event listener to be called when caching is completepublic short jsxGet_status()
public int jsxGet_length()
public void jsxFunction_add(String uri)
uri
- the URI of the item to add to the dynamically managed entriespublic boolean jsxFunction_hasItem(String uri)
uri
- the URI to check
public String jsxFunction_item(int index)
index
- the index of the cached item whose URI should be returned
public void jsxFunction_remove(String uri)
uri
- the URI to removepublic void jsxFunction_swapCache()
public void jsxFunction_update()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |