ui.data.ActiveDictionary
संग्रह की मदद से व्यवस्थित रहें
अपनी प्राथमिकताओं के आधार पर, कॉन्टेंट को सेव करें और कैटगरी में बांटें.
यूज़र इंटरफ़ेस (यूआई) कॉम्पोनेंट में इस्तेमाल करने के लिए, डेटा का डिक्शनरी जैसा कंटेनर.
जब ui.data.ActiveDictionary की कोई प्रॉपर्टी (उदाहरण के लिए, myButton.style()) अपडेट की जाती है, तो उससे जुड़ा कॉम्पोनेंट अपने-आप अपडेट हो जाता है. उदाहरण के लिए, myButton.style().set('color', 'red') से बटन के टेक्स्ट का रंग लाल हो जाएगा.
इस्तेमाल | रिटर्न |
---|
ui.data.ActiveDictionary(object, allowedProperties) | ui.data.ActiveDictionary |
आर्ग्यूमेंट | टाइप | विवरण |
---|
object | ऑब्जेक्ट, ज़रूरी नहीं | इस ऑब्जेक्ट को शुरू करने के लिए, प्रॉपर्टी और वैल्यू वाला JavaScript ऑब्जेक्ट. |
allowedProperties | List<String>, ज़रूरी नहीं | इस ऑब्जेक्ट के लिए इस्तेमाल की जा सकने वाली प्रॉपर्टी का कलेक्शन. अगर इसकी कोई वैल्यू नहीं दी गई है, तो किसी भी प्रॉपर्टी का इस्तेमाल किया जा सकता है. |
जब तक कुछ अलग से न बताया जाए, तब तक इस पेज की सामग्री को Creative Commons Attribution 4.0 License के तहत और कोड के नमूनों को Apache 2.0 License के तहत लाइसेंस मिला है. ज़्यादा जानकारी के लिए, Google Developers साइट नीतियां देखें. Oracle और/या इससे जुड़ी हुई कंपनियों का, Java एक रजिस्टर किया हुआ ट्रेडमार्क है.
आखिरी बार 2025-07-25 (UTC) को अपडेट किया गया.
[null,null,["आखिरी बार 2025-07-25 (UTC) को अपडेट किया गया."],[[["\u003cp\u003eui.data.ActiveDictionary is a container for storing data used by UI components, similar to a dictionary.\u003c/p\u003e\n"],["\u003cp\u003eChanges to an ActiveDictionary's properties automatically update the associated UI component, ensuring data and UI stay in sync.\u003c/p\u003e\n"],["\u003cp\u003eYou can create an ActiveDictionary using \u003ccode\u003eui.data.ActiveDictionary(object, allowedProperties)\u003c/code\u003e and optionally provide initial data and allowed properties.\u003c/p\u003e\n"]]],[],null,["# ui.data.ActiveDictionary\n\n\u003cbr /\u003e\n\nA dictionary-like container for data for use in UI components.\n\n\u003cbr /\u003e\n\nWhen a property of a ui.data.ActiveDictionary (e.g. myButton.style()) is updated, the component it belongs to is automatically updated. For example, myButton.style().set('color', 'red') would change the color of button's text to red.\n\n| Usage | Returns |\n|----------------------------------------------------------------|--------------------------|\n| `ui.data.ActiveDictionary(`*object* `, `*allowedProperties*`)` | ui.data.ActiveDictionary |\n\n| Argument | Type | Details |\n|---------------------|--------------------------|---------------------------------------------------------------------------------------------|\n| `object` | Object, optional | A JavaScript object with properties and values to initialize this object with. |\n| `allowedProperties` | List\\\u003cString\\\u003e, optional | An array of allowed properties for this object. If undefined, then any property is allowed. |"]]