हमारा सुझाव है कि 27 मार्च, 2025 से AOSP को बनाने और उसमें योगदान देने के लिए, aosp-main
के बजाय android-latest-release
का इस्तेमाल करें. ज़्यादा जानकारी के लिए, AOSP में हुए बदलाव लेख पढ़ें.
Tradefed कॉन्फ़िगरेशन ऑब्जेक्ट
संग्रह की मदद से व्यवस्थित रहें
अपनी प्राथमिकताओं के आधार पर, कॉन्टेंट को सेव करें और कैटगरी में बांटें.
Tradefed एक्सएमएल कॉन्फ़िगरेशन को पार्स किया जाता है और इससे एक Configuration
ऑब्जेक्ट बनाया जाता है, जिसमें पूरे कॉन्फ़िगरेशन के बारे में जानकारी होती है.
ऑब्जेक्ट के बारे में जानकारी, IConfiguration इंटरफ़ेस से मिलती है.इसमें एक्सएमएल में बताए गए सभी ऑब्जेक्ट का एक इंस्टेंस होगा.
इस उदाहरण में:
<configuration description="<description of the configuration>">
<!-- A build provider that takes local device information -->
<build_provider class="com.android.tradefed.build.BootstrapBuildProvider" />
<!-- Some target preparation, disabled by default -->
<target_preparer class="com.android.tradefed.targetprep.PreloadedClassesPreparer">
<option name="disable" value="true" />
</target_preparer>
<!-- One test running some unit tests -->
<test class="com.android.tradefed.testtype.HostTest">
<option name="class" value="com.android.tradefed.build.BuildInfoTest" />
</test>
</configuration>
इससे ये चीज़ें होंगी:
IConfiguration#getBuildProvider()
का इस्तेमाल करके BootstrapBuildProvider
का उदाहरण पाएं.
IConfiguration#getTargetPreparers()
का इस्तेमाल करके, ITargetPreparer
की सूची पाएं. इसमें PreloadedClassesPreparer
का एक इंस्टेंस शामिल होगा.
IConfiguration#getTests()
, IRemoteTest
की सूची दिखाता है, जिसमें HostTest
का एक उदाहरण शामिल है.
कॉन्फ़िगरेशन ऑब्जेक्ट में मौजूद हर ऑब्जेक्ट को एक्सएमएल परिभाषा से मैप किया जा सकता है. इसलिए, एक्सएमएल परिभाषा को समझने से, आम तौर पर यह समझने में मदद मिलती है कि कॉन्फ़िगरेशन ऑब्जेक्ट से क्या उम्मीद की जा सकती है.
इस पेज पर मौजूद कॉन्टेंट और कोड सैंपल कॉन्टेंट के लाइसेंस में बताए गए लाइसेंस के हिसाब से हैं. 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,["# Tradefed configuration object\n\n[Tradefed XML configuration](/docs/core/tests/tradefed/architecture/xml-config)\nis parsed, and a `Configuration` object is created from it that describes the\ncomplete configuration.\n\nThe object is described by the\n[IConfiguration interface.](https://android.googlesource.com/platform/tools/tradefederation/+/refs/heads/android16-release/src/com/android/tradefed/config/IConfiguration.java)\nit will contain an instance of all the objects defined in the XML.\n\nThis example: \n\n \u003cconfiguration description=\"\u003cdescription of the configuration\u003e\"\u003e\n \u003c!-- A build provider that takes local device information --\u003e\n \u003cbuild_provider class=\"com.android.tradefed.build.BootstrapBuildProvider\" /\u003e\n\n \u003c!-- Some target preparation, disabled by default --\u003e\n \u003ctarget_preparer class=\"com.android.tradefed.targetprep.PreloadedClassesPreparer\"\u003e\n \u003coption name=\"disable\" value=\"true\" /\u003e\n \u003c/target_preparer\u003e\n\n \u003c!-- One test running some unit tests --\u003e\n \u003ctest class=\"com.android.tradefed.testtype.HostTest\"\u003e\n \u003coption name=\"class\" value=\"com.android.tradefed.build.BuildInfoTest\" /\u003e\n \u003c/test\u003e\n \u003c/configuration\u003e\n\nWill result in:\n\n- `IConfiguration#getBuildProvider()` to return a `BootstrapBuildProvider` instance.\n- `IConfiguration#getTargetPreparers()` to return a list of `ITargetPreparer` containing an instance of `PreloadedClassesPreparer`.\n- `IConfiguration#getTests()` to return a list of `IRemoteTest` containing an instance of `HostTest`.\n\nEvery single object in the configuration object can be mapped to the XML\ndefinition, so understanding the XML definition usually helps to understand\nwhat to expect from the configuration object."]]