I'd love it if someone spent some time on getting agreement at W3C
about some of the low-hanging fruit like this. Functions like

objectStore.getAll
objectStore.getAllKeys
index.getAll
index.getAllKeys
objectStore.openKeyCursor

feel pretty obvious and should just be added to the IDB v2 spec
drafts. All it'd take is a pull request I think.

/ Jonas



On Mon, Mar 23, 2015 at 12:56 AM, Andrew Sutherland
<[email protected]> wrote:
> I would like to be able to use the IDBObjectStore.getAllKeys method.  It is
> gated on the
> mozilla::dom::indexedDB::IndexedDatabaseManager::ExperimentalFeaturesEnabled
> check which currently just changes based on the dom.indexedDB.experimental
> pref.  I would propose it could also return true for privileged apps.
>
> My rationale is that:
> - https://bugzil.la/920633 implies that getAllKeys is standards track
> - no one shouted Jonas down when he mentioned it in
> https://lists.w3.org/Archives/Public/public-webapps/2014AprJun/0177.html
> - Even if it doesn't get standardized, Jonas's recent posts imply we
> recognize that some APIs are simply proprietary.  Of course, this would mean
> we should probably prefix these with "moz" so we don't screw up the true v2
> IndexedDB standard (in addition to gating on privileged).
> - My workaround will be to put the key as the value too and use mozGetAll so
> my hands are already dirty.  (If I knew that our cursors did
> prefetching/batching and supported some type of hinting, I'd do that instead
> to keep my hands more clean.  I'm basically hand-rolling
> https://www.w3.org/Bugs/Public/show_bug.cgi?id=10000 "Allow expressions in
> addition to keyPaths when creating indexes".)
>
> Can/should we do this?  No is okay.
>
> Andrew
> _______________________________________________
> dev-b2g mailing list
> [email protected]
> https://lists.mozilla.org/listinfo/dev-b2g
_______________________________________________
dev-b2g mailing list
[email protected]
https://lists.mozilla.org/listinfo/dev-b2g

Reply via email to