Home
last modified time | relevance | path

Searched refs:ResourceEntry (Results 1 – 25 of 33) sorted by relevance

12

/frameworks/opt/car/setupwizard/library/main/tests/robotests/src/com/android/car/setupwizardlib/partner/
DResourceEntryTest.java35 ResourceEntry resourceEntry = in toBundle_getBundleWithCorrectData()
36 new ResourceEntry( in toBundle_getBundleWithCorrectData()
42 assertThat(result.getString(ResourceEntry.KEY_PACKAGE_NAME)).isEqualTo(TEST_PACKAGE_NAME); in toBundle_getBundleWithCorrectData()
43 assertThat(result.getString(ResourceEntry.KEY_RESOURCE_NAME)) in toBundle_getBundleWithCorrectData()
45 assertThat(result.getInt(ResourceEntry.KEY_RESOURCE_ID)).isEqualTo(TEST_RESOURCE_ID); in toBundle_getBundleWithCorrectData()
51 source.putString(ResourceEntry.KEY_PACKAGE_NAME, TEST_PACKAGE_NAME); in fromBundle_bundleWithRequiredData_getResourceEntryWithCorrectData()
53 ResourceEntry.KEY_RESOURCE_NAME, PartnerConfigKey.KEY_TOOLBAR_BG_COLOR); in fromBundle_bundleWithRequiredData_getResourceEntryWithCorrectData()
54 source.putInt(ResourceEntry.KEY_RESOURCE_ID, TEST_RESOURCE_ID); in fromBundle_bundleWithRequiredData_getResourceEntryWithCorrectData()
56 ResourceEntry result = ResourceEntry.fromBundle(source); in fromBundle_bundleWithRequiredData_getResourceEntryWithCorrectData()
65 assertThat(ResourceEntry.fromBundle(null)).isNull(); in fromNullBundle_returnNull()
[all …]
DPartnerConfigHelperTest.java56 private List<ResourceEntry> mResourceEntries;
63 for (ResourceEntry entry : mResourceEntries) { in setUp()
113 private List<ResourceEntry> prepareFakeData() { in prepareFakeData()
130 new ResourceEntry( in prepareFakeData()
137 new ResourceEntry( in prepareFakeData()
144 new ResourceEntry( in prepareFakeData()
151 new ResourceEntry( in prepareFakeData()
DFakeOverrideContentProvider.java50 public FakeOverrideContentProvider injectResourceEntry(ResourceEntry resourceEntry) { in injectResourceEntry()
72 contentProvider.injectResourceEntry(new ResourceEntry( in installDefaultProvider()
85 contentProvider.injectResourceEntry(new ResourceEntry( in installDefaultProvider()
98 contentProvider.injectResourceEntry(new ResourceEntry( in installDefaultProvider()
111 contentProvider.injectResourceEntry(new ResourceEntry( in installDefaultProvider()
124 contentProvider.injectResourceEntry(new ResourceEntry( in installDefaultProvider()
/frameworks/opt/setupwizard/library/main/src/com/android/setupwizardlib/util/
DPartner.java64 final ResourceEntry entry = getResourceEntry(context, id); in getDrawable()
74 final ResourceEntry entry = getResourceEntry(context, id); in getString()
82 final ResourceEntry resourceEntry = getResourceEntry(context, id); in getColor()
91 final ResourceEntry entry = getResourceEntry(context, id); in getText()
105 public static ResourceEntry getResourceEntry(Context context, @AnyRes int id) { in getResourceEntry()
113 return new ResourceEntry(partner.resources, partnerId, true); in getResourceEntry()
116 return new ResourceEntry(context.getResources(), id, false); in getResourceEntry()
119 public static class ResourceEntry { class in Partner
124 ResourceEntry(Resources resources, int id, boolean isOverlay) { in ResourceEntry() method in Partner.ResourceEntry
/frameworks/opt/car/setupwizard/library/main/src/com/android/car/setupwizardlib/partner/
DResourceEntry.java30 public final class ResourceEntry { class
44 public static ResourceEntry fromBundle(@Nullable Bundle bundle) { in fromBundle()
55 return new ResourceEntry(packageName, resourceName, resourceId); in fromBundle()
58 public ResourceEntry(String packageName, String resourceName, int resourceId) { in ResourceEntry() method in ResourceEntry
DPartnerConfigHelper.java87 ResourceEntry resourceEntry = getResourceEntryFromKey(resourceName); in getColor()
123 ResourceEntry resourceEntry = getResourceEntryFromKey(resourceName); in getDrawable()
166 ResourceEntry resourceEntry = getResourceEntryFromKey(resourceName); in getString()
212 ResourceEntry resourceEntry = getResourceEntryFromKey(resourceName); in getDimension()
248 ResourceEntry resourceEntry = getResourceEntryFromKey(resourceName); in getBoolean()
289 private ResourceEntry getResourceEntryFromKey(String resourceName) { in getResourceEntryFromKey()
293 return ResourceEntry.fromBundle(mResultBundle.getBundle(resourceName)); in getResourceEntryFromKey()
/frameworks/base/tools/aapt2/
DResourceTable.cpp149 ResourceEntry* ResourceTableType::FindEntry(const StringPiece& name, const Maybe<uint16_t> id) { in FindEntry()
152 less_than_struct_with_name_and_id<ResourceEntry>); in FindEntry()
159 ResourceEntry* ResourceTableType::FindOrCreateEntry(const StringPiece& name, in FindOrCreateEntry()
163 less_than_struct_with_name_and_id<ResourceEntry>); in FindOrCreateEntry()
168 auto new_entry = new ResourceEntry(name); in FindOrCreateEntry()
173 ResourceConfigValue* ResourceEntry::FindValue(const ConfigDescription& config) { in FindValue()
190 ResourceConfigValue* ResourceEntry::FindValue(const ConfigDescription& config, in FindValue()
203 ResourceConfigValue* ResourceEntry::FindOrCreateValue(const ConfigDescription& config, in FindOrCreateValue()
218 std::vector<ResourceConfigValue*> ResourceEntry::FindAllValues(const ConfigDescription& config) { in FindAllValues()
240 bool ResourceEntry::HasDefaultValue() const { in HasDefaultValue()
[all …]
DResourceTable.h131 class ResourceEntry {
151 explicit ResourceEntry(const android::StringPiece& name) : name(name.to_string()) {} in ResourceEntry() function
176 DISALLOW_COPY_AND_ASSIGN(ResourceEntry);
192 std::vector<std::unique_ptr<ResourceEntry>> entries;
196 ResourceEntry* FindEntry(const android::StringPiece& name,
198 ResourceEntry* FindOrCreateEntry(const android::StringPiece& name,
277 ResourceEntry* entry;
DDebug.cpp275 std::vector<const ResourceEntry*> sorted_entries; in PrintTable()
279 [](const ResourceEntry* a, const ResourceEntry* b) -> bool { in PrintTable()
292 for (const ResourceEntry* entry : sorted_entries) { in PrintTable()
366 ResourceEntry* entry = result.value().entry; in PrintStyleGraph()
/frameworks/base/tools/aapt2/link/
DLinkers.h35 class ResourceEntry; variable
46 bool ShouldGenerateVersionedResource(const ResourceEntry* entry,
52 ApiVersion FindNextApiVersionForConfig(const ResourceEntry* entry,
DPrivateAttributeMover.cpp71 std::vector<std::unique_ptr<ResourceEntry>> private_attr_entries; in Consume()
74 [](const std::unique_ptr<ResourceEntry>& entry) -> bool { in Consume()
DNoDefaultResourceRemover.cpp29 static bool KeepResource(const std::unique_ptr<ResourceEntry>& entry, int minSdk) { in KeepResource()
74 [&minSdk](const std::unique_ptr<ResourceEntry>& entry) -> bool { in Consume()
DAutoVersioner.cpp32 bool ShouldGenerateVersionedResource(const ResourceEntry* entry, in ShouldGenerateVersionedResource()
40 ApiVersion FindNextApiVersionForConfig(const ResourceEntry* entry, in FindNextApiVersionForConfig()
DAutoVersioner_test.cpp32 ResourceEntry entry("foo"); in TEST()
45 ResourceEntry entry("foo"); in TEST()
DResourceExcluder.cpp33 ResourceEntry* entry, in RemoveIfExcluded()
DTableMerger.cpp107 ResourceEntry* dst_entry, ResourceEntry* src_entry, in MergeEntry()
241 ResourceEntry* dst_entry; in DoMerge()
/frameworks/base/tools/aapt2/optimize/
DResourceDeduper.cpp46 explicit DominatedKeyValueRemover(IAaptContext* context, ResourceEntry* entry) in DominatedKeyValueRemover()
93 ResourceEntry* entry_;
96 static void DedupeEntry(IAaptContext* context, ResourceEntry* entry) { in DedupeEntry()
DVersionCollapser.cpp73 static void CollapseVersions(int min_sdk, ResourceEntry* entry) { in CollapseVersions()
/frameworks/base/tools/aapt2/cmd/
DDiff.cpp94 ResourceEntry* entry_a, ResourceConfigValue* config_value_a, in EmitResourceConfigValueDiff()
96 ResourceTableType* type_b, ResourceEntry* entry_b, in EmitResourceConfigValueDiff()
115 ResourceEntry* entry_a, LoadedApk* apk_b, in EmitResourceEntryDiff()
117 ResourceEntry* entry_b) { in EmitResourceEntryDiff()
153 for (std::unique_ptr<ResourceEntry>& entry_a : type_a->entries) { in EmitResourceTypeDiff()
154 ResourceEntry* entry_b = type_b->FindEntry(entry_a->name); in EmitResourceTypeDiff()
205 for (std::unique_ptr<ResourceEntry>& entry_b : type_b->entries) { in EmitResourceTypeDiff()
206 ResourceEntry* entry_a = type_a->FindEntry(entry_b->name); in EmitResourceTypeDiff()
/frameworks/opt/setupwizard/library/test/robotest/src/com/android/setupwizardlib/util/
DPartnerTest.java32 import com.android.setupwizardlib.util.Partner.ResourceEntry;
93 ResourceEntry entry = Partner.getResourceEntry(application, R.integer.suwTransitionDuration); in getResourceEntry_hasOverlay_shouldReturnOverlayValue()
123 ResourceEntry entry = Partner.getResourceEntry(application, R.color.suw_color_accent_dark); in getResourceEntry_partnerValueNotPresent_shouldReturnDefault()
133 ResourceEntry entry = Partner.getResourceEntry(application, R.color.suw_color_accent_dark); in getResourceEntry_directBootUnawareNoValueDefined_shouldReturnDefaultValue()
/frameworks/base/tools/aapt2/java/
DJavaClassGenerator.h92 const ResourceEntry& entry);
102 const ResourceEntry& entry, ClassDefinition* out_class_def,
DJavaClassGenerator.cpp439 const ResourceEntry& entry, ClassDefinition* out_class_def, in ProcessResource()
498 const ResourceEntry& entry) { in UnmangleResource()
/frameworks/opt/car/setupwizard/library/main/tests/robotests/src/com/android/car/setupwizardlib/
DCarSetupWizardCompatLayoutTest.java37 import com.android.car.setupwizardlib.partner.ResourceEntry;
79 List<ResourceEntry> resourceEntries = prepareFakeData(); in setUp()
80 for (ResourceEntry entry : resourceEntries) { in setUp()
554 private List<ResourceEntry> prepareFakeData() { in prepareFakeData()
562 new ResourceEntry( in prepareFakeData()
/frameworks/base/tools/aapt2/format/binary/
DTableFlattener.cpp75 ResourceEntry* entry;
418 std::vector<ResourceEntry*> CollectAndSortEntries(ResourceTableType* type) { in CollectAndSortEntries()
420 std::vector<ResourceEntry*> sorted_entries; in CollectAndSortEntries()
425 std::sort(sorted_entries.begin(), sorted_entries.end(), cmp_ids<ResourceEntry>); in CollectAndSortEntries()
566 bool FlattenTypeSpec(ResourceTableType* type, std::vector<ResourceEntry*>* sorted_entries, in FlattenTypeSpec()
591 ResourceEntry* entry = sorted_entries->at(entryIndex); in FlattenTypeSpec()
630 std::vector<ResourceEntry*> sorted_entries = CollectAndSortEntries(type); in FlattenTypes()
653 for (ResourceEntry* entry : sorted_entries) { in FlattenTypes()
/frameworks/base/tools/aapt2/compile/
DIdAssigner.cpp36 ResourceTableType* type, ResourceEntry* entry) { in AssignId()

12