ee.FeatureCollection.toList

यह फ़ंक्शन, किसी कलेक्शन के एलिमेंट को सूची के तौर पर दिखाता है.

इस्तेमालरिटर्न
FeatureCollection.toList(count, offset)सूची
आर्ग्यूमेंटटाइपविवरण
यह: collectionFeatureCollectionवह इनपुट कलेक्शन जिसे फ़ेच करना है.
countपूर्णांकफ़ेच किए जाने वाले ज़्यादा से ज़्यादा एलिमेंट की संख्या.
offsetपूर्णांक, डिफ़ॉल्ट: 0शुरुआत से हटाए जाने वाले एलिमेंट की संख्या. अगर यह सेट है, तो (ऑफ़सेट + गिनती) एलिमेंट फ़ेच किए जाएंगे और पहले ऑफ़सेट एलिमेंट खारिज कर दिए जाएंगे.

उदाहरण

कोड एडिटर (JavaScript)

// FeatureCollection of power plants in Belgium.
var fc = ee.FeatureCollection('WRI/GPPD/power_plants')
             .filter('country_lg == "Belgium"');

print('First 5 features to an ee.List', fc.toList(5));

print('Second 5 features to an ee.List', fc.toList(5, 5));

Python सेटअप करना

Python API और इंटरैक्टिव डेवलपमेंट के लिए geemap का इस्तेमाल करने के बारे में जानकारी पाने के लिए, Python एनवायरमेंट पेज देखें.

import ee
import geemap.core as geemap

Colab (Python)

# FeatureCollection of power plants in Belgium.
fc = ee.FeatureCollection('WRI/GPPD/power_plants').filter(
    'country_lg == "Belgium"')

print('First 5 features to an ee.List:', fc.toList(5).getInfo())

print('Second 5 features to an ee.List:', fc.toList(5, 5).getInfo())