<कार्रवाई>
संग्रह की मदद से व्यवस्थित रहें
अपनी प्राथमिकताओं के आधार पर, कॉन्टेंट को सेव करें और कैटगरी में बांटें.
- सिंटैक्स:
<action android:name="string" />
- इसमें शामिल है:
<intent-filter>
- विवरण:
- इंटेंट फ़िल्टर में कार्रवाई जोड़ता है.
<intent-filter>
एलिमेंट में एक या उससे ज़्यादा <action>
एलिमेंट होने चाहिए. अगर वहां
इंटेंट फ़िल्टर में कोई <action>
एलिमेंट नहीं है, फ़िल्टर
किसी Intent
ऑब्जेक्ट को स्वीकार नहीं करता.
इंटेंट फ़िल्टर और कार्रवाई की भूमिका के बारे में जानकारी के लिए
फ़िल्टर में खास जानकारी देखने के लिए,
इंटेंट और
इंटेंट फ़िल्टर.
- विशेषताएं:
android:name
- कार्रवाई का नाम. कुछ स्टैंडर्ड कार्रवाइयां,
Intent
क्लास का नाम
ACTION_string
कॉन्सटेंट. इनमें से कोई एक कार्रवाई, इसे असाइन करने के लिए
इस एट्रिब्यूट की वैल्यू के तौर पर, android.intent.action.
को
ACTION_
के बाद आने वाली string
.
उदाहरण के लिए, ACTION_MAIN
के लिए android.intent.action.MAIN
का इस्तेमाल करें,
और ACTION_WEB_SEARCH
के लिए, android.intent.action.WEB_SEARCH
का इस्तेमाल करें.
आपकी तय की गई कार्रवाइयों के लिए, बेहतर होगा कि आप अपने ऐप्लिकेशन के पैकेज के नाम को प्रीफ़िक्स के तौर पर इस्तेमाल करें
यूनीक कॉन्टेंट दिखाने में मदद मिलती है. उदाहरण के लिए, TRANSMOGRIFY
कार्रवाई तय की जा सकती है
इस तरह से:
<action android:name="com.example.project.TRANSMOGRIFY" />
- इसमें पेश किया गया:
- एपीआई लेवल 1
- यह भी देखें:
<intent-filter>
इस पेज पर मौजूद कॉन्टेंट और कोड सैंपल कॉन्टेंट के लाइसेंस में बताए गए लाइसेंस के हिसाब से हैं. Java और OpenJDK, Oracle और/या इससे जुड़ी हुई कंपनियों के ट्रेडमार्क या रजिस्टर किए हुए ट्रेडमार्क हैं.
आखिरी बार 2025-07-27 (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"]],["आखिरी बार 2025-07-27 (UTC) को अपडेट किया गया."],[],[],null,["# <action\u003e\n\nsyntax:\n:\n\n ```xml\n \u003caction android:name=\"string\" /\u003e\n ```\n\ncontained in:\n: [\u003cintent-filter\u003e](/guide/topics/manifest/intent-filter-element)\n\ndescription:\n: Adds an action to an intent filter.\n An [\u003cintent-filter\u003e](/guide/topics/manifest/intent-filter-element)\n element must contain one or more `\u003caction\u003e` elements. If there\n are no `\u003caction\u003e` elements in an intent filter, the filter\n doesn't accept any [Intent](/reference/android/content/Intent) objects.\n For details about intent filters and the role of action\n specifications within a filter, see\n [Intents and\n Intent Filters](/guide/components/intents-filters).\n\nattributes:\n:\n\n `android:name`\n : The name of the action. Some standard actions are defined in the\n [Intent](/reference/android/content/Intent#ACTION_CHOOSER) class as\n `ACTION_`*string* constants. To assign one of these actions to\n this attribute, prepend `android.intent.action.` to the\n *string* that follows `ACTION_`.\n For example, for `ACTION_MAIN`, use `android.intent.action.MAIN`,\n and for `ACTION_WEB_SEARCH`, use `android.intent.action.WEB_SEARCH`.\n\n\n For actions you define, it's best to use your app's package name as a prefix to\n help ensure uniqueness. For example, a `TRANSMOGRIFY` action might be specified\n as follows:\n\n\n ```xml\n \u003caction android:name=\"com.example.project.TRANSMOGRIFY\" /\u003e\n ```\n\nintroduced in:\n: API Level 1\n\nsee also:\n: [\u003cintent-filter\u003e](/guide/topics/manifest/intent-filter-element)"]]