रिसर्च सर्वे: Blockly के साथ अपने अनुभव के बारे में हमें बताएं
सर्वे शुरू करें
संग्रह की मदद से व्यवस्थित रहें
अपनी प्राथमिकताओं के आधार पर, कॉन्टेंट को सेव करें और कैटगरी में बांटें.
ब्लॉकली > नाम
नाम की श्रेणी
इकाई के नामों (वैरिएबल, प्रोसेस वगैरह) के डेटाबेस के लिए क्लास.
हस्ताक्षर:
export declare class Names
कंस्ट्रक्टर
प्रॉपर्टी
तरीके
तरीका |
मॉडिफ़ायर |
ब्यौरा |
इसके बराबर है(name1, name2) |
static |
क्या दिए गए दो इकाई नाम एक ही इकाई से संबंधित हैं? ब्लॉक किए गए नाम, केस-इनसेंसिटिव होते हैं. |
getDistinctName(name, type) |
|
ब्लॉकली इकाई के नाम को, कानूनी तौर पर एक्सपोर्ट की जा सकने वाली इकाई के नाम में बदलें. पक्का करें कि यह नया नाम है, जो पहले से तय किसी नाम के साथ ओवरलैप नहीं कर रहा है. साथ ही, मौजूदा भाषा के लिए रिज़र्व किए गए शब्दों की सूची देखें और पक्का करें कि नाम एक-दूसरे से मैच न हो रहा हो. |
getName(nameOrId, type) |
|
ब्लॉकली इकाई के नाम को, कानूनी तौर पर एक्सपोर्ट की जा सकने वाली इकाई के नाम में बदलें. |
getUserNames(type) |
|
किसी खास तरह के नाम से जुड़े, उपयोगकर्ता के बनाए गए सभी नामों की सूची दिखाएं. |
populateProcedures(workspace) |
|
प्रक्रियाओं के लिए नाम जनरेट करें. |
populateVariables(workspace) |
|
उपयोगकर्ता वैरिएबल के लिए नाम जनरेट करें, लेकिन सिर्फ़ वही नाम जनरेट करें जिनका इस्तेमाल किया जा रहा हो. |
reset() |
|
डेटाबेस को खाली करें और नए सिरे से शुरुआत करें. रिज़र्व किए गए शब्द सेव रहते हैं. |
setVariableMap(map) |
|
वैरिएबल मैप से वैरिएबल नाम से वैरिएबल ऑब्जेक्ट पर मैप करने वाला वैरिएबल मैप सेट करें. |
जब तक कुछ अलग से न बताया जाए, तब तक इस पेज की सामग्री को Creative Commons Attribution 4.0 License के तहत और कोड के नमूनों को Apache 2.0 License के तहत लाइसेंस मिला है. ज़्यादा जानकारी के लिए, Google Developers साइट नीतियां देखें. Oracle और/या इससे जुड़ी हुई कंपनियों का, Java एक रजिस्टर किया हुआ ट्रेडमार्क है.
आखिरी बार 2024-09-09 (UTC) को अपडेट किया गया.
[[["समझने में आसान है","easyToUnderstand","thumb-up"],["मेरी समस्या हल हो गई","solvedMyProblem","thumb-up"],["अन्य","otherUp","thumb-up"]],[["वह जानकारी मौजूद नहीं है जो मुझे चाहिए","missingTheInformationINeed","thumb-down"],["बहुत मुश्किल है / बहुत सारे चरण हैं","tooComplicatedTooManySteps","thumb-down"],["पुराना","outOfDate","thumb-down"],["अनुवाद से जुड़ी समस्या","translationIssue","thumb-down"],["सैंपल / कोड से जुड़ी समस्या","samplesCodeIssue","thumb-down"],["अन्य","otherDown","thumb-down"]],["आखिरी बार 2024-09-09 (UTC) को अपडेट किया गया."],[[["The `Names` class manages a database of entity names in Blockly, such as variables and procedures, ensuring they are unique and do not conflict with reserved words."],["It provides methods for generating, converting, and comparing names, and for populating the database with names from the workspace."],["This class helps maintain consistency and avoid naming conflicts when working with Blockly entities."],["The `Names` class also stores a map of variables and their corresponding objects."]]],["The `Names` class manages a database of entity names, including variables and procedures. Key actions include constructing a new `Names` instance, checking name equality, and generating distinct, legal names. Methods allow retrieving user-created names, generating names for procedures and variables, and resetting the database. The class also manages a variable map, and can populate procedures and variables within a workspace. It handles reserved words and prevents name collisions.\n"]]