Lines Matching refs:block
255 ResXMLTree& block, bool _appendComment)
257 , sourcePos(in->getPrintableSource(), block.getLineNumber())
299 ResXMLTree& block,
305 PendingAttribute attr(myPackage, in, block, inStyleable);
318 ssize_t identIdx = block.indexOfAttribute(NULL, "name");
320 attr.ident = String16(block.getAttributeStringValue(identIdx, &len));
330 block.getComment(&len) ? block.getComment(&len) : nulStr);
332 ssize_t typeIdx = block.indexOfAttribute(NULL, "format");
334 String16 typeStr = String16(block.getAttributeStringValue(typeIdx, &len));
350 ssize_t minIdx = block.indexOfAttribute(NULL, "min");
352 String16 val = String16(block.getAttributeStringValue(minIdx, &len));
368 ssize_t maxIdx = block.indexOfAttribute(NULL, "max");
370 String16 val = String16(block.getAttributeStringValue(maxIdx, &len));
389 ssize_t l10nIdx = block.indexOfAttribute(NULL, "localization");
391 const uint16_t* str = block.getAttributeStringValue(l10nIdx, &len);
413 while ((code=block.next()) != ResXMLTree::END_DOCUMENT && code != ResXMLTree::BAD_DOCUMENT) {
416 if (strcmp16(block.getElementName(&len), enum16.string()) == 0) {
418 } else if (strcmp16(block.getElementName(&len), flag16.string()) == 0) {
421 SourcePos(in->getPrintableSource(), block.getLineNumber())
423 String8(block.getElementName(&len)).string());
441 err = outTable->addBag(SourcePos(in->getPrintableSource(), block.getLineNumber()),
450 SourcePos(in->getPrintableSource(), block.getLineNumber())
454 SourcePos(in->getPrintableSource(), block.getLineNumber())
461 ssize_t itemIdentIdx = block.indexOfAttribute(NULL, "name");
463 itemIdent = String16(block.getAttributeStringValue(itemIdentIdx, &len));
465 SourcePos(in->getPrintableSource(), block.getLineNumber())
471 ssize_t valueIdx = block.indexOfAttribute(NULL, "value");
473 value = String16(block.getAttributeStringValue(valueIdx, &len));
475 SourcePos(in->getPrintableSource(), block.getLineNumber())
480 SourcePos(in->getPrintableSource(), block.getLineNumber())
489 err = outTable->startBag(SourcePos(in->getPrintableSource(), block.getLineNumber()),
515 if (block.getComment(&len)) {
516 enumOrFlagsComment.append(String16(block.getComment(&len)));
520 err = outTable->addBag(SourcePos(in->getPrintableSource(), block.getLineNumber()),
529 if (strcmp16(block.getElementName(&len), attr16.string()) == 0) {
533 if (strcmp16(block.getElementName(&len), enum16.string()) != 0) {
534 SourcePos(in->getPrintableSource(), block.getLineNumber())
536 String8(block.getElementName(&len)).string());
540 if (strcmp16(block.getElementName(&len), flag16.string()) != 0) {
541 SourcePos(in->getPrintableSource(), block.getLineNumber())
543 String8(block.getElementName(&len)).string());
570 ResXMLTree* block,
590 block, item16, &str, &spans, isFormatted,
606 err = outTable->addBag(SourcePos(in->getPrintableSource(), block->getLineNumber()),
665 ResXMLTree* block,
684 err = parseStyledString(bundle, in->getPrintableSource().string(), block,
746 err = outTable->addEntry(SourcePos(in->getPrintableSource(), block->getLineNumber()),
760 ResXMLTree block;
761 status_t err = parseXMLResource(in, &block, false, true);
839 code = block.next();
844 SourcePos(in->getPrintableSource(), block.getLineNumber()).error(
848 if (strcmp16(block.getElementName(&len), resources16.string()) != 0) {
849 SourcePos(in->getPrintableSource(), block.getLineNumber()).error(
850 "Invalid start tag %s\n", String8(block.getElementName(&len)).string());
862 while ((code=block.next()) != ResXMLTree::END_DOCUMENT && code != ResXMLTree::BAD_DOCUMENT) {
874 if (strcmp16(block.getElementName(&len), skip16.string()) == 0) {
875 while ((code=block.next()) != ResXMLTree::END_DOCUMENT
878 if (strcmp16(block.getElementName(&len), skip16.string()) == 0) {
885 } else if (strcmp16(block.getElementName(&len), eat_comment16.string()) == 0) {
886 while ((code=block.next()) != ResXMLTree::END_DOCUMENT
889 if (strcmp16(block.getElementName(&len), eat_comment16.string()) == 0) {
896 } else if (strcmp16(block.getElementName(&len), public16.string()) == 0) {
897 SourcePos srcPos(in->getPrintableSource(), block.getLineNumber());
900 ssize_t typeIdx = block.indexOfAttribute(NULL, "type");
905 type = String16(block.getAttributeStringValue(typeIdx, &len));
908 ssize_t nameIdx = block.indexOfAttribute(NULL, "name");
913 name = String16(block.getAttributeStringValue(nameIdx, &len));
916 ssize_t identIdx = block.indexOfAttribute(NULL, "id");
918 const char16_t* identStr = block.getAttributeStringValue(identIdx, &len);
922 String8(block.getAttributeStringValue(identIdx, &len)).string());
951 block.getComment(&len) ? block.getComment(&len) : nulStr);
959 while ((code=block.next()) != ResXMLTree::END_DOCUMENT && code != ResXMLTree::BAD_DOCUMENT) {
961 if (strcmp16(block.getElementName(&len), public16.string()) == 0) {
968 } else if (strcmp16(block.getElementName(&len), public_padding16.string()) == 0) {
969 SourcePos srcPos(in->getPrintableSource(), block.getLineNumber());
972 ssize_t typeIdx = block.indexOfAttribute(NULL, "type");
977 type = String16(block.getAttributeStringValue(typeIdx, &len));
980 ssize_t nameIdx = block.indexOfAttribute(NULL, "name");
985 name = String16(block.getAttributeStringValue(nameIdx, &len));
988 ssize_t startIdx = block.indexOfAttribute(NULL, "start");
990 const char16_t* startStr = block.getAttributeStringValue(startIdx, &len);
994 String8(block.getAttributeStringValue(startIdx, &len)).string());
1008 ssize_t endIdx = block.indexOfAttribute(NULL, "end");
1010 const char16_t* endStr = block.getAttributeStringValue(endIdx, &len);
1014 String8(block.getAttributeStringValue(endIdx, &len)).string());
1033 block.getComment(&len) ? block.getComment(&len) : nulStr);
1069 while ((code=block.next()) != ResXMLTree::END_DOCUMENT && code != ResXMLTree::BAD_DOCUMENT) {
1071 if (strcmp16(block.getElementName(&len), public_padding16.string()) == 0) {
1078 } else if (strcmp16(block.getElementName(&len), private_symbols16.string()) == 0) {
1080 ssize_t pkgIdx = block.indexOfAttribute(NULL, "package");
1082 SourcePos(in->getPrintableSource(), block.getLineNumber()).error(
1086 pkg = String16(block.getAttributeStringValue(pkgIdx, &len));
1091 while ((code=block.next()) != ResXMLTree::END_DOCUMENT && code != ResXMLTree::BAD_DOCUMENT) {
1093 if (strcmp16(block.getElementName(&len), private_symbols16.string()) == 0) {
1100 } else if (strcmp16(block.getElementName(&len), java_symbol16.string()) == 0) {
1101 SourcePos srcPos(in->getPrintableSource(), block.getLineNumber());
1104 ssize_t typeIdx = block.indexOfAttribute(NULL, "type");
1109 type = String16(block.getAttributeStringValue(typeIdx, &len));
1112 ssize_t nameIdx = block.indexOfAttribute(NULL, "name");
1117 name = String16(block.getAttributeStringValue(nameIdx, &len));
1126 block.getComment(&len) ? block.getComment(&len) : nulStr);
1133 while ((code=block.next()) != ResXMLTree::END_DOCUMENT && code != ResXMLTree::BAD_DOCUMENT) {
1135 if (strcmp16(block.getElementName(&len), java_symbol16.string()) == 0) {
1143 } else if (strcmp16(block.getElementName(&len), add_resource16.string()) == 0) {
1144 SourcePos srcPos(in->getPrintableSource(), block.getLineNumber());
1147 ssize_t typeIdx = block.indexOfAttribute(NULL, "type");
1152 typeName = String16(block.getAttributeStringValue(typeIdx, &len));
1155 ssize_t nameIdx = block.indexOfAttribute(NULL, "name");
1160 name = String16(block.getAttributeStringValue(nameIdx, &len));
1164 while ((code=block.next()) != ResXMLTree::END_DOCUMENT && code != ResXMLTree::BAD_DOCUMENT) {
1166 if (strcmp16(block.getElementName(&len), add_resource16.string()) == 0) {
1173 } else if (strcmp16(block.getElementName(&len), declare_styleable16.string()) == 0) {
1174 SourcePos srcPos(in->getPrintableSource(), block.getLineNumber());
1177 ssize_t identIdx = block.indexOfAttribute(NULL, "name");
1182 ident = String16(block.getAttributeStringValue(identIdx, &len));
1199 block.getComment(&len) ? block.getComment(&len) : nulStr);
1205 while ((code=block.next()) != ResXMLTree::END_DOCUMENT && code != ResXMLTree::BAD_DOCUMENT) {
1207 if (strcmp16(block.getElementName(&len), skip16.string()) == 0) {
1208 while ((code=block.next()) != ResXMLTree::END_DOCUMENT
1211 if (strcmp16(block.getElementName(&len), skip16.string()) == 0) {
1217 } else if (strcmp16(block.getElementName(&len), eat_comment16.string()) == 0) {
1218 while ((code=block.next()) != ResXMLTree::END_DOCUMENT
1221 if (strcmp16(block.getElementName(&len), eat_comment16.string()) == 0) {
1227 } else if (strcmp16(block.getElementName(&len), attr16.string()) != 0) {
1228 SourcePos(in->getPrintableSource(), block.getLineNumber()).error(
1230 String8(block.getElementName(&len)).string());
1235 block.getComment(&len) ? block.getComment(&len) : nulStr);
1237 err = compileAttribute(in, block, myPackage, outTable, &itemIdent, true);
1243 SourcePos srcPos(String8(in->getPrintableSource()), block.getLineNumber());
1250 if (strcmp16(block.getElementName(&len), declare_styleable16.string()) == 0) {
1254 SourcePos(in->getPrintableSource(), block.getLineNumber()).error(
1256 String8(block.getElementName(&len)).string());
1262 } else if (strcmp16(block.getElementName(&len), attr16.string()) == 0) {
1263 err = compileAttribute(in, block, myPackage, outTable, NULL);
1269 } else if (strcmp16(block.getElementName(&len), item16.string()) == 0) {
1271 ssize_t attri = block.indexOfAttribute(NULL, "type");
1273 curType = String16(block.getAttributeStringValue(attri, &len));
1274 ssize_t formatIdx = block.indexOfAttribute(NULL, "format");
1276 String16 formatStr = String16(block.getAttributeStringValue(
1281 SourcePos(in->getPrintableSource(), block.getLineNumber()).error(
1288 SourcePos(in->getPrintableSource(), block.getLineNumber()).error(
1293 } else if (strcmp16(block.getElementName(&len), string16.string()) == 0) {
1302 size_t n = block.getAttributeCount();
1305 const uint16_t* attr = block.getAttributeName(i, &length);
1307 name.setTo(block.getAttributeStringValue(i, &length));
1309 translatable.setTo(block.getAttributeStringValue(i, &length));
1311 formatted.setTo(block.getAttributeStringValue(i, &length));
1326 // Intentionally empty block:
1346 } else if (strcmp16(block.getElementName(&len), drawable16.string()) == 0) {
1350 } else if (strcmp16(block.getElementName(&len), color16.string()) == 0) {
1354 } else if (strcmp16(block.getElementName(&len), bool16.string()) == 0) {
1358 } else if (strcmp16(block.getElementName(&len), integer16.string()) == 0) {
1362 } else if (strcmp16(block.getElementName(&len), dimen16.string()) == 0) {
1366 } else if (strcmp16(block.getElementName(&len), fraction16.string()) == 0) {
1370 } else if (strcmp16(block.getElementName(&len), bag16.string()) == 0) {
1373 ssize_t attri = block.indexOfAttribute(NULL, "type");
1375 curType = String16(block.getAttributeStringValue(attri, &len));
1377 SourcePos(in->getPrintableSource(), block.getLineNumber()).error(
1381 } else if (strcmp16(block.getElementName(&len), style16.string()) == 0) {
1385 } else if (strcmp16(block.getElementName(&len), plurals16.string()) == 0) {
1389 } else if (strcmp16(block.getElementName(&len), array16.string()) == 0) {
1394 ssize_t formatIdx = block.indexOfAttribute(NULL, "format");
1396 String16 formatStr = String16(block.getAttributeStringValue(
1401 SourcePos(in->getPrintableSource(), block.getLineNumber()).error(
1407 } else if (strcmp16(block.getElementName(&len), string_array16.string()) == 0) {
1410 size_t n = block.getAttributeCount();
1413 const uint16_t* attr = block.getAttributeName(i, &length);
1416 const uint16_t* value = block.getAttributeStringValue(i, &length);
1430 } else if (strcmp16(block.getElementName(&len), integer_array16.string()) == 0) {
1437 SourcePos(in->getPrintableSource(), block.getLineNumber()).error(
1439 String8(block.getElementName(&len)).string());
1444 ssize_t identIdx = block.indexOfAttribute(NULL, "name");
1446 ident = String16(block.getAttributeStringValue(identIdx, &len));
1448 SourcePos(in->getPrintableSource(), block.getLineNumber()).error(
1455 identIdx = block.indexOfAttribute(NULL, "product");
1457 product = String16(block.getAttributeStringValue(identIdx, &len));
1460 String16 comment(block.getComment(&len) ? block.getComment(&len) : nulStr);
1465 ssize_t parentIdentIdx = block.indexOfAttribute(NULL, "parent");
1467 parentIdent = String16(block.getAttributeStringValue(parentIdentIdx, &len));
1477 block.getLineNumber()), myPackage, curType, ident,
1487 while ((code=block.next()) != ResXMLTree::END_DOCUMENT
1491 if (strcmp16(block.getElementName(&len), item16.string()) != 0) {
1492 SourcePos(in->getPrintableSource(), block.getLineNumber()).error(
1494 String8(block.getElementName(&len)).string(),
1504 ssize_t itemIdentIdx = block.indexOfAttribute(NULL, "quantity");
1506 String16 quantity16(block.getAttributeStringValue(itemIdentIdx, &len));
1526 SourcePos(in->getPrintableSource(), block.getLineNumber()).error(
1531 SourcePos(in->getPrintableSource(), block.getLineNumber()).error(
1536 ssize_t itemIdentIdx = block.indexOfAttribute(NULL, "name");
1538 itemIdent = String16(block.getAttributeStringValue(itemIdentIdx, &len));
1540 SourcePos(in->getPrintableSource(), block.getLineNumber()).error(
1547 block.getPosition(&parserPosition);
1549 err = parseAndAddBag(bundle, in, &block, curParams, myPackage, curType,
1557 block.setPosition(parserPosition);
1558 err = parseAndAddBag(bundle, in, &block, pseudoParams, myPackage,
1568 if (strcmp16(block.getElementName(&len), curTag->string()) != 0) {
1569 SourcePos(in->getPrintableSource(), block.getLineNumber()).error(
1571 String8(block.getElementName(&len)).string(),
1580 block.getPosition(&parserPosition);
1582 err = parseAndAddEntry(bundle, in, &block, curParams, myPackage, curType, ident,
1593 block.setPosition(parserPosition);
1594 err = parseAndAddEntry(bundle, in, &block, pseudoParams, myPackage, curType,
1617 if (strcmp16(block.getElementName(&len), resources16.string()) != 0) {
1618 SourcePos(in->getPrintableSource(), block.getLineNumber()).error(
1619 "Unexpected end tag %s\n", String8(block.getElementName(&len)).string());
1626 if (isWhitespace(block.getText(&len))) {
1629 SourcePos(in->getPrintableSource(), block.getLineNumber()).error(
1631 String8(block.getText(&len)).string());
2807 // Retrieve them in the same order as the type string block.