Home | History | Annotate | Download | only in expat

Lines Matching refs:enc

35 #define MUST_CONVERT(enc, s) (!(enc)->isUtf16 || (((char *)(s) - (char *)NULL) & 1))

43 #define MUST_CONVERT(enc, s) (!(enc)->isUtf8)
332 doProlog(XML_Parser parser, const ENCODING *enc, const char *s,
339 doContent(XML_Parser parser, int startTagLevel, const ENCODING *enc,
367 getAttributeId(XML_Parser parser, const ENCODING *enc, const char *start,
372 storeEntityValue(XML_Parser parser, const ENCODING *enc, const char *start,
375 reportProcessingInstruction(XML_Parser parser, const ENCODING *enc,
378 reportComment(XML_Parser parser, const ENCODING *enc, const char *start,
381 reportDefault(XML_Parser parser, const ENCODING *enc, const char *start,
416 poolAppend(STRING_POOL *pool, const ENCODING *enc,
419 poolStoreString(STRING_POOL *pool, const ENCODING *enc,
432 getElementType(XML_Parser parser, const ENCODING *enc,
2233 const ENCODING *enc,
2244 if (enc == encoding) {
2256 int tok = XmlContentTok(enc, s, end, &next);
2270 reportDefault(parser, enc, s, end);
2311 XML_Char ch = (XML_Char) XmlPredefinedEntityName(enc,
2312 s + enc->minBytesPerChar,
2313 next - enc->minBytesPerChar);
2318 reportDefault(parser, enc, s, next);
2321 name = poolStoreString(&dtd->pool, enc,
2322 s + enc->minBytesPerChar,
2323 next - enc->minBytesPerChar);
2342 reportDefault(parser, enc, s, next);
2355 reportDefault(parser, enc, s, next);
2378 reportDefault(parser, enc, s, next);
2408 tag->rawName = s + enc->minBytesPerChar;
2409 tag->rawNameLength = XmlNameLength(enc, tag->rawName);
2418 XmlConvert(enc,
2439 result = storeAtts(parser, enc, s, &(tag->name), &(tag->bindings));
2446 reportDefault(parser, enc, s, next);
2454 const char *rawName = s + enc->minBytesPerChar;
2459 name.str = poolStoreString(&tempPool, enc, rawName,
2460 rawName + XmlNameLength(enc, rawName));
2464 result = storeAtts(parser, enc, s, &name, &bindings);
2479 reportDefault(parser, enc, s, next);
2504 rawName = s + enc->minBytesPerChar*2;
2505 len = XmlNameLength(enc, rawName);
2535 reportDefault(parser, enc, s, next);
2551 int n = XmlCharRefNumber(enc, s);
2559 reportDefault(parser, enc, s, next);
2570 reportDefault(parser, enc, s, next);
2594 reportDefault(parser, enc, s, next);
2595 result = doCdataSection(parser, enc, &next, end, nextPtr, haveMore);
2610 if (MUST_CONVERT(enc, s)) {
2612 XmlConvert(enc, &s, end, &dataPtr, (ICHAR *)dataBufEnd);
2622 reportDefault(parser, enc, s, end);
2640 if (MUST_CONVERT(enc, s)) {
2643 XmlConvert(enc, &s, next, &dataPtr, (ICHAR *)dataBufEnd);
2658 reportDefault(parser, enc, s, next);
2662 if (!reportProcessingInstruction(parser, enc, s, next))
2666 if (!reportComment(parser, enc, s, next))
2671 reportDefault(parser, enc, s, next);
2698 storeAtts(XML_Parser parser, const ENCODING *enc,
2731 n = XmlGetAttributes(enc, attStr, attsSize, atts);
2750 XmlGetAttributes(enc, attStr, n, atts);
2760 ATTRIBUTE_ID *attId = getAttributeId(parser, enc, currAtt->name,
2762 + XmlNameLength(enc, currAtt->name));
2768 XmlNameLength(enc, currAtt->name);
2778 if (enc == encoding)
2800 result = storeAttributeValue(parser, enc, isCdata,
2810 appAtts[attIndex] = poolStoreString(&tempPool, enc, atts[i].valuePtr,
3194 const ENCODING *enc,
3203 if (enc == encoding) {
3217 int tok = XmlCdataSectionTok(enc, s, end, &next);
3229 reportDefault(parser, enc, s, next);
3242 reportDefault(parser, enc, s, next);
3248 if (MUST_CONVERT(enc, s)) {
3251 XmlConvert(enc, &s, next, &dataPtr, (ICHAR *)dataBufEnd);
3266 reportDefault(parser, enc, s, next);
3330 const ENCODING *enc,
3341 if (enc == encoding) {
3352 tok = XmlIgnoreSectionTok(enc, s, end, &next);
3357 reportDefault(parser, enc, s, next);
3520 ENCODING *enc;
3527 enc = (ns
3533 if (enc) {
3536 encoding = enc;
3701 const ENCODING *enc = encoding;
3705 tok = XmlPrologTok(enc, start, end, &next);
3723 return storeEntityValue(parser, enc, s, end);
3745 const ENCODING *enc,
3783 if (enc == encoding) {
3816 if (enc != encoding && !openInternalEntities->betweenDecl) {
3824 if (isParamEntity || enc != encoding) {
3825 if (XmlTokenRole(&prologState, XML_TOK_NONE, end, end, enc)
3839 role = XmlTokenRole(&prologState, tok, s, next, enc);
3846 enc = encoding;
3852 doctypeName = poolStoreString(&tempPool, enc, s, next);
3876 enc = encoding;
3894 if (!XmlIsPublicId(enc, s, next, eventPP))
3896 pubId = poolStoreString(&tempPool, enc,
3897 s + enc->minBytesPerChar,
3898 next - enc->minBytesPerChar);
3909 if (!XmlIsPublicId(enc, s, next, eventPP))
3914 enc,
3915 s + enc->minBytesPerChar,
3916 next - enc->minBytesPerChar);
4018 declElementType = getElementType(parser, enc, s, next);
4023 declAttributeId = getAttributeId(parser, enc, s, next);
4073 if (!poolAppend(&tempPool, enc, s, next))
4111 storeAttributeValue(parser, enc, declAttributeIsCdata,
4112 s + enc->minBytesPerChar,
4113 next - enc->minBytesPerChar,
4146 enum XML_Error result = storeEntityValue(parser, enc,
4147 s + enc->minBytesPerChar,
4148 next - enc->minBytesPerChar);
4176 doctypeSysid = poolStoreString(&tempPool, enc,
4177 s + enc->minBytesPerChar,
4178 next - enc->minBytesPerChar);
4213 declEntity->systemId = poolStoreString(&dtd->pool, enc,
4214 s + enc->minBytesPerChar,
4215 next - enc->minBytesPerChar);
4240 declEntity->notation = poolStoreString(&dtd->pool, enc, s, next);
4269 if (XmlPredefinedEntityName(enc, s, next)) {
4274 const XML_Char *name = poolStoreString(&dtd->pool, enc, s, next);
4306 const XML_Char *name = poolStoreString(&dtd->pool, enc, s, next);
4341 declNotationName = poolStoreString(&tempPool, enc, s, next);
4349 if (!XmlIsPublicId(enc, s, next, eventPP))
4353 enc,
4354 s + enc->minBytesPerChar,
4355 next - enc->minBytesPerChar);
4367 = poolStoreString(&tempPool, enc,
4368 s + enc->minBytesPerChar,
4369 next - enc->minBytesPerChar);
4410 reportDefault(parser, enc, s, next);
4412 result = doIgnoreSection(parser, enc, &next, end, nextPtr, haveMore);
4486 name = poolStoreString(&dtd->pool, enc,
4487 s + enc->minBytesPerChar,
4488 next - enc->minBytesPerChar);
4561 declElementType = getElementType(parser, enc, s, next);
4620 : next - enc->minBytesPerChar);
4626 el = getElementType(parser, enc, s, nxt);
4672 if (!reportProcessingInstruction(parser, enc, s, next))
4677 if (!reportComment(parser, enc, s, next))
4711 reportDefault(parser, enc, s, next);
4721 tok = XmlPrologTok(enc, s, end, &next);
4922 storeAttributeValue(XML_Parser parser, const ENCODING *enc, XML_Bool isCdata,
4926 enum XML_Error result = appendAttributeValue(parser, enc, isCdata, ptr,
4938 appendAttributeValue(XML_Parser parser, const ENCODING *enc, XML_Bool isCdata,
4945 int tok = XmlAttributeValueTok(enc, ptr, end, &next);
4950 if (enc == encoding)
4954 if (enc == encoding)
4961 int n = XmlCharRefNumber(enc, ptr);
4963 if (enc == encoding)
4973 if (enc == encoding)
4984 if (!poolAppend(pool, enc, ptr, next))
4988 next = ptr + enc->minBytesPerChar;
5002 XML_Char ch = (XML_Char) XmlPredefinedEntityName(enc,
5003 ptr + enc->minBytesPerChar,
5004 next - enc->minBytesPerChar);
5010 name = poolStoreString(&temp2Pool, enc,
5011 ptr + enc->minBytesPerChar,
5012 next - enc->minBytesPerChar);
5045 reportDefault(parser, enc, ptr, next);
5050 if (enc == encoding)
5055 if (enc == encoding)
5060 if (enc == encoding)
5078 if (enc == encoding)
5089 const ENCODING *enc,
5110 int tok = XmlEntityValueTok(enc, entityTextPtr, entityTextEnd, &next);
5114 if (isParamEntity || enc != encoding) {
5117 name = poolStoreString(&tempPool, enc,
5118 entityTextPtr + enc->minBytesPerChar,
5119 next - enc->minBytesPerChar);
5137 if (enc == encoding)
5186 if (!poolAppend(pool, enc, entityTextPtr, next)) {
5192 next = entityTextPtr + enc->minBytesPerChar;
5205 int n = XmlCharRefNumber(enc, entityTextPtr);
5207 if (enc == encoding)
5214 if (enc == encoding)
5229 if (enc == encoding)
5234 if (enc == encoding)
5239 if (enc == encoding)
5277 reportProcessingInstruction(XML_Parser parser, const ENCODING *enc,
5285 reportDefault(parser, enc, start, end);
5288 start += enc->minBytesPerChar * 2;
5289 tem = start + XmlNameLength(enc, start);
5290 target = poolStoreString(&tempPool, enc, start, tem);
5294 data = poolStoreString(&tempPool, enc,
5295 XmlSkipS(enc, tem),
5296 end - enc->minBytesPerChar*2);
5306 reportComment(XML_Parser parser, const ENCODING *enc,
5312 reportDefault(parser, enc, start, end);
5316 enc,
5317 start + enc->minBytesPerChar * 4,
5318 end - enc->minBytesPerChar * 3);
5328 reportDefault(XML_Parser parser, const ENCODING *enc,
5331 if (MUST_CONVERT(enc, s)) {
5334 if (enc == encoding) {
5344 XmlConvert(enc, &s, end, &dataPtr, (ICHAR *)dataBufEnd);
5430 getAttributeId(XML_Parser parser, const ENCODING *enc,
5438 name = poolStoreString(&dtd->pool, enc, start, end);
6145 poolAppend(STRING_POOL *pool, const ENCODING *enc,
6151 XmlConvert(enc, &ptr, end, (ICHAR **)&(pool->ptr), (ICHAR *)pool->end);
6198 poolStoreString(STRING_POOL *pool, const ENCODING *enc,
6201 if (!poolAppend(pool, enc, ptr, end))
6382 const ENCODING *enc,
6387 const XML_Char *name = poolStoreString(&dtd->pool, enc, ptr, end);