Home
last modified time | relevance | path

Searched refs:ResourceUtils (Results 1 – 25 of 32) sorted by relevance

12

/frameworks/base/tools/aapt2/
DResourceUtils_test.cpp33 EXPECT_THAT(ResourceUtils::ParseBool("true"), Eq(Maybe<bool>(true))); in TEST()
34 EXPECT_THAT(ResourceUtils::ParseBool("TRUE"), Eq(Maybe<bool>(true))); in TEST()
35 EXPECT_THAT(ResourceUtils::ParseBool("True"), Eq(Maybe<bool>(true))); in TEST()
37 EXPECT_THAT(ResourceUtils::ParseBool("false"), Eq(Maybe<bool>(false))); in TEST()
38 EXPECT_THAT(ResourceUtils::ParseBool("FALSE"), Eq(Maybe<bool>(false))); in TEST()
39 EXPECT_THAT(ResourceUtils::ParseBool("False"), Eq(Maybe<bool>(false))); in TEST()
41 EXPECT_THAT(ResourceUtils::ParseBool(" False\n "), Eq(Maybe<bool>(false))); in TEST()
47 EXPECT_TRUE(ResourceUtils::ParseResourceName("android:color/foo", &actual, &actual_priv)); in TEST()
51 EXPECT_TRUE(ResourceUtils::ParseResourceName("color/foo", &actual, &actual_priv)); in TEST()
55 EXPECT_TRUE(ResourceUtils::ParseResourceName("*android:color/foo", &actual, &actual_priv)); in TEST()
[all …]
DResourceValues_test.cpp109 .AddItem("android:attr/foo", ResourceUtils::TryParseInt("1")) in TEST()
110 .AddItem("android:attr/bar", ResourceUtils::TryParseInt("2")) in TEST()
115 .AddItem("android:attr/foo", ResourceUtils::TryParseInt("1")) in TEST()
116 .AddItem("android:attr/bar", ResourceUtils::TryParseInt("3")) in TEST()
121 .AddItem("android:attr/foo", ResourceUtils::TryParseInt("1")) in TEST()
122 .AddItem("android:attr/bar", ResourceUtils::TryParseInt("2")) in TEST()
126 .AddItem("android:attr/foo", ResourceUtils::TryParseInt("1")) in TEST()
127 .AddItem("android:attr/bar", ResourceUtils::TryParseInt("2")) in TEST()
132 .AddItem("android:attr/foo", ResourceUtils::TryParseInt("1")) in TEST()
133 .AddItem("android:attr/bat", ResourceUtils::TryParseInt("2")) in TEST()
[all …]
DResourceParser.cpp35 using ::aapt::ResourceUtils::StringBuilder;
375 ResourceUtils::FlattenedXmlString flattened_string = builder.GetFlattenedString(); in FlattenXmlSubtree()
755 ResourceUtils::TryParseItemForAttribute(raw_value, type_mask, on_create_reference); in ParseXml()
775 return ResourceUtils::MakeNull(); in ParseXml()
793 ResourceUtils::ParseBool(formatted_attr.value()); in ParseString()
804 Maybe<bool> maybe_translatable = ResourceUtils::ParseBool(translatable_attr.value()); in ParseString()
873 Maybe<ResourceId> maybe_id = ResourceUtils::ParseResourceId(maybe_id_str.value()); in ParsePublic()
928 ResourceUtils::ParseResourceId(maybe_id_str.value()); in ParsePublicGroup()
1406 Maybe<Reference> maybe_key = ResourceUtils::ParseXmlAttributeName(maybe_name.value()); in ParseStyleItem()
1436 style->parent = ResourceUtils::ParseStyleParentReference(maybe_parent.value(), &err_str); in ParseStyle()
[all …]
DResourceUtils.h34 namespace ResourceUtils {
DAndroid.bp143 "ResourceUtils.cpp",
/frameworks/base/tools/aapt2/format/proto/
DProtoSerialize_test.cpp198 ResourceUtils::TryParseItemForAttribute(attr.value, android::ResTable_map::TYPE_DIMENSION); in TEST()
314 .AddValue("android:color/color_rgb8", ResourceUtils::TryParseColor("#AABBCC")) in TEST()
315 .AddValue("android:color/color_argb8", ResourceUtils::TryParseColor("#11223344")) in TEST()
316 .AddValue("android:color/color_rgb4", ResourceUtils::TryParseColor("#DEF")) in TEST()
317 .AddValue("android:color/color_argb4", ResourceUtils::TryParseColor("#5678")) in TEST()
318 .AddValue("android:integer/integer_444", ResourceUtils::TryParseInt("444")) in TEST()
319 .AddValue("android:integer/integer_neg_333", ResourceUtils::TryParseInt("-333")) in TEST()
320 .AddValue("android:integer/hex_int_abcd", ResourceUtils::TryParseInt("0xABCD")) in TEST()
321 .AddValue("android:dimen/dimen_1.39mm", ResourceUtils::TryParseFloat("1.39mm")) in TEST()
322 .AddValue("android:fraction/fraction_27", ResourceUtils::TryParseFloat("27%")) in TEST()
[all …]
DProtoDeserialize.cpp584 if (!ResourceUtils::ParseResourceName(pb_file.resource_name(), &name_ref)) { in DeserializeCompiledFileFromPb()
604 if (!ResourceUtils::ParseResourceName(pb_symbol.resource_name(), &name_ref)) { in DeserializeCompiledFileFromPb()
644 if (!ResourceUtils::ParseResourceName(pb_ref.name(), &name_ref, nullptr)) { in DeserializeReferenceFromPb()
/frameworks/base/tools/aapt2/link/
DTableMerger_test.cpp160 .AddValue("bool/foo", ResourceUtils::TryParseBool("true")) in TEST_F()
165 .AddValue("bool/foo", ResourceUtils::TryParseBool("false")) in TEST_F()
182 std::unique_ptr<Value> foo_original = ResourceUtils::TryParseBool("true"); in TEST_F()
184 std::unique_ptr<Value> bar_original = ResourceUtils::TryParseBool("true"); in TEST_F()
186 std::unique_ptr<Value> foo_overlay = ResourceUtils::TryParseBool("false"); in TEST_F()
188 std::unique_ptr<Value> bar_overlay = ResourceUtils::TryParseBool("false"); in TEST_F()
190 std::unique_ptr<Value> baz_overlay = ResourceUtils::TryParseBool("false"); in TEST_F()
325 .AddValue("bool/foo", ResourceUtils::TryParseBool("true")) in TEST_F()
343 .AddValue("bool/foo", ResourceUtils::TryParseBool("true")) in TEST_F()
417 .AddValue("bool/foo", ResourceUtils::TryParseBool("true")) in TEST_F()
[all …]
DReferenceLinker_test.cpp83 ResourceUtils::TryParseColor("#ff00ff")) in TEST()
162 ResourceUtils::TryParseColor("#ff0000")) in TEST()
236 ResourceUtils::TryParseColor("#ff00ff")) in TEST()
DManifestFixer.cpp128 if (!ResourceUtils::ParseBool(attr->value).value_or_default(false)) { in AutoGenerateIsFeatureSplit()
151 } else if (ResourceUtils::IsReference(attr->value)) { in VerifyManifest()
177 std::unique_ptr<BinaryPrimitive> result = ResourceUtils::TryParseBool(attr->value); in FixCoreAppAttribute()
DReferenceLinker.cpp34 using ::aapt::ResourceUtils::StringBuilder;
134 ResourceUtils::TryParseItemForAttribute(*raw_string->value, attr); in ParseValueWithAttribute()
DXmlReferenceLinker.cpp117 attr.compiled_value = ResourceUtils::TryParseItemForAttribute(attr.value, attribute); in Visit()
DTableMerger.cpp334 std::string path = ResourceUtils::BuildResourceFileName(file_desc); in MergeFile()
/frameworks/base/tools/aapt2/cmd/
DUtil.cpp286 Maybe<uint32_t> integer = ResourceUtils::ParseInt(attr.value); in ExtractCompiledInt()
310 Maybe<int> sdk_version = ResourceUtils::ParseSdkVersion(*compiled_str->value); in ExtractSdkVersion()
323 Maybe<int> sdk_version = ResourceUtils::ParseSdkVersion(attr.value); in ExtractSdkVersion()
425 version_code->compiled_value = ResourceUtils::TryParseInt(version_code->value); in SetLongVersionCode()
432 version_major->compiled_value = ResourceUtils::TryParseInt(version_major->value); in SetLongVersionCode()
DLink.cpp625 dst_path = ResourceUtils::BuildResourceFileName(file, context_->GetNameMangler()); in Flatten()
703 if (!ResourceUtils::ParseResourceName(res_name_str, &name)) { in LoadStableIdMap()
713 Maybe<ResourceId> maybe_id = ResourceUtils::ParseResourceId(res_id_str); in LoadStableIdMap()
924 Maybe<uint32_t> maybe_code = ResourceUtils::ParseInt(version_code_attr->value); in ExtractAppInfoFromManifest()
935 Maybe<uint32_t> maybe_code = ResourceUtils::ParseInt(version_code_major_attr->value); in ExtractAppInfoFromManifest()
947 Maybe<uint32_t> maybe_code = ResourceUtils::ParseInt(revision_code_attr->value); in ExtractAppInfoFromManifest()
965 app_info.min_sdk_version = ResourceUtils::ParseSdkVersion(min_sdk->value); in ExtractAppInfoFromManifest()
2138 const Maybe<uint32_t> maybe_package_id_int = ResourceUtils::ParseInt(package_id_.value()); in Action()
/frameworks/base/tools/aapt2/optimize/
DMultiApkGenerator.cpp320 min_sdk_attr->compiled_value = ResourceUtils::TryParseInt(min_sdk_str); in UpdateManifest()
383 size->compiled_value = ResourceUtils::MakeInt(screen_size); in AddScreens()
387 density->compiled_value = ResourceUtils::MakeInt(config.density); in AddScreens()
/frameworks/base/tools/aapt2/compile/
DXmlIdCollector.cpp48 if (ResourceUtils::ParseReference(attr.value, &name, &create, nullptr)) { in Visit()
DInlineXmlFormatParser.cpp59 Maybe<Reference> ref = ResourceUtils::ParseXmlAttributeName(attr->value); in Visit()
/frameworks/base/tools/aapt2/process/
DSymbolTable.cpp307 Maybe<ResourceName> parsed_name = ResourceUtils::ToResourceName(name); in LookupAttributeInTable()
376 return ResourceUtils::ToResourceName(name); in GetResourceName()
/frameworks/base/tools/aapt2/configuration/
DConfigurationParser.cpp727 Maybe<int> version = ResourceUtils::ParseSdkVersion(attr.value); in AndroidSdkTagHandler()
733 Maybe<int> version = ResourceUtils::ParseSdkVersion(attr.value); in AndroidSdkTagHandler()
739 Maybe<int> version = ResourceUtils::ParseSdkVersion(attr.value); in AndroidSdkTagHandler()
/frameworks/base/cmds/idmap2/
DAndroid.bp53 "libidmap2/ResourceUtils.cpp",
/frameworks/base/libs/androidfw/
DAndroid.bp55 "ResourceUtils.cpp",
/frameworks/base/tools/aapt2/test/
DCommon.h44 CHECK(ResourceUtils::ParseResourceName(str, &ref)) << "invalid resource name: " << str; in ParseNameOrDie()
/frameworks/base/tools/aapt2/format/binary/
DXmlFlattener_test.cpp501 doc->root->attributes[0].compiled_value = ResourceUtils::MakeBool(true); in TEST_F()
521 doc->root->attributes[0].compiled_value = ResourceUtils::MakeBool(true); in TEST_F()
DXmlFlattener.cpp37 using ::aapt::ResourceUtils::StringBuilder;

12