From 218934fa2ed1c702a6d3923d2aa2cc6b43c48684 Mon Sep 17 00:00:00 2001 From: Peter Bengtsson Date: Tue, 8 Dec 2020 14:43:23 -0500 Subject: initial commit --- files/tr/web/api/idbindex/getall/index.html | 164 ++++++++++++++++++++++++++++ 1 file changed, 164 insertions(+) create mode 100644 files/tr/web/api/idbindex/getall/index.html (limited to 'files/tr/web/api/idbindex/getall') diff --git a/files/tr/web/api/idbindex/getall/index.html b/files/tr/web/api/idbindex/getall/index.html new file mode 100644 index 0000000000..dfbd31c48d --- /dev/null +++ b/files/tr/web/api/idbindex/getall/index.html @@ -0,0 +1,164 @@ +--- +title: IDBIndex.getAll() +slug: Web/API/IDBIndex/getAll +translation_of: Web/API/IDBIndex/getAll +--- +

{{ APIRef("IndexedDB") }}

+ +
+

getAll() metodu {{domxref("IDBIndex")}} Arabirimi, dizinin içindeki tüm nesneleri alır.

+
+ +

Nesne tembel olarak oluşturulduğundan, bir imlecin value özelliğine bakmakla ilişkili bir performans maliyeti söz konusudur. GetAll () gibi bir özellik kullanmak için, tarayıcının tüm nesneleri aynı anda oluşturması gerekir. Örneğin sadece anahtarların her birine bakmak istiyorsanız, bir imleci kullanmak daha etkilidir. Ancak, bir nesne deposundaki tüm nesnelerin bir dizisini almaya çalışıyorsanız, getAll () kullanmalısınız.

+ +

Syntax

+ +
var getAllKeysRequest = IDBIndex.getAll();
+var getAllKeysRequest = IDBIndex.getAll(query);
+var getAllKeysRequest = IDBIndex.getAll(query, count);
+ +

Parametreler

+ +
+
query {{optional_inline}}
+
A key or an {{domxref("IDBKeyRange")}} identifying the records to retrieve. If this value is null or missing, the browser will use an unbound key range.
+
count {{optional_inline}}
+
The number records to return. If this value exceeds the number of records in the query, the browser will only retrieve the first item. If it is lower than 0 or greater than 232-1 a {{jsxref("TypeError")}} exception will be thrown.
+
+ +

Return value

+ +

An {{domxref("IDBRequest")}} object on which subsequent events related to this operation are fired.

+ +

Exceptions

+ +

This method may raise a {{domxref("DOMException")}} of the following types:

+ + + + + + + + + + + + + + + + + + +
ExceptionDescription
TransactionInactiveErrorThis {{domxref("IDBIndex")}}'s transaction is inactive.
InvalidStateErrorThe {{domxref("IDBIndex")}} has been deleted or removed.
+ +

A {{jsxref("TypeError")}} exception is thrown if the count parameter is not between 0 and 232-1 included.

+ +

Example

+ +
var myIndex = objectStore.index('index');
+var getAllKeysRequest = myIndex.getAllKeys();
+getAllKeysRequest.onsuccess = function() {
+  console.log(getAllKeysRequest.result);
+}
+ +

Specification

+ + + + + + + + + + + + + + +
SpecificationStatusComment
{{SpecName('IndexedDB 2', '#dom-idbindex-getall', 'getAll()')}}{{Spec2('IndexedDB 2')}}Initial definition.
+ +

Browser compatibility

+ +

{{ CompatibilityTable }}

+ +
+ + + + + + + + + + + + + + + + + + + + + + + + + + + +
FeatureChromeFirefox (Gecko)Internet ExplorerOperaSafari (WebKit)
Basic support{{ CompatChrome(48) }}{{ CompatGeckoDesktop("44.0") }} [1]{{ CompatNo }}{{CompatOpera(35)}}{{ CompatNo}}
Indexed Database 2.0{{CompatChrome(58)}}{{CompatUnknown}}{{CompatUnknown}}{{CompatOpera(45)}}{{CompatUnknown}}
+
+ +
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
FeatureAndroid WebviewChrome for AndroidFirefox Mobile (Gecko)IE PhoneOpera MobileSafari Mobile
Basic support{{ CompatChrome(48) }}{{ CompatChrome(48) }}{{ CompatGeckoDesktop("44.0") }} [1]{{ CompatNo}}{{CompatOperaMobile(35)}}{{ CompatNo}}
Indexed Database 2.0{{CompatChrome(58)}}{{CompatChrome(58)}}{{CompatUnknown}}{{CompatUnknown}}{{CompatOperaMobile(45)}}{{CompatUnknown}}
+
+ +

 [1] This feature was available since Firefox 24, but behind the dom.indexedDB.experimental  pref, off by default

+ +

See also

+ + -- cgit v1.2.3-54-g00ecf