nsIApplicationCacheService 编辑
netwerk/base/public/nsIApplicationCacheService.idl
Scriptable This interface manages the set of application cache groups that manage offline resources for web applications. 1.0 66 Introduced Gecko 1.9.1 Inherits from: nsISupports
Last changed in Gecko 1.9.1 (Firefox 3.5 / Thunderbird 3.0 / SeaMonkey 2.0)Method overview
void cacheOpportunistically(in nsIApplicationCache cache, in ACString key); |
nsIApplicationCache chooseApplicationCache(in ACString key); |
nsIApplicationCache createApplicationCache(in ACString group); |
void deactivateGroup(in ACString group); |
nsIApplicationCache getActiveCache(in ACString group); |
nsIApplicationCache getApplicationCache(in ACString clientID); |
void getGroups([optional] out unsigned long count, [array, size_is(count), retval] out string groupIDs); |
Methods
cacheOpportunistically()
Flags the specified key as one that should be cached opportunistically.
Note: This method should propagate the entry to other application caches with the same opportunistic namespace; however, this is not currently implemented.void cacheOpportunistically( in nsIApplicationCache cache, in ACString key );
Parameters
cache
- The cache in which the entry is currently cached.
key
- The cache entry's key.
chooseApplicationCache()
Tries to find the best application cache to serve a specified resource.
nsIApplicationCache chooseApplicationCache( in ACString key );
Parameters
key
- The cache entry key for which to select an application cache.
Return value
The nsIApplicationCache
best able to serve the resource indicated by the key
parameter.
createApplicationCache()
Creates a new, empty application cache for the specified cache group.
nsIApplicationCache createApplicationCache( in ACString group );
Parameters
group
- The cache group for which to create an application cache.
Return value
The newly-created nsIApplicationCache
.
deactivateGroup()
Deactivates the currently active cache object for the specified cache group.
void deactivateGroup( in ACString group );
Parameters
group
- The cache group to deactivate.
getActiveCache()
Returns the currently active cache object for a cache group.
nsIApplicationCache getActiveCache( in ACString group );
Parameters
group
- The cache group for which to return an application cache.
Return value
The currently active cache object for the cache group.
getApplicationCache()
Returns the nsIApplicationCache
object for the specified client ID.
nsIApplicationCache getApplicationCache( in ACString clientID );
Parameters
clientID
- The client ID for which to return the application cache object.
Return value
The application cache object for the specified client ID.
getGroups()
Returns the list of application cache groups.
void getGroups( out unsigned long count, Optional [array, size_is(count), retval] out string groupIDs );
Parameters
count
Optional- The count of the application cache groups.
groupIDs
- The list of application cache groups.
See also
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论