Lines Matching refs:out
53 #define xmlOutputBufferWriteLit(out, literal) xmlOutputBufferWrite((out), strlen("" literal), "" li… argument
72 xmlOutputBufferPtr out; member
471 static int dom_xml_output_qname(xmlOutputBufferPtr out, const dom_qname_pair *qname) in dom_xml_output_qname() argument
474 TRY(xmlOutputBufferWriteString(out, (const char *) qname->prefix)); in dom_xml_output_qname()
475 TRY(xmlOutputBufferWriteLit(out, ":")); in dom_xml_output_qname()
477 return xmlOutputBufferWriteString(out, (const char *) qname->name); in dom_xml_output_qname()
483 static int dom_xml_common_text_serialization(xmlOutputBufferPtr out, const char *content, bool attr… in dom_xml_common_text_serialization() argument
500 TRY(xmlOutputBufferWrite(out, content - last_output, last_output)); in dom_xml_common_text_serialization()
504 TRY(xmlOutputBufferWriteLit(out, "&")); in dom_xml_common_text_serialization()
509 TRY(xmlOutputBufferWriteLit(out, "<")); in dom_xml_common_text_serialization()
514 TRY(xmlOutputBufferWriteLit(out, ">")); in dom_xml_common_text_serialization()
519 TRY(xmlOutputBufferWriteLit(out, """)); in dom_xml_common_text_serialization()
526 TRY(xmlOutputBufferWriteLit(out, "	")); in dom_xml_common_text_serialization()
531 TRY(xmlOutputBufferWriteLit(out, " ")); in dom_xml_common_text_serialization()
536 TRY(xmlOutputBufferWriteLit(out, " ")); in dom_xml_common_text_serialization()
545 return xmlOutputBufferWrite(out, content - last_output, last_output); in dom_xml_common_text_serialization()
566 static zend_always_inline int dom_xml_serialize_text_node(xmlOutputBufferPtr out, xmlNodePtr text, … in dom_xml_serialize_text_node() argument
574 return dom_xml_common_text_serialization(out, (const char *) text->content, false); in dom_xml_serialize_text_node()
582 static int dom_xml_serialize_attribute_node_value(xmlOutputBufferPtr out, xmlAttrPtr attr) in dom_xml_serialize_attribute_node_value() argument
584 TRY(xmlOutputBufferWriteString(out, (const char *) attr->name)); in dom_xml_serialize_attribute_node_value()
585 TRY(xmlOutputBufferWriteLit(out, "=\"")); in dom_xml_serialize_attribute_node_value()
589 TRY(dom_xml_common_text_serialization(out, (const char *) child->content, true)); in dom_xml_serialize_attribute_node_value()
592 TRY(xmlOutputBufferWriteLit(out, "&")); in dom_xml_serialize_attribute_node_value()
593 TRY(dom_xml_common_text_serialization(out, (const char *) child->name, true)); in dom_xml_serialize_attribute_node_value()
594 TRY(xmlOutputBufferWriteLit(out, ";")); in dom_xml_serialize_attribute_node_value()
597 return xmlOutputBufferWriteLit(out, "\""); in dom_xml_serialize_attribute_node_value()
623 static int dom_xml_serialize_attribute_node(xmlOutputBufferPtr out, xmlNodePtr attr) in dom_xml_serialize_attribute_node() argument
626 TRY(xmlOutputBufferWriteString(out, (const char *) attr->ns->prefix)); in dom_xml_serialize_attribute_node()
627 TRY(xmlOutputBufferWriteLit(out, ":")); in dom_xml_serialize_attribute_node()
629 return dom_xml_serialize_attribute_node_value(out, (xmlAttrPtr) attr); in dom_xml_serialize_attribute_node()
633 static int dom_xml_serialize_comment_node(xmlOutputBufferPtr out, xmlNodePtr comment, bool require_… in dom_xml_serialize_comment_node() argument
649 TRY(xmlOutputBufferWriteLit(out, "<!--")); in dom_xml_serialize_comment_node()
651 TRY(xmlOutputBufferWriteString(out, (const char *) comment->content)); in dom_xml_serialize_comment_node()
653 return xmlOutputBufferWriteLit(out, "-->"); in dom_xml_serialize_comment_node()
657 static int dom_xml_serialize_processing_instruction(xmlOutputBufferPtr out, xmlNodePtr pi, bool req… in dom_xml_serialize_processing_instruction() argument
676 TRY(xmlOutputBufferWriteLit(out, "<?")); in dom_xml_serialize_processing_instruction()
677 TRY(xmlOutputBufferWriteString(out, (const char *) pi->name)); in dom_xml_serialize_processing_instruction()
678 TRY(xmlOutputBufferWriteLit(out, " ")); in dom_xml_serialize_processing_instruction()
680 TRY(xmlOutputBufferWriteString(out, (const char *) pi->content)); in dom_xml_serialize_processing_instruction()
682 return xmlOutputBufferWriteLit(out, "?>"); in dom_xml_serialize_processing_instruction()
687 static int dom_xml_serialize_cdata_section_node(xmlOutputBufferPtr out, xmlNodePtr cdata) in dom_xml_serialize_cdata_section_node() argument
689 TRY(xmlOutputBufferWriteLit(out, "<![CDATA[")); in dom_xml_serialize_cdata_section_node()
691 TRY(xmlOutputBufferWriteString(out, (const char *) cdata->content)); in dom_xml_serialize_cdata_section_node()
693 return xmlOutputBufferWriteLit(out, "]]>"); in dom_xml_serialize_cdata_section_node()
715 xmlOutputBufferPtr out, in dom_xml_serialize_attributes() argument
838 TRY_OR_CLEANUP(xmlOutputBufferWriteLit(out, " xmlns:")); in dom_xml_serialize_attributes()
839 TRY_OR_CLEANUP(xmlOutputBufferWriteString(out, (const char *) candidate_prefix)); in dom_xml_serialize_attributes()
840 TRY_OR_CLEANUP(xmlOutputBufferWriteLit(out, "=\"")); in dom_xml_serialize_attributes()
841 … TRY_OR_CLEANUP(dom_xml_common_text_serialization(out, (const char *) attribute_namespace, true)); in dom_xml_serialize_attributes()
842 TRY_OR_CLEANUP(xmlOutputBufferWriteLit(out, "\"")); in dom_xml_serialize_attributes()
847 TRY_OR_CLEANUP(xmlOutputBufferWriteLit(out, " ")); in dom_xml_serialize_attributes()
851 TRY_OR_CLEANUP(xmlOutputBufferWriteString(out, (const char *) candidate_prefix)); in dom_xml_serialize_attributes()
852 TRY_OR_CLEANUP(xmlOutputBufferWriteLit(out, ":")); in dom_xml_serialize_attributes()
867 TRY_OR_CLEANUP(dom_xml_serialize_attribute_node_value(out, attr)); in dom_xml_serialize_attributes()
895 static int dom_xml_output_indents(xmlOutputBufferPtr out, int indent) in dom_xml_output_indents() argument
897 TRY(xmlOutputBufferWriteLit(out, "\n")); in dom_xml_output_indents()
899 TRY(xmlOutputBufferWriteLit(out, " ")); in dom_xml_output_indents()
926 TRY(xmlOutputBufferWriteLit(ctx->out, "<")); in dom_xml_serialize_element_node()
976 TRY_OR_CLEANUP(dom_xml_output_qname(ctx->out, &qualified_name)); in dom_xml_serialize_element_node()
1021 TRY_OR_CLEANUP(dom_xml_output_qname(ctx->out, &qualified_name)); in dom_xml_serialize_element_node()
1043 TRY_OR_CLEANUP(dom_xml_output_qname(ctx->out, &qualified_name)); in dom_xml_serialize_element_node()
1046 TRY_OR_CLEANUP(xmlOutputBufferWriteLit(ctx->out, " xmlns:")); /* 12.5.5.1 - 12.5.5.2 */ in dom_xml_serialize_element_node()
1047 TRY_OR_CLEANUP(xmlOutputBufferWriteString(ctx->out, (const char *) prefix)); in dom_xml_serialize_element_node()
1048 TRY_OR_CLEANUP(xmlOutputBufferWriteLit(ctx->out, "=\"")); in dom_xml_serialize_element_node()
1049 TRY_OR_CLEANUP(dom_xml_common_text_serialization(ctx->out, (const char *) ns, true)); in dom_xml_serialize_element_node()
1050 TRY_OR_CLEANUP(xmlOutputBufferWriteLit(ctx->out, "\"")); in dom_xml_serialize_element_node()
1074 TRY_OR_CLEANUP(dom_xml_output_qname(ctx->out, &qualified_name)); in dom_xml_serialize_element_node()
1077 TRY_OR_CLEANUP(xmlOutputBufferWriteLit(ctx->out, " xmlns=\"")); /* 12.6.5.1 - 12.6.5.2 */ in dom_xml_serialize_element_node()
1078 TRY_OR_CLEANUP(dom_xml_common_text_serialization(ctx->out, (const char *) ns, true)); in dom_xml_serialize_element_node()
1079 TRY_OR_CLEANUP(xmlOutputBufferWriteLit(ctx->out, "\"")); in dom_xml_serialize_element_node()
1085 TRY_OR_CLEANUP(dom_xml_output_qname(ctx->out, &qualified_name)); in dom_xml_serialize_element_node()
1091 …TRY_OR_CLEANUP(dom_xml_serialize_attributes(ctx->out, element, &map, &local_prefixes_map, prefix_i… in dom_xml_serialize_element_node()
1119 TRY_OR_CLEANUP(xmlOutputBufferWriteLit(ctx->out, " /")); in dom_xml_serialize_element_node()
1125 TRY_OR_CLEANUP(xmlOutputBufferWriteLit(ctx->out, "/")); in dom_xml_serialize_element_node()
1131 TRY_OR_CLEANUP(xmlOutputBufferWriteLit(ctx->out, ">")); in dom_xml_serialize_element_node()
1156 TRY_OR_CLEANUP(dom_xml_output_indents(ctx->out, indent)); in dom_xml_serialize_element_node()
1163 TRY_OR_CLEANUP(dom_xml_output_indents(ctx->out, indent)); in dom_xml_serialize_element_node()
1167 TRY_OR_CLEANUP(xmlOutputBufferWriteLit(ctx->out, "</")); in dom_xml_serialize_element_node()
1168 TRY_OR_CLEANUP(dom_xml_output_qname(ctx->out, &qualified_name)); in dom_xml_serialize_element_node()
1169 TRY_OR_CLEANUP(xmlOutputBufferWriteLit(ctx->out, ">")); in dom_xml_serialize_element_node()
1228 TRY(xmlOutputBufferFlush(ctx->out)); in dom_xml_serializing_a_document_node()
1270 return dom_xml_serialize_text_node(ctx->out, node, require_well_formed); in dom_xml_serialization_algorithm()
1273 return dom_xml_serialize_comment_node(ctx->out, node, require_well_formed); in dom_xml_serialization_algorithm()
1276 return dom_xml_serialize_processing_instruction(ctx->out, node, require_well_formed); in dom_xml_serialization_algorithm()
1279 return dom_xml_serialize_cdata_section_node(ctx->out, node); in dom_xml_serialization_algorithm()
1282 return dom_xml_serialize_attribute_node(ctx->out, node); in dom_xml_serialization_algorithm()
1285 TRY(xmlOutputBufferFlush(ctx->out)); in dom_xml_serialization_algorithm()
1289 return xmlOutputBufferWriteLit(ctx->out, "\n"); in dom_xml_serialization_algorithm()
1298 int dom_xml_serialize(xmlSaveCtxtPtr ctxt, xmlOutputBufferPtr out, xmlNodePtr node, bool format, bo… in dom_xml_serialize() argument
1315 ctx.out = out; in dom_xml_serialize()