Lines Matching refs:block
254 ResXMLTree& block, bool _appendComment) in PendingAttribute()
256 , sourcePos(in->getPrintableSource(), block.getLineNumber()) in PendingAttribute()
298 ResXMLTree& block, in compileAttribute() argument
304 PendingAttribute attr(myPackage, in, block, inStyleable); in compileAttribute()
317 ssize_t identIdx = block.indexOfAttribute(NULL, "name"); in compileAttribute()
319 attr.ident = String16(block.getAttributeStringValue(identIdx, &len)); in compileAttribute()
329 block.getComment(&len) ? block.getComment(&len) : nulStr); in compileAttribute()
331 ssize_t typeIdx = block.indexOfAttribute(NULL, "format"); in compileAttribute()
333 String16 typeStr = String16(block.getAttributeStringValue(typeIdx, &len)); in compileAttribute()
349 ssize_t minIdx = block.indexOfAttribute(NULL, "min"); in compileAttribute()
351 String16 val = String16(block.getAttributeStringValue(minIdx, &len)); in compileAttribute()
367 ssize_t maxIdx = block.indexOfAttribute(NULL, "max"); in compileAttribute()
369 String16 val = String16(block.getAttributeStringValue(maxIdx, &len)); in compileAttribute()
388 ssize_t l10nIdx = block.indexOfAttribute(NULL, "localization"); in compileAttribute()
390 const uint16_t* str = block.getAttributeStringValue(l10nIdx, &len); in compileAttribute()
412 while ((code=block.next()) != ResXMLTree::END_DOCUMENT && code != ResXMLTree::BAD_DOCUMENT) { in compileAttribute()
415 if (strcmp16(block.getElementName(&len), enum16.string()) == 0) { in compileAttribute()
417 } else if (strcmp16(block.getElementName(&len), flag16.string()) == 0) { in compileAttribute()
420 SourcePos(in->getPrintableSource(), block.getLineNumber()) in compileAttribute()
422 String8(block.getElementName(&len)).string()); in compileAttribute()
440 … err = outTable->addBag(SourcePos(in->getPrintableSource(), block.getLineNumber()), in compileAttribute()
449 SourcePos(in->getPrintableSource(), block.getLineNumber()) in compileAttribute()
453 SourcePos(in->getPrintableSource(), block.getLineNumber()) in compileAttribute()
460 ssize_t itemIdentIdx = block.indexOfAttribute(NULL, "name"); in compileAttribute()
462 itemIdent = String16(block.getAttributeStringValue(itemIdentIdx, &len)); in compileAttribute()
464 SourcePos(in->getPrintableSource(), block.getLineNumber()) in compileAttribute()
470 ssize_t valueIdx = block.indexOfAttribute(NULL, "value"); in compileAttribute()
472 value = String16(block.getAttributeStringValue(valueIdx, &len)); in compileAttribute()
474 SourcePos(in->getPrintableSource(), block.getLineNumber()) in compileAttribute()
479 SourcePos(in->getPrintableSource(), block.getLineNumber()) in compileAttribute()
488 err = outTable->startBag(SourcePos(in->getPrintableSource(), block.getLineNumber()), in compileAttribute()
514 if (block.getComment(&len)) { in compileAttribute()
515 enumOrFlagsComment.append(String16(block.getComment(&len))); in compileAttribute()
519 err = outTable->addBag(SourcePos(in->getPrintableSource(), block.getLineNumber()), in compileAttribute()
528 if (strcmp16(block.getElementName(&len), attr16.string()) == 0) { in compileAttribute()
532 if (strcmp16(block.getElementName(&len), enum16.string()) != 0) { in compileAttribute()
533 SourcePos(in->getPrintableSource(), block.getLineNumber()) in compileAttribute()
535 String8(block.getElementName(&len)).string()); in compileAttribute()
539 if (strcmp16(block.getElementName(&len), flag16.string()) != 0) { in compileAttribute()
540 SourcePos(in->getPrintableSource(), block.getLineNumber()) in compileAttribute()
542 String8(block.getElementName(&len)).string()); in compileAttribute()
569 ResXMLTree* block, in parseAndAddBag() argument
589 block, item16, &str, &spans, isFormatted, in parseAndAddBag()
605 err = outTable->addBag(SourcePos(in->getPrintableSource(), block->getLineNumber()), in parseAndAddBag()
640 ResXMLTree* block, in parseAndAddEntry() argument
658 err = parseStyledString(bundle, in->getPrintableSource().string(), block, in parseAndAddEntry()
713 err = outTable->addEntry(SourcePos(in->getPrintableSource(), block->getLineNumber()), in parseAndAddEntry()
727 ResXMLTree block; in compileResourceFile() local
728 status_t err = parseXMLResource(in, &block, false, true); in compileResourceFile()
801 code = block.next(); in compileResourceFile()
806 SourcePos(in->getPrintableSource(), block.getLineNumber()).error( in compileResourceFile()
810 if (strcmp16(block.getElementName(&len), resources16.string()) != 0) { in compileResourceFile()
811 SourcePos(in->getPrintableSource(), block.getLineNumber()).error( in compileResourceFile()
812 "Invalid start tag %s\n", String8(block.getElementName(&len)).string()); in compileResourceFile()
824 while ((code=block.next()) != ResXMLTree::END_DOCUMENT && code != ResXMLTree::BAD_DOCUMENT) { in compileResourceFile()
836 if (strcmp16(block.getElementName(&len), skip16.string()) == 0) { in compileResourceFile()
837 while ((code=block.next()) != ResXMLTree::END_DOCUMENT in compileResourceFile()
840 if (strcmp16(block.getElementName(&len), skip16.string()) == 0) { in compileResourceFile()
847 } else if (strcmp16(block.getElementName(&len), eat_comment16.string()) == 0) { in compileResourceFile()
848 while ((code=block.next()) != ResXMLTree::END_DOCUMENT in compileResourceFile()
851 if (strcmp16(block.getElementName(&len), eat_comment16.string()) == 0) { in compileResourceFile()
858 } else if (strcmp16(block.getElementName(&len), public16.string()) == 0) { in compileResourceFile()
859 SourcePos srcPos(in->getPrintableSource(), block.getLineNumber()); in compileResourceFile()
862 ssize_t typeIdx = block.indexOfAttribute(NULL, "type"); in compileResourceFile()
867 type = String16(block.getAttributeStringValue(typeIdx, &len)); in compileResourceFile()
870 ssize_t nameIdx = block.indexOfAttribute(NULL, "name"); in compileResourceFile()
875 name = String16(block.getAttributeStringValue(nameIdx, &len)); in compileResourceFile()
878 ssize_t identIdx = block.indexOfAttribute(NULL, "id"); in compileResourceFile()
880 const char16_t* identStr = block.getAttributeStringValue(identIdx, &len); in compileResourceFile()
884 String8(block.getAttributeStringValue(identIdx, &len)).string()); in compileResourceFile()
913 block.getComment(&len) ? block.getComment(&len) : nulStr); in compileResourceFile()
921 … while ((code=block.next()) != ResXMLTree::END_DOCUMENT && code != ResXMLTree::BAD_DOCUMENT) { in compileResourceFile()
923 if (strcmp16(block.getElementName(&len), public16.string()) == 0) { in compileResourceFile()
930 } else if (strcmp16(block.getElementName(&len), public_padding16.string()) == 0) { in compileResourceFile()
931 SourcePos srcPos(in->getPrintableSource(), block.getLineNumber()); in compileResourceFile()
934 ssize_t typeIdx = block.indexOfAttribute(NULL, "type"); in compileResourceFile()
939 type = String16(block.getAttributeStringValue(typeIdx, &len)); in compileResourceFile()
942 ssize_t nameIdx = block.indexOfAttribute(NULL, "name"); in compileResourceFile()
947 name = String16(block.getAttributeStringValue(nameIdx, &len)); in compileResourceFile()
950 ssize_t startIdx = block.indexOfAttribute(NULL, "start"); in compileResourceFile()
952 const char16_t* startStr = block.getAttributeStringValue(startIdx, &len); in compileResourceFile()
956 String8(block.getAttributeStringValue(startIdx, &len)).string()); in compileResourceFile()
970 ssize_t endIdx = block.indexOfAttribute(NULL, "end"); in compileResourceFile()
972 const char16_t* endStr = block.getAttributeStringValue(endIdx, &len); in compileResourceFile()
976 String8(block.getAttributeStringValue(endIdx, &len)).string()); in compileResourceFile()
995 block.getComment(&len) ? block.getComment(&len) : nulStr); in compileResourceFile()
1031 … while ((code=block.next()) != ResXMLTree::END_DOCUMENT && code != ResXMLTree::BAD_DOCUMENT) { in compileResourceFile()
1033 if (strcmp16(block.getElementName(&len), public_padding16.string()) == 0) { in compileResourceFile()
1040 } else if (strcmp16(block.getElementName(&len), private_symbols16.string()) == 0) { in compileResourceFile()
1042 ssize_t pkgIdx = block.indexOfAttribute(NULL, "package"); in compileResourceFile()
1044 SourcePos(in->getPrintableSource(), block.getLineNumber()).error( in compileResourceFile()
1048 pkg = String16(block.getAttributeStringValue(pkgIdx, &len)); in compileResourceFile()
1053 … while ((code=block.next()) != ResXMLTree::END_DOCUMENT && code != ResXMLTree::BAD_DOCUMENT) { in compileResourceFile()
1055 if (strcmp16(block.getElementName(&len), private_symbols16.string()) == 0) { in compileResourceFile()
1062 } else if (strcmp16(block.getElementName(&len), java_symbol16.string()) == 0) { in compileResourceFile()
1063 SourcePos srcPos(in->getPrintableSource(), block.getLineNumber()); in compileResourceFile()
1066 ssize_t typeIdx = block.indexOfAttribute(NULL, "type"); in compileResourceFile()
1071 type = String16(block.getAttributeStringValue(typeIdx, &len)); in compileResourceFile()
1074 ssize_t nameIdx = block.indexOfAttribute(NULL, "name"); in compileResourceFile()
1079 name = String16(block.getAttributeStringValue(nameIdx, &len)); in compileResourceFile()
1088 block.getComment(&len) ? block.getComment(&len) : nulStr); in compileResourceFile()
1095 … while ((code=block.next()) != ResXMLTree::END_DOCUMENT && code != ResXMLTree::BAD_DOCUMENT) { in compileResourceFile()
1097 if (strcmp16(block.getElementName(&len), java_symbol16.string()) == 0) { in compileResourceFile()
1105 } else if (strcmp16(block.getElementName(&len), add_resource16.string()) == 0) { in compileResourceFile()
1106 SourcePos srcPos(in->getPrintableSource(), block.getLineNumber()); in compileResourceFile()
1109 ssize_t typeIdx = block.indexOfAttribute(NULL, "type"); in compileResourceFile()
1114 typeName = String16(block.getAttributeStringValue(typeIdx, &len)); in compileResourceFile()
1117 ssize_t nameIdx = block.indexOfAttribute(NULL, "name"); in compileResourceFile()
1122 name = String16(block.getAttributeStringValue(nameIdx, &len)); in compileResourceFile()
1126 … while ((code=block.next()) != ResXMLTree::END_DOCUMENT && code != ResXMLTree::BAD_DOCUMENT) { in compileResourceFile()
1128 if (strcmp16(block.getElementName(&len), add_resource16.string()) == 0) { in compileResourceFile()
1135 } else if (strcmp16(block.getElementName(&len), declare_styleable16.string()) == 0) { in compileResourceFile()
1136 SourcePos srcPos(in->getPrintableSource(), block.getLineNumber()); in compileResourceFile()
1139 ssize_t identIdx = block.indexOfAttribute(NULL, "name"); in compileResourceFile()
1144 ident = String16(block.getAttributeStringValue(identIdx, &len)); in compileResourceFile()
1161 block.getComment(&len) ? block.getComment(&len) : nulStr); in compileResourceFile()
1167 … while ((code=block.next()) != ResXMLTree::END_DOCUMENT && code != ResXMLTree::BAD_DOCUMENT) { in compileResourceFile()
1169 if (strcmp16(block.getElementName(&len), skip16.string()) == 0) { in compileResourceFile()
1170 while ((code=block.next()) != ResXMLTree::END_DOCUMENT in compileResourceFile()
1173 … if (strcmp16(block.getElementName(&len), skip16.string()) == 0) { in compileResourceFile()
1179 … } else if (strcmp16(block.getElementName(&len), eat_comment16.string()) == 0) { in compileResourceFile()
1180 while ((code=block.next()) != ResXMLTree::END_DOCUMENT in compileResourceFile()
1183 … if (strcmp16(block.getElementName(&len), eat_comment16.string()) == 0) { in compileResourceFile()
1189 } else if (strcmp16(block.getElementName(&len), attr16.string()) != 0) { in compileResourceFile()
1190 SourcePos(in->getPrintableSource(), block.getLineNumber()).error( in compileResourceFile()
1192 String8(block.getElementName(&len)).string()); in compileResourceFile()
1197 block.getComment(&len) ? block.getComment(&len) : nulStr); in compileResourceFile()
1199 err = compileAttribute(in, block, myPackage, outTable, &itemIdent, true); in compileResourceFile()
1205 … SourcePos srcPos(String8(in->getPrintableSource()), block.getLineNumber()); in compileResourceFile()
1212 … if (strcmp16(block.getElementName(&len), declare_styleable16.string()) == 0) { in compileResourceFile()
1216 SourcePos(in->getPrintableSource(), block.getLineNumber()).error( in compileResourceFile()
1218 String8(block.getElementName(&len)).string()); in compileResourceFile()
1224 } else if (strcmp16(block.getElementName(&len), attr16.string()) == 0) { in compileResourceFile()
1225 err = compileAttribute(in, block, myPackage, outTable, NULL); in compileResourceFile()
1231 } else if (strcmp16(block.getElementName(&len), item16.string()) == 0) { in compileResourceFile()
1233 ssize_t attri = block.indexOfAttribute(NULL, "type"); in compileResourceFile()
1235 curType = String16(block.getAttributeStringValue(attri, &len)); in compileResourceFile()
1236 ssize_t formatIdx = block.indexOfAttribute(NULL, "format"); in compileResourceFile()
1238 String16 formatStr = String16(block.getAttributeStringValue( in compileResourceFile()
1243 SourcePos(in->getPrintableSource(), block.getLineNumber()).error( in compileResourceFile()
1250 SourcePos(in->getPrintableSource(), block.getLineNumber()).error( in compileResourceFile()
1255 } else if (strcmp16(block.getElementName(&len), string16.string()) == 0) { in compileResourceFile()
1264 size_t n = block.getAttributeCount(); in compileResourceFile()
1267 const uint16_t* attr = block.getAttributeName(i, &length); in compileResourceFile()
1269 name.setTo(block.getAttributeStringValue(i, &length)); in compileResourceFile()
1271 translatable.setTo(block.getAttributeStringValue(i, &length)); in compileResourceFile()
1273 formatted.setTo(block.getAttributeStringValue(i, &length)); in compileResourceFile()
1308 } else if (strcmp16(block.getElementName(&len), drawable16.string()) == 0) { in compileResourceFile()
1312 } else if (strcmp16(block.getElementName(&len), color16.string()) == 0) { in compileResourceFile()
1316 } else if (strcmp16(block.getElementName(&len), bool16.string()) == 0) { in compileResourceFile()
1320 } else if (strcmp16(block.getElementName(&len), integer16.string()) == 0) { in compileResourceFile()
1324 } else if (strcmp16(block.getElementName(&len), dimen16.string()) == 0) { in compileResourceFile()
1328 } else if (strcmp16(block.getElementName(&len), fraction16.string()) == 0) { in compileResourceFile()
1332 } else if (strcmp16(block.getElementName(&len), bag16.string()) == 0) { in compileResourceFile()
1335 ssize_t attri = block.indexOfAttribute(NULL, "type"); in compileResourceFile()
1337 curType = String16(block.getAttributeStringValue(attri, &len)); in compileResourceFile()
1339 SourcePos(in->getPrintableSource(), block.getLineNumber()).error( in compileResourceFile()
1343 } else if (strcmp16(block.getElementName(&len), style16.string()) == 0) { in compileResourceFile()
1347 } else if (strcmp16(block.getElementName(&len), plurals16.string()) == 0) { in compileResourceFile()
1351 } else if (strcmp16(block.getElementName(&len), array16.string()) == 0) { in compileResourceFile()
1356 ssize_t formatIdx = block.indexOfAttribute(NULL, "format"); in compileResourceFile()
1358 String16 formatStr = String16(block.getAttributeStringValue( in compileResourceFile()
1363 SourcePos(in->getPrintableSource(), block.getLineNumber()).error( in compileResourceFile()
1369 } else if (strcmp16(block.getElementName(&len), string_array16.string()) == 0) { in compileResourceFile()
1372 size_t n = block.getAttributeCount(); in compileResourceFile()
1375 const uint16_t* attr = block.getAttributeName(i, &length); in compileResourceFile()
1378 const uint16_t* value = block.getAttributeStringValue(i, &length); in compileResourceFile()
1392 } else if (strcmp16(block.getElementName(&len), integer_array16.string()) == 0) { in compileResourceFile()
1399 SourcePos(in->getPrintableSource(), block.getLineNumber()).error( in compileResourceFile()
1401 String8(block.getElementName(&len)).string()); in compileResourceFile()
1406 ssize_t identIdx = block.indexOfAttribute(NULL, "name"); in compileResourceFile()
1408 ident = String16(block.getAttributeStringValue(identIdx, &len)); in compileResourceFile()
1410 SourcePos(in->getPrintableSource(), block.getLineNumber()).error( in compileResourceFile()
1417 identIdx = block.indexOfAttribute(NULL, "product"); in compileResourceFile()
1419 product = String16(block.getAttributeStringValue(identIdx, &len)); in compileResourceFile()
1422 String16 comment(block.getComment(&len) ? block.getComment(&len) : nulStr); in compileResourceFile()
1427 ssize_t parentIdentIdx = block.indexOfAttribute(NULL, "parent"); in compileResourceFile()
1429 parentIdent = String16(block.getAttributeStringValue(parentIdentIdx, &len)); in compileResourceFile()
1439 block.getLineNumber()), myPackage, curType, ident, in compileResourceFile()
1449 while ((code=block.next()) != ResXMLTree::END_DOCUMENT in compileResourceFile()
1453 if (strcmp16(block.getElementName(&len), item16.string()) != 0) { in compileResourceFile()
1454 SourcePos(in->getPrintableSource(), block.getLineNumber()).error( in compileResourceFile()
1456 String8(block.getElementName(&len)).string(), in compileResourceFile()
1466 ssize_t itemIdentIdx = block.indexOfAttribute(NULL, "quantity"); in compileResourceFile()
1468 … String16 quantity16(block.getAttributeStringValue(itemIdentIdx, &len)); in compileResourceFile()
1488 … SourcePos(in->getPrintableSource(), block.getLineNumber()).error( in compileResourceFile()
1493 SourcePos(in->getPrintableSource(), block.getLineNumber()).error( in compileResourceFile()
1498 ssize_t itemIdentIdx = block.indexOfAttribute(NULL, "name"); in compileResourceFile()
1500 … itemIdent = String16(block.getAttributeStringValue(itemIdentIdx, &len)); in compileResourceFile()
1502 SourcePos(in->getPrintableSource(), block.getLineNumber()).error( in compileResourceFile()
1509 block.getPosition(&parserPosition); in compileResourceFile()
1511 err = parseAndAddBag(bundle, in, &block, curParams, myPackage, curType, in compileResourceFile()
1519 block.setPosition(parserPosition); in compileResourceFile()
1520 err = parseAndAddBag(bundle, in, &block, pseudoParams, myPackage, in compileResourceFile()
1530 if (strcmp16(block.getElementName(&len), curTag->string()) != 0) { in compileResourceFile()
1531 SourcePos(in->getPrintableSource(), block.getLineNumber()).error( in compileResourceFile()
1533 String8(block.getElementName(&len)).string(), in compileResourceFile()
1542 block.getPosition(&parserPosition); in compileResourceFile()
1544 err = parseAndAddEntry(bundle, in, &block, curParams, myPackage, curType, ident, in compileResourceFile()
1555 block.setPosition(parserPosition); in compileResourceFile()
1556 err = parseAndAddEntry(bundle, in, &block, pseudoParams, myPackage, curType, in compileResourceFile()
1579 if (strcmp16(block.getElementName(&len), resources16.string()) != 0) { in compileResourceFile()
1580 SourcePos(in->getPrintableSource(), block.getLineNumber()).error( in compileResourceFile()
1581 "Unexpected end tag %s\n", String8(block.getElementName(&len)).string()); in compileResourceFile()
1588 if (isWhitespace(block.getText(&len))) { in compileResourceFile()
1591 SourcePos(in->getPrintableSource(), block.getLineNumber()).error( in compileResourceFile()
1593 String8(block.getText(&len)).string()); in compileResourceFile()