HomeSort by relevance Sort by last modified time
    Searched refs:BinaryPrimitive (Results 1 - 22 of 22) sorted by null

  /frameworks/base/tools/aapt2/
ResourceUtils.h 143 // Returns a BinaryPrimitive representing @empty. This is encoded as a Res_value with
145 std::unique_ptr<BinaryPrimitive> MakeEmpty();
151 std::unique_ptr<BinaryPrimitive> TryParseColor(const android::StringPiece& str);
157 std::unique_ptr<BinaryPrimitive> TryParseBool(const android::StringPiece& str);
159 // Returns a boolean BinaryPrimitive.
160 std::unique_ptr<BinaryPrimitive> MakeBool(bool val);
166 std::unique_ptr<BinaryPrimitive> TryParseInt(const android::StringPiece& str);
172 std::unique_ptr<BinaryPrimitive> TryParseFloat(const android::StringPiece& str);
178 std::unique_ptr<BinaryPrimitive> TryParseEnumSymbol(const Attribute* enum_attr,
185 std::unique_ptr<BinaryPrimitive> TryParseFlagSymbol(const Attribute* enum_attr
    [all...]
ResourceValues_test.cpp 230 EXPECT_TRUE(attr2.Matches(BinaryPrimitive(TYPE_INT_DEC, static_cast<uint32_t>(-1))));
231 EXPECT_TRUE(attr2.Matches(BinaryPrimitive(TYPE_INT_DEC, 1u)));
232 EXPECT_FALSE(attr2.Matches(BinaryPrimitive(TYPE_INT_DEC, static_cast<uint32_t>(-2))));
245 EXPECT_TRUE(attr3.Matches(BinaryPrimitive(TYPE_INT_DEC, 0x01u | 0x02u)));
246 EXPECT_TRUE(attr3.Matches(BinaryPrimitive(TYPE_INT_DEC, 0x01u | 0x02u | 0x80u)));
249 EXPECT_TRUE(attr3.Matches(BinaryPrimitive(TYPE_INT_DEC, 0x08u)));
252 EXPECT_FALSE(attr3.Matches(BinaryPrimitive(TYPE_INT_DEC, 127u)));
257 EXPECT_TRUE(attr4.Matches(BinaryPrimitive(TYPE_INT_DEC, 0x01u)));
258 EXPECT_FALSE(attr4.Matches(BinaryPrimitive(TYPE_INT_DEC, 0x02u)));
ResourceUtils.cpp 324 std::unique_ptr<BinaryPrimitive> MakeEmpty() {
325 return util::make_unique<BinaryPrimitive>(android::Res_value::TYPE_NULL,
329 std::unique_ptr<BinaryPrimitive> TryParseEnumSymbol(const Attribute* enum_attr,
340 return util::make_unique<BinaryPrimitive>(value);
346 std::unique_ptr<BinaryPrimitive> TryParseFlagSymbol(const Attribute* flag_attr,
354 return util::make_unique<BinaryPrimitive>(flags);
377 return util::make_unique<BinaryPrimitive>(flags);
393 std::unique_ptr<BinaryPrimitive> TryParseColor(const StringPiece& str) {
444 return error ? std::unique_ptr<BinaryPrimitive>()
445 : util::make_unique<BinaryPrimitive>(value)
    [all...]
ResourceUtils_test.cpp 189 std::unique_ptr<BinaryPrimitive> result = ResourceUtils::TryParseFlagSymbol(attr.get(), "");
200 ASSERT_THAT(ResourceUtils::MakeEmpty(), Pointee(ValueEq(BinaryPrimitive(Res_value::TYPE_NULL, Res_value::DATA_NULL_EMPTY))));
201 ASSERT_THAT(ResourceUtils::TryParseNullOrEmpty("@empty"), Pointee(ValueEq(BinaryPrimitive(Res_value::TYPE_NULL, Res_value::DATA_NULL_EMPTY))));
206 Pointee(ValueEq(BinaryPrimitive(Res_value::TYPE_INT_DEC, 12u))));
208 Pointee(ValueEq(BinaryPrimitive(Res_value::TYPE_INT_BOOLEAN, 0xffffffffu))));
213 Pointee(ValueEq(BinaryPrimitive(Res_value::TYPE_FLOAT, expected_float_flattened))));
ResourceValues.h 234 struct BinaryPrimitive : public BaseItem<BinaryPrimitive> {
237 BinaryPrimitive() = default;
238 explicit BinaryPrimitive(const android::Res_value& val);
239 BinaryPrimitive(uint8_t dataType, uint32_t data);
243 BinaryPrimitive* Clone(StringPool* new_pool) const override;
ResourceTable_test.cpp 88 test::ValueBuilder<BinaryPrimitive>(android::Res_value{})
96 EXPECT_THAT(test::GetValueForConfig<BinaryPrimitive>(&table, "android:string/ok", language_config), NotNull());
ResourceValues.cpp 294 BinaryPrimitive::BinaryPrimitive(const android::Res_value& val) : value(val) {}
296 BinaryPrimitive::BinaryPrimitive(uint8_t dataType, uint32_t data) {
301 bool BinaryPrimitive::Equals(const Value* value) const {
302 const BinaryPrimitive* other = ValueCast<BinaryPrimitive>(value);
310 bool BinaryPrimitive::Flatten(android::Res_value* out_value) const {
316 BinaryPrimitive* BinaryPrimitive::Clone(StringPool* /*new_pool*/) const
    [all...]
ResourceParser_test.cpp 230 BinaryPrimitive* integer = test::GetValue<BinaryPrimitive>(&table_, "integer/foo");
367 std::unique_ptr<BinaryPrimitive> flag_value =
547 EXPECT_THAT(ValueCast<BinaryPrimitive>(array->elements[2].get()), NotNull());
741 BinaryPrimitive* val = test::GetValue<BinaryPrimitive>(&table_, "integer/foo");
752 BinaryPrimitive* val = test::GetValue<BinaryPrimitive>(&table_, "integer/foo");
ValueVisitor.h 40 virtual void Visit(BinaryPrimitive* value) { VisitItem(value); }
  /frameworks/base/tools/aapt2/cmd/
Util.cpp 169 util::make_unique<BinaryPrimitive>(android::Res_value::TYPE_INT_DEC, version_code)});
177 util::make_unique<BinaryPrimitive>(android::Res_value::TYPE_INT_DEC, revision_code)});
208 util::make_unique<BinaryPrimitive>(android::Res_value::TYPE_INT_BOOLEAN, 0u)});
242 BinaryPrimitive* compiled_prim = ValueCast<BinaryPrimitive>(attr->compiled_value.get());
266 BinaryPrimitive* compiled_prim = ValueCast<BinaryPrimitive>(attr->compiled_value.get());
  /frameworks/base/tools/aapt2/flatten/
TableFlattener_test.cpp 158 util::make_unique<BinaryPrimitive>(
162 util::make_unique<BinaryPrimitive>(
263 util::make_unique<BinaryPrimitive>(Res_value::TYPE_INT_DEC, static_cast<uint32_t>(i));
306 auto value = test::GetValueForConfig<BinaryPrimitive>(&sparse_table, "android:string/foo_0",
311 ASSERT_THAT(test::GetValueForConfig<BinaryPrimitive>(&sparse_table, "android:string/foo_1", sparse_config), IsNull());
313 value = test::GetValueForConfig<BinaryPrimitive>(&sparse_table, "android:string/foo_4", sparse_config);
TableFlattener.cpp 89 BinaryPrimitive val(Res_value::TYPE_INT_DEC, attr->type_mask);
95 BinaryPrimitive val(Res_value::TYPE_INT_DEC,
102 BinaryPrimitive val(Res_value::TYPE_INT_DEC,
108 BinaryPrimitive val(Res_value::TYPE_INT_DEC, s.value);
130 BinaryPrimitive val(Res_value{});
  /frameworks/base/tools/aapt2/proto/
TableProtoSerializer_test.cpp 113 BinaryPrimitive* prim = test::GetValueForConfigAndProduct<BinaryPrimitive>(
118 prim = test::GetValueForConfigAndProduct<BinaryPrimitive>(
TableProtoSerializer.cpp 81 void Visit(BinaryPrimitive* prim) override {
TableProtoDeserializer.cpp 170 return util::make_unique<BinaryPrimitive>(static_cast<uint8_t>(pb_prim.type()),
  /frameworks/base/tools/aapt2/test/
Common.h 121 template std::ostream& operator<<<BinaryPrimitive>(std::ostream&, const BinaryPrimitive&);
Builders.cpp 140 std::unique_ptr<BinaryPrimitive> BuildPrimitive(uint8_t type, uint32_t data) {
145 return util::make_unique<BinaryPrimitive>(value);
Builders.h 78 std::unique_ptr<BinaryPrimitive> BuildPrimitive(uint8_t type, uint32_t data);
  /frameworks/base/tools/aapt2/link/
TableMerger_test.cpp 173 BinaryPrimitive* foo = test::GetValue<BinaryPrimitive>(&final_table, "com.app.a:bool/foo");
175 Pointee(Field(&BinaryPrimitive::value, Field(&android::Res_value::data, Eq(0u)))));
ReferenceLinker_test.cpp 130 ASSERT_THAT(ValueCast<BinaryPrimitive>(style->entries[0].value.get()), NotNull());
134 ASSERT_THAT(ValueCast<BinaryPrimitive>(style->entries[1].value.get()), NotNull());
ManifestFixer_test.cpp 356 EXPECT_NE(nullptr, ValueCast<BinaryPrimitive>(attr->compiled_value.get()));
ManifestFixer.cpp 152 std::unique_ptr<BinaryPrimitive> result = ResourceUtils::TryParseBool(attr->value);

Completed in 1167 milliseconds