use of com.android.aapt.Resources.Attribute in project jadx by skylot.
the class ResProtoParser method parse.
private ProtoValue parse(Attribute a) {
String format = XmlGenUtils.getAttrTypeAsString(a.getFormatFlags());
List<ProtoValue> namedValues = new ArrayList<>(a.getSymbolCount());
for (int i = 0; i < a.getSymbolCount(); i++) {
Attribute.Symbol s = a.getSymbol(i);
int type = s.getType();
String name = s.getName().getName();
String value = String.valueOf(s.getValue());
namedValues.add(new ProtoValue(value).setName(name).setType(type));
}
return new ProtoValue(format).setNamedValues(namedValues);
}
Aggregations