38#define EXPECT_REF(obj,ref) _expect_ref((IUnknown*)obj, ref, __LINE__)
43 rc = IUnknown_Release(
obj);
44 ok_(__FILE__,
line)(rc ==
ref,
"expected refcount %ld, got %ld.\n",
ref, rc);
47#define check_interface(a, b, c) check_interface_(__LINE__, a, b, c)
56 hr = IUnknown_QueryInterface(iface, iid, (
void **)&unk);
57 ok_(__FILE__,
line)(
hr == expected_hr,
"Got hr %#lx, expected %#lx.\n",
hr, expected_hr);
59 IUnknown_Release(unk);
67 ref = IUnknown_AddRef(unk);
68 IUnknown_Release(unk);
154 if (lenexp !=
len)
return;
194 "putDocumentLocator",
197 "startPrefixMapping",
202 "ignorableWhitespace",
203 "processingInstruction",
251#define CONTENT_HANDLER_INDEX 0
252#define NUM_CALL_SEQUENCES 1
257 memset(call, 0,
sizeof(*call));
300 for (
i = 0;
i < call_seq->
count;
i++)
338 while (
ptr->uri) { lenexp++;
ptr++; };
374 add_call(seq, sequence_index, &end_of_sequence);
392 "%s: in event %s expecting line %d got %d\n",
399 "%s: in event %s expecting line %d got %d\n",
413 "%s: in event %s expecting column %d got %d\n",
420 "%s: in event %s expecting column %d got %d\n",
472 "%s: in event %s expecting ret %#lx got %#lx\n",
477 "%s: in event %s expecting ret %#lx got %#lx\n",
493 ok_(
file,
line) (
FALSE,
"%s: call %s was expected, but got call %s instead\n",
502 ok_(
file,
line) (
FALSE,
"%s: call %s was expected, but got call %s instead\n",
516 ok_(
file,
line) (
FALSE,
"%s: the call sequence is not complete: expected %s - actual %s\n",
523 ok_(
file,
line) (
FALSE,
"%s: the call sequence is not complete: expected %s - actual %s\n",
527 if (
todo && !failcount)
538#define ok_sequence(seq, index, exp, contx, todo) \
539 ok_sequence_(seq, index, (exp), (contx), (todo), __FILE__, __LINE__)
545 for (
i = 0;
i <
n;
i++)
546 seq[
i] =
calloc(1,
sizeof(**seq));
551L"<?xml version=\"1.0\" ?>\n"
553" <Number>1234</Number>\n"
554" <Name>Captain Ahab</Name>\n"
559L"<?xml version=\"1.0\"?>\r\n"
560"<BankAccount>\r\n\t<Number>1234</Number>\r\n\t"
561"<Name>Captain Ahab</Name>\r\n"
564static const WCHAR szUtf16XML[] =
L"<?xml version=\"1.0\" encoding=\"UTF-16\" standalone=\"no\"?>\r\n";
569"<?xml version=\"1.0\" encoding=\"UTF-8\" standalone=\"no\"?>\r\n";
572"<?xml version=\"1.0\" encoding=\"utf-8\" standalone=\"no\"?>\r\n";
575"<?xml version=\"1.0\" ?>\n"
577" <Number>1234</Number>\n"
578" <Name>Captain Ahab</Name>\n"
582"<?xml version=\"1.0\" ?>\n"
583"<document xmlns:test=\"prefix_test\" xmlns=\"prefix\" test:arg1=\"arg1\" arg2=\"arg2\" test:ar3=\"arg3\">\n"
584"<node1 xmlns:p=\"test\" />"
588"<?xml version=\"1.0\" ?>"
589"<a><![CDATA[Some \r\ntext\n\r\ndata\n\n]]></a>";
592"<?xml version=\"1.0\" ?>"
593"<a><![CDATA[\n\r\nSome \r\ntext\n\r\ndata\n\n]]></a>";
596"<?xml version=\"1.0\" ?><a><![CDATA[Some text data]]></a>";
713 {
"",
"",
"xmlns:test",
"prefix_test" },
714 {
"",
"",
"xmlns",
"prefix" },
715 {
"prefix_test",
"arg1",
"test:arg1",
"arg1" },
716 {
"",
"arg2",
"arg2",
"arg2" },
717 {
"prefix_test",
"ar3",
"test:ar3",
"arg3" },
722 {
"",
"",
"xmlns:p",
"test" },
745 {
"prefix_test",
"arg1",
"test:arg1",
"arg1" },
746 {
"",
"arg2",
"arg2",
"arg2" },
747 {
"prefix_test",
"ar3",
"test:ar3",
"arg3" },
748 {
"",
"",
"xmlns:test",
"prefix_test" },
749 {
"",
"",
"xmlns",
"prefix" },
773 {
"",
"",
"xmlns:test",
"prefix_test" },
774 {
"",
"",
"xmlns",
"prefix" },
775 {
"",
"",
"test:arg1",
"arg1" },
776 {
"",
"",
"arg2",
"arg2" },
777 {
"",
"",
"test:ar3",
"arg3" },
794 {
"prefix_test",
"arg1",
"test:arg1",
"arg1" },
795 {
"",
"arg2",
"arg2",
"arg2" },
796 {
"prefix_test",
"ar3",
"test:ar3",
"arg3" },
797 {
"http://www.w3.org/2000/xmlns/",
"",
"xmlns:test",
"prefix_test" },
798 {
"http://www.w3.org/2000/xmlns/",
"",
"xmlns",
"prefix" },
803 {
"http://www.w3.org/2000/xmlns/",
"",
"xmlns:p",
"test" },
827 {
"prefix_test",
"arg1",
"test:arg1",
"arg1" },
828 {
"",
"arg2",
"arg2",
"arg2" },
829 {
"prefix_test",
"ar3",
"test:ar3",
"arg3" },
870 {
"http://www.w3.org/XML/1998/namespace",
"space",
"xml:space",
"preserve" },
896 "<?xml version=\"1.0\" ?>\n"
897 "<a attr1=\" \r \n \tattr_value A & &\t \r \n\r\n \n\"/>\n";
900 {
"",
"attr1",
"attr1",
" attr_value A & & " },
1011 {
"",
"attr",
"attr",
"val" },
1037 "<?xml version=\"1.0\" encoding=\"UTF-16\"?>"
1038 "<a xml:space=\"preserve\"> Some text data </a>";
1059 ISAXContentHandler* iface,
1078 ISAXContentHandler* iface)
1084 ISAXContentHandler* iface)
1090 ISAXContentHandler* iface,
1091 ISAXLocator *pLocator)
1103 hr = ISAXLocator_QueryInterface(pLocator, &IID_IVBSAXLocator, (
void**)&unk);
1107 ISAXAttributes *
attr, *attr1;
1108 IMXAttributes *mxattr;
1111 hr = ISAXLocator_QueryInterface(pLocator, &IID_ISAXAttributes, (
void**)&
attr);
1114 hr = ISAXLocator_QueryInterface(pLocator, &IID_ISAXAttributes, (
void**)&attr1);
1117 ok(
attr == attr1,
"got %p, %p\n",
attr, attr1);
1119 hr = ISAXAttributes_QueryInterface(
attr, &IID_IVBSAXAttributes, (
void**)&unk);
1122 hr = ISAXLocator_QueryInterface(pLocator, &IID_IVBSAXAttributes, (
void**)&unk);
1125 hr = ISAXAttributes_QueryInterface(
attr, &IID_IMXAttributes, (
void**)&mxattr);
1128 ISAXAttributes_Release(
attr);
1129 ISAXAttributes_Release(attr1);
1137 ISAXContentHandler* iface)
1151 ISAXContentHandler* iface)
1163 ISAXContentHandler* iface,
1182 ISAXContentHandler* iface,
1198 ISAXContentHandler* iface,
1200 const WCHAR *localname,
int local_len,
1201 const WCHAR *qname,
int qname_len,
1202 ISAXAttributes *saxattr)
1205 IMXAttributes *mxattr;
1210 ok(localname !=
NULL,
"localname == NULL\n");
1211 ok(qname !=
NULL,
"qname == NULL\n");
1213 hr = ISAXAttributes_QueryInterface(saxattr, &IID_IMXAttributes, (
void**)&mxattr);
1228 hr = ISAXAttributes_getLength(saxattr, &
len);
1240 hr = ISAXXMLReader_getFeature(
g_reader,
_bstr_(
"http://xml.org/sax/features/namespaces"), &
v);
1243 for (
i = 0;
i <
len;
i++)
1248 hr = ISAXAttributes_getName(saxattr,
i, &
uri, &uri_len,
1249 &localname, &local_len, &
qname, &qname_len);
1252 hr = ISAXAttributes_getValue(saxattr,
i, &
value, &value_len);
1281 ISAXContentHandler* iface,
1283 const WCHAR *localname,
int local_len,
1289 ok(localname !=
NULL,
"localname == NULL\n");
1290 ok(qname !=
NULL,
"qname == NULL\n");
1303 ISAXContentHandler* iface,
1309 ok(chars !=
NULL,
"chars == NULL\n");
1320 ISAXContentHandler* iface,
1325 ok(chars !=
NULL,
"chars == NULL\n");
1336 ISAXContentHandler* iface,
1355 ISAXContentHandler* iface,
1391 ISAXErrorHandler* iface,
1410 ISAXErrorHandler* iface)
1416 ISAXErrorHandler* iface)
1422 ISAXErrorHandler* iface,
1423 ISAXLocator *pLocator,
1424 const WCHAR *pErrorMessage,
1427 ok(0,
"unexpected call\n");
1432 ISAXErrorHandler* iface,
1433 ISAXLocator *pLocator,
1450 ISAXErrorHandler* iface,
1451 ISAXLocator *pLocator,
1452 const WCHAR *pErrorMessage,
1455 ok(0,
"unexpected call\n");
1472 ISAXAttributes* iface,
1507 ISAXAttributes* iface,
1512 ok(0,
"unexpected call\n");
1517 ISAXAttributes* iface,
1519 const WCHAR **pLocalName,
1520 int *pLocalNameLength)
1522 ok(0,
"unexpected call\n");
1527 ISAXAttributes* iface,
1529 const WCHAR **QName,
1532 static const WCHAR attrqnamesW[][15] = {
L"a:attr1junk",
1535 static const int attrqnamelen[] = {7, 5, 5};
1540 *QName = attrqnamesW[
index];
1541 *QNameLength = attrqnamelen[
index];
1551 ISAXAttributes* iface,
1555 const WCHAR ** pLocalName,
1556 int * pLocalNameSize,
1557 const WCHAR ** pQName,
1560 ok(0,
"unexpected call\n");
1565 ISAXAttributes* iface,
1568 const WCHAR * pLocalName,
1569 int cocalNameLength,
1572 ok(0,
"unexpected call\n");
1577 ISAXAttributes* iface,
1578 const WCHAR * pQName,
1582 ok(0,
"unexpected call\n");
1587 ISAXAttributes* iface,
1589 const WCHAR ** pType,
1592 ok(0,
"unexpected call\n");
1597 ISAXAttributes* iface,
1600 const WCHAR * pLocalName,
1602 const WCHAR ** pType,
1605 ok(0,
"unexpected call\n");
1610 ISAXAttributes* iface,
1611 const WCHAR * pQName,
1613 const WCHAR ** pType,
1616 ok(0,
"unexpected call\n");
1623 static const WCHAR attrvaluesW[][10] = {
L"a1junk",
1626 static const int attrvalueslen[] = {2, 2, 5};
1632 *nValue = attrvalueslen[
index];
1642 ISAXAttributes* iface,
1645 const WCHAR * pLocalName,
1650 ok(0,
"unexpected call\n");
1655 ISAXAttributes* iface,
1656 const WCHAR * pQName,
1661 ok(0,
"unexpected call\n");
1709 ok(0,
"got unexpected IID_IUnknown query\n");
1718 ISAXLexicalHandler_AddRef(iface);
1739 int nPublicId,
const WCHAR * pSystemId,
int nSystemId)
1741 ok(0,
"call not expected\n");
1747 ok(0,
"call not expected\n");
1754 ok(0,
"call not expected\n");
1761 ok(0,
"call not expected\n");
1788 const WCHAR * pChars,
int nChars)
1790 ok(0,
"call not expected\n");
1837 ok(0,
"got unexpected IID_IUnknown query\n");
1846 ISAXDeclHandler_AddRef(iface);
1868 ok(0,
"call not expected\n");
1873 const WCHAR * pElementName,
int nElementName,
const WCHAR * pAttributeName,
1874 int nAttributeName,
const WCHAR * pType,
int nType,
const WCHAR * pValueDefault,
1875 int nValueDefault,
const WCHAR *
pValue,
int nValue)
1877 ok(0,
"call not expected\n");
1884 ok(0,
"call not expected\n");
1889 const WCHAR *
pName,
int nName,
const WCHAR * pPublicId,
int nPublicId,
1890 const WCHAR * pSystemId,
int nSystemId)
1892 ok(0,
"call not expected\n");
1957 ok(0,
"unexpected call\n");
1963 ok(0,
"unexpected call\n");
1970 ok(0,
"unexpected call\n");
1976 ok(0,
"unexpected call\n");
1983 ok(0,
"unexpected call\n");
1989 ok(0,
"unexpected call\n");
1995 ok(0,
"unexpected call\n");
2002 ok(0,
"unexpected call\n");
2009 ok(0,
"unexpected call\n");
2020 ok(0,
"unexpected call\n");
2028 ok(pv !=
NULL,
"pv == NULL\n");
2076 static const char *ret_str;
2079 ret_str =
"<?xml version=\"1.0\" ?>\n<rootelem>";
2081 ret_str =
"<elem attr=\"val\">text</elem>";
2083 ret_str =
"</rootelem>\n";
2089 *pcbRead =
strlen(ret_str);
2114 { &CLSID_SAXXMLReader,
"SAXReader" },
2115 { &CLSID_SAXXMLReader30,
"SAXReader30" },
2116 { &CLSID_SAXXMLReader40,
"SAXReader40" },
2117 { &CLSID_SAXXMLReader60,
"SAXReader60" },
2149 ISAXErrorHandler *lpErrorHandler;
2156 static const CHAR testXmlA[] =
"test.xml";
2161 while (
table->clsid)
2164 ISAXEntityResolver *resolver;
2199 hr = ISAXXMLReader_getErrorHandler(
reader, &lpErrorHandler);
2201 ok(lpErrorHandler ==
NULL,
"Expected %p, got %p\n",
NULL, lpErrorHandler);
2328 IVBSAXXMLReader *vb_reader;
2333 hr = ISAXXMLReader_QueryInterface(
reader, &IID_IVBSAXXMLReader, (
void **)&vb_reader);
2335 hr = IVBSAXXMLReader_parseURL(vb_reader,
NULL);
2337 IVBSAXXMLReader_Release(vb_reader);
2346 hr = ISAXXMLReader_parseURL(
reader,
L"test.xml");
2357 hr = ISAXXMLReader_parseURL(
reader,
L"test.xml");
2367 hr = ISAXXMLReader_parseURL(
reader,
L"test.xml");
2374 hr = ISAXXMLReader_parseURL(
reader,
L"test.xml");
2383 &IID_IXMLDOMDocument, (
void**)&doc);
2387 hr = IXMLDOMDocument_loadXML(doc,
str, &
v);
2404 IXMLDOMDocument_Release(doc);
2430 hr = ISAXXMLReader_putFeature(
reader,
_bstr_(
"http://xml.org/sax/features/namespaces"), VARIANT_FALSE);
2450 hr = ISAXXMLReader_putFeature(
reader,
_bstr_(
"http://xml.org/sax/features/namespaces"), VARIANT_TRUE);
2454 hr = ISAXXMLReader_putFeature(
reader,
_bstr_(
"http://xml.org/sax/features/namespace-prefixes"), VARIANT_FALSE);
2475 hr = ISAXXMLReader_putFeature(
reader,
_bstr_(
"http://xml.org/sax/features/namespace-prefixes"), VARIANT_TRUE);
2497 resolver = (
void*)0xdeadbeef;
2498 hr = ISAXXMLReader_getEntityResolver(
reader, &resolver);
2500 ok(resolver ==
NULL,
"got %p\n", resolver);
2510 hr = ISAXXMLReader_putProperty(
reader,
_bstr_(
"http://xml.org/sax/properties/lexical-handler"),
var);
2569 ISAXXMLReader_Release(
reader);
2583 {
"http://xml.org/sax/properties/lexical-handler", (
IUnknown*)&
lexicalhandler.ISAXLexicalHandler_iface },
2584 {
"http://xml.org/sax/properties/declaration-handler", (
IUnknown*)&
declhandler.ISAXDeclHandler_iface },
2597 &IID_ISAXXMLReader, (
void**)&
reader);
2600 hr = ISAXXMLReader_getProperty(
reader,
_bstr_(
"http://xml.org/sax/properties/lexical-handler"),
NULL);
2603 while (
ptr->prop_name)
2738 ISAXXMLReader_Release(
reader);
2744 &IID_ISAXXMLReader, (
void**)&
reader);
2749 V_BSTR(&
v) = (
void*)0xdeadbeef;
2750 hr = ISAXXMLReader_getProperty(
reader,
_bstr_(
"xmldecl-version"), &
v);
2762 V_BSTR(&
v) = (
void*)0xdeadbeef;
2763 hr = ISAXXMLReader_getProperty(
reader,
_bstr_(
"xmldecl-version"), &
v);
2770 V_BSTR(&
v) =
_bstr_(
"<?xml version=\"1.0\"?><element></element>");
2775 str =
_bstr_(
"<?xml version=\"1.0\"?><element></element>");
2782 V_BSTR(&
v) = (
void*)0xdeadbeef;
2783 hr = ISAXXMLReader_getProperty(
reader,
_bstr_(
"xmldecl-version"), &
v);
2789 ISAXXMLReader_Release(
reader);
2801 { &CLSID_SAXXMLReader,
"CLSID_SAXXMLReader", VARIANT_TRUE, VARIANT_FALSE },
2802 { &CLSID_SAXXMLReader30,
"CLSID_SAXXMLReader30", VARIANT_TRUE, VARIANT_FALSE },
2803 { &CLSID_SAXXMLReader40,
"CLSID_SAXXMLReader40", VARIANT_TRUE, VARIANT_TRUE },
2804 { &CLSID_SAXXMLReader60,
"CLSID_SAXXMLReader60", VARIANT_TRUE, VARIANT_TRUE },
2809 "http://xml.org/sax/features/namespaces",
2810 "http://xml.org/sax/features/namespace-prefixes",
2836 value = VARIANT_TRUE;
2838 ok(
hr ==
S_OK,
"Failed to get feature value, hr %#lx.\n",
hr);
2839 ok(
value == VARIANT_FALSE,
"Unexpected default feature value.\n");
2840 hr = ISAXXMLReader_putFeature(
reader,
_bstr_(
"exhaustive-errors"), VARIANT_FALSE);
2841 ok(
hr ==
S_OK,
"Failed to put feature value, hr %#lx.\n",
hr);
2843 value = VARIANT_TRUE;
2845 ok(
hr ==
S_OK,
"Failed to get feature value, hr %#lx.\n",
hr);
2846 ok(
value == VARIANT_FALSE,
"Unexpected default feature value.\n");
2847 hr = ISAXXMLReader_putFeature(
reader,
_bstr_(
"exhaustive-errors"), VARIANT_FALSE);
2848 ok(
hr ==
S_OK,
"Failed to put feature value, hr %#lx.\n",
hr);
2885 ok(
value == VARIANT_FALSE,
"%s: got wrong value %x, expected VARIANT_FALSE\n",
entry->clsid,
value);
2892 ok(
value == VARIANT_TRUE,
"%s: got wrong value %x, expected VARIANT_TRUE\n",
entry->clsid,
value);
2897 ISAXXMLReader_Release(
reader);
2905"\xEF\xBB\xBF<?xml version = \"1.0\" encoding = \"UTF-16\"?>\n"
2917 { &CLSID_SAXXMLReader,
"CLSID_SAXXMLReader",
UTF8BOMTest, 0xc00ce56f,
TRUE },
2918 { &CLSID_SAXXMLReader30,
"CLSID_SAXXMLReader30",
UTF8BOMTest, 0xc00ce56f,
TRUE },
2927 static const CHAR testXmlA[] =
"test.xml";
2950 hr = ISAXXMLReader_parseURL(
reader,
L"test.xml");
2962 ISAXXMLReader_Release(
reader);
2977 &IID_ISAXContentHandler,
2978 &IID_ISAXLexicalHandler,
2979 &IID_ISAXDeclHandler,
2980 &IID_ISAXDTDHandler,
2981 &IID_ISAXErrorHandler,
2982 &IID_IVBSAXDeclHandler,
2983 &IID_IVBSAXLexicalHandler,
2984 &IID_IVBSAXContentHandler,
2985 &IID_IVBSAXDTDHandler,
2986 &IID_IVBSAXErrorHandler
2990 &IID_IMXWriter, (
void**)&writer);
3001 hr = IMXWriter_QueryInterface(writer, riids[
i], (
void**)&
handler);
3007 hr = IUnknown_QueryInterface(
handler, &IID_IMXWriter, (
void**)&writer2);
3009 ok(writer2 == writer,
"got %p, expected %p\n", writer2, writer);
3011 IMXWriter_Release(writer2);
3015 IMXWriter_Release(writer);
3020 { &CLSID_MXXMLWriter,
"MXXMLWriter" },
3021 { &CLSID_MXXMLWriter30,
"MXXMLWriter30" },
3022 { &CLSID_MXXMLWriter40,
"MXXMLWriter40" },
3023 { &CLSID_MXXMLWriter60,
"MXXMLWriter60" },
3029 { &CLSID_SAXAttributes,
"SAXAttributes" },
3030 { &CLSID_SAXAttributes30,
"SAXAttributes30" },
3031 { &CLSID_SAXAttributes40,
"SAXAttributes40" },
3032 { &CLSID_SAXAttributes60,
"SAXAttributes60" },
3049 { &CLSID_MXXMLWriter, VARIANT_TRUE, VARIANT_FALSE, VARIANT_FALSE, VARIANT_FALSE, VARIANT_FALSE,
"UTF-16" },
3050 { &CLSID_MXXMLWriter30, VARIANT_TRUE, VARIANT_FALSE, VARIANT_FALSE, VARIANT_FALSE, VARIANT_FALSE,
"UTF-16" },
3051 { &CLSID_MXXMLWriter40, VARIANT_TRUE, VARIANT_FALSE, VARIANT_FALSE, VARIANT_FALSE, VARIANT_FALSE,
"UTF-16" },
3052 { &CLSID_MXXMLWriter60, VARIANT_TRUE, VARIANT_FALSE, VARIANT_FALSE, VARIANT_FALSE, VARIANT_FALSE,
"UTF-16" },
3060 while (
table->clsid)
3075 &IID_IMXWriter, (
void**)&writer);
3079 hr = IMXWriter_get_byteOrderMark(writer, &
b);
3081 ok(
table->bom ==
b,
"test %d: got BOM %d, expected %d\n",
i,
b,
table->bom);
3083 b = !
table->disable_escape;
3084 hr = IMXWriter_get_disableOutputEscaping(writer, &
b);
3086 ok(
table->disable_escape ==
b,
"test %d: got disable escape %d, expected %d\n",
i,
b,
3087 table->disable_escape);
3090 hr = IMXWriter_get_indent(writer, &
b);
3092 ok(
table->indent ==
b,
"test %d: got indent %d, expected %d\n",
i,
b,
table->indent);
3095 hr = IMXWriter_get_omitXMLDeclaration(writer, &
b);
3097 ok(
table->omitdecl ==
b,
"test %d: got omitdecl %d, expected %d\n",
i,
b,
table->omitdecl);
3100 hr = IMXWriter_get_standalone(writer, &
b);
3102 ok(
table->standalone ==
b,
"test %d: got standalone %d, expected %d\n",
i,
b,
table->standalone);
3104 hr = IMXWriter_get_encoding(writer, &
encoding);
3110 IMXWriter_Release(writer);
3129 &IID_IMXWriter, (
void**)&writer);
3132 hr = IMXWriter_get_disableOutputEscaping(writer,
NULL);
3135 hr = IMXWriter_get_byteOrderMark(writer,
NULL);
3138 hr = IMXWriter_get_indent(writer,
NULL);
3141 hr = IMXWriter_get_omitXMLDeclaration(writer,
NULL);
3144 hr = IMXWriter_get_standalone(writer,
NULL);
3148 hr = IMXWriter_put_standalone(writer, VARIANT_TRUE);
3152 hr = IMXWriter_get_standalone(writer, &
b);
3154 ok(
b == VARIANT_TRUE,
"got %d\n",
b);
3156 hr = IMXWriter_get_encoding(writer,
NULL);
3160 str = (
void*)0xdeadbeef;
3161 hr = IMXWriter_get_encoding(writer, &
str);
3165 str2 = (
void*)0xdeadbeef;
3166 hr = IMXWriter_get_encoding(writer, &str2);
3168 ok(
str != str2,
"expected newly allocated, got same %p\n",
str);
3175 hr = IMXWriter_put_encoding(writer,
str);
3179 str = (
void*)0xdeadbeef;
3180 hr = IMXWriter_get_encoding(writer, &
str);
3187 hr = IMXWriter_put_encoding(writer,
str);
3192 hr = IMXWriter_put_encoding(writer,
_bstr_(
"utf-8"));
3194 str = (
void*)0xdeadbeef;
3195 hr = IMXWriter_get_encoding(writer, &
str);
3200 hr = IMXWriter_put_encoding(writer,
_bstr_(
"uTf-16"));
3202 str = (
void*)0xdeadbeef;
3203 hr = IMXWriter_get_encoding(writer, &
str);
3209 hr = IMXWriter_QueryInterface(writer, &IID_ISAXContentHandler, (
void**)&
content);
3212 hr = ISAXContentHandler_startDocument(
content);
3214 hr = ISAXContentHandler_endDocument(
content);
3218 hr = IMXWriter_get_output(writer, &
dest);
3221 ok(!
lstrcmpW(
L"<?xml version=\"1.0\" encoding=\"UTF-16\" standalone=\"yes\"?>\r\n",
3224 ISAXContentHandler_Release(
content);
3226 hr = IMXWriter_get_version(writer,
NULL);
3229 hr = IMXWriter_get_version(writer, &
str);
3235 hr = IMXWriter_put_version(writer,
NULL);
3238 hr = IMXWriter_put_version(writer,
_bstr_(
"1.0"));
3241 hr = IMXWriter_put_version(writer,
_bstr_(
""));
3243 hr = IMXWriter_get_version(writer, &
str);
3248 hr = IMXWriter_put_version(writer,
_bstr_(
"a.b"));
3250 hr = IMXWriter_get_version(writer, &
str);
3255 hr = IMXWriter_put_version(writer,
_bstr_(
"2.0"));
3257 hr = IMXWriter_get_version(writer, &
str);
3262 IMXWriter_Release(writer);
3280 &IID_IMXWriter, (
void**)&writer);
3289 hr = IMXWriter_put_output(writer,
dest);
3295 hr = IMXWriter_put_output(writer,
dest);
3301 hr = IMXWriter_put_output(writer,
dest);
3307 hr = IMXWriter_put_output(writer,
dest);
3311 hr = IMXWriter_flush(writer);
3316 hr = IStream_Seek(
stream,
pos, STREAM_SEEK_CUR, &pos2);
3318 ok(pos2.
QuadPart == 0,
"expected stream beginning\n");
3320 hr = IMXWriter_QueryInterface(writer, &IID_ISAXContentHandler, (
void**)&
content);
3323 hr = ISAXContentHandler_startDocument(
content);
3327 hr = IStream_Seek(
stream,
pos, STREAM_SEEK_CUR, &pos2);
3329 ok(pos2.
QuadPart != 0,
"expected stream beginning\n");
3332 hr = ISAXContentHandler_startDocument(
content);
3335 hr = ISAXContentHandler_endDocument(
content);
3340 hr = IStream_Seek(
stream,
pos, STREAM_SEEK_CUR, &pos2);
3342 ok(pos2.
QuadPart != 0,
"expected stream position moved\n");
3353 hr = IMXWriter_put_output(writer,
dest);
3356 hr = IMXWriter_put_byteOrderMark(writer, VARIANT_FALSE);
3359 hr = IMXWriter_put_omitXMLDeclaration(writer, VARIANT_TRUE);
3362 hr = ISAXContentHandler_startDocument(
content);
3371 hr = IStream_Seek(
stream,
pos, STREAM_SEEK_CUR, &pos2);
3373 ok(pos2.
QuadPart == 0,
"expected stream beginning\n");
3384 hr = IStream_Seek(
stream,
pos, STREAM_SEEK_CUR, &pos2);
3386 ok(pos2.
QuadPart != 0,
"unexpected stream beginning\n");
3388 hr = IMXWriter_get_output(writer,
NULL);
3393 hr = IMXWriter_get_output(writer, &
dest);
3400 hr = ISAXContentHandler_endDocument(
content);
3410 hr = ISAXContentHandler_startDocument(
content);
3418 hr = IStream_Seek(
stream,
pos, STREAM_SEEK_CUR, &pos2);
3420 ok(pos2.
QuadPart == 0,
"expected stream beginning\n");
3429 hr = IStream_Seek(
stream,
pos, STREAM_SEEK_CUR, &pos2);
3431 ok(pos2.
QuadPart == 0,
"expected stream beginning\n");
3433 hr = ISAXContentHandler_endDocument(
content);
3438 hr = IMXWriter_put_output(writer,
dest);
3441 hr = ISAXContentHandler_startDocument(
content);
3453 hr = IMXWriter_get_output(writer, &
dest);
3460 ISAXContentHandler_Release(
content);
3462 IMXWriter_Release(writer);
3474 &IID_IMXWriter, (
void**)&writer);
3477 hr = IMXWriter_QueryInterface(writer, &IID_ISAXContentHandler, (
void**)&
content);
3480 hr = ISAXContentHandler_startDocument(
content);
3483 hr = ISAXContentHandler_endDocument(
content);
3487 hr = IMXWriter_get_output(writer, &
dest);
3495 hr = ISAXContentHandler_startDocument(
content);
3499 hr = IMXWriter_get_output(writer, &
dest);
3502 ok(!
lstrcmpW(
_bstr_(
"<?xml version=\"1.0\" encoding=\"UTF-16\" standalone=\"no\"?>\r\n"
3503 "<?xml version=\"1.0\" encoding=\"UTF-16\" standalone=\"no\"?>\r\n"),
V_BSTR(&
dest)),
3507 ISAXContentHandler_Release(
content);
3508 IMXWriter_Release(writer);
3512 &IID_IMXWriter, (
void**)&writer);
3515 hr = IMXWriter_QueryInterface(writer, &IID_ISAXContentHandler, (
void**)&
content);
3518 hr = IMXWriter_put_omitXMLDeclaration(writer, VARIANT_TRUE);
3521 hr = ISAXContentHandler_startDocument(
content);
3524 hr = ISAXContentHandler_endDocument(
content);
3528 hr = IMXWriter_get_output(writer, &
dest);
3534 ISAXContentHandler_Release(
content);
3535 IMXWriter_Release(writer);
3559static const char startelement_xml[] =
"<uri:local a:attr1=\"a1\" attr2=\"a2\" attr3=\"<&">\'\">";
3560static const char startendelement_xml[] =
"<uri:local a:attr1=\"a1\" attr2=\"a2\" attr3=\"<&">\'\"/>";
3584 { &CLSID_MXXMLWriter,
StartElement,
"uri",
"local",
"qname",
"<qname>",
S_OK },
3585 { &CLSID_MXXMLWriter30,
StartElement,
"uri",
"local",
"qname",
"<qname>",
S_OK },
3586 { &CLSID_MXXMLWriter40,
StartElement,
"uri",
"local",
"qname",
"<qname>",
S_OK },
3587 { &CLSID_MXXMLWriter60,
StartElement,
"uri",
"local",
"qname",
"<qname>",
S_OK },
3593 { &CLSID_MXXMLWriter,
StartElement,
"uri",
"local",
"uri:local",
"<uri:local>",
S_OK },
3595 { &CLSID_MXXMLWriter30,
StartElement,
"uri",
"local",
"uri:local",
"<uri:local>",
S_OK },
3596 { &CLSID_MXXMLWriter40,
StartElement,
"uri",
"local",
"uri:local",
"<uri:local>",
S_OK },
3597 { &CLSID_MXXMLWriter60,
StartElement,
"uri",
"local",
"uri:local",
"<uri:local>",
S_OK },
3598 { &CLSID_MXXMLWriter,
StartElement,
"uri",
"local",
"uri:local2",
"<uri:local2>",
S_OK },
3599 { &CLSID_MXXMLWriter30,
StartElement,
"uri",
"local",
"uri:local2",
"<uri:local2>",
S_OK },
3601 { &CLSID_MXXMLWriter40,
StartElement,
"uri",
"local",
"uri:local2",
"<uri:local2>",
S_OK },
3602 { &CLSID_MXXMLWriter60,
StartElement,
"uri",
"local",
"uri:local2",
"<uri:local2>",
S_OK },
3623 { &CLSID_MXXMLWriter,
EndElement,
"uri",
"local",
"qname",
"</qname>",
S_OK },
3624 { &CLSID_MXXMLWriter30,
EndElement,
"uri",
"local",
"qname",
"</qname>",
S_OK },
3626 { &CLSID_MXXMLWriter40,
EndElement,
"uri",
"local",
"qname",
"</qname>",
S_OK },
3627 { &CLSID_MXXMLWriter60,
EndElement,
"uri",
"local",
"qname",
"</qname>",
S_OK },
3633 { &CLSID_MXXMLWriter,
EndElement,
"uri",
"local",
"uri:local",
"</uri:local>",
S_OK },
3634 { &CLSID_MXXMLWriter30,
EndElement,
"uri",
"local",
"uri:local",
"</uri:local>",
S_OK },
3635 { &CLSID_MXXMLWriter40,
EndElement,
"uri",
"local",
"uri:local",
"</uri:local>",
S_OK },
3636 { &CLSID_MXXMLWriter60,
EndElement,
"uri",
"local",
"uri:local",
"</uri:local>",
S_OK },
3638 { &CLSID_MXXMLWriter,
EndElement,
"uri",
"local",
"uri:local2",
"</uri:local2>",
S_OK },
3639 { &CLSID_MXXMLWriter30,
EndElement,
"uri",
"local",
"uri:local2",
"</uri:local2>",
S_OK },
3640 { &CLSID_MXXMLWriter40,
EndElement,
"uri",
"local",
"uri:local2",
"</uri:local2>",
S_OK },
3641 { &CLSID_MXXMLWriter60,
EndElement,
"uri",
"local",
"uri:local2",
"</uri:local2>",
S_OK },
3672 while (
table->clsid)
3678 if (
hr ==
S_OK) IUnknown_Release(unk);
3691 while (
table->clsid)
3705 &IID_IMXWriter, (
void**)&writer);
3708 hr = IMXWriter_QueryInterface(writer, &IID_ISAXContentHandler, (
void**)&
content);
3711 hr = IMXWriter_put_omitXMLDeclaration(writer, VARIANT_TRUE);
3714 hr = ISAXContentHandler_startDocument(
content);
3719 hr = IMXWriter_put_disableOutputEscaping(writer, VARIANT_TRUE);
3745 hr = IMXWriter_get_output(writer, &
dest);
3753 ISAXContentHandler_Release(
content);
3754 IMXWriter_Release(writer);
3775 { &CLSID_MXXMLWriter,
"a", -1,
"b", -1,
"<a/>",
S_OK },
3776 { &CLSID_MXXMLWriter30,
"a", -1,
"b", -1,
"<a/>",
S_OK },
3777 { &CLSID_MXXMLWriter40,
"a", -1,
"b", -1,
"<a/>",
S_OK },
3779 { &CLSID_MXXMLWriter60,
"a", -1,
"b", -1,
"<a/>",
E_INVALIDARG },
3781 { &CLSID_MXXMLWriter,
"a", 1,
"b", 1,
"<a/>",
S_OK },
3782 { &CLSID_MXXMLWriter30,
"a", 1,
"b", 1,
"<a/>",
S_OK },
3783 { &CLSID_MXXMLWriter40,
"a", 1,
"b", 1,
"<a/>",
S_OK },
3784 { &CLSID_MXXMLWriter60,
"a", 1,
"b", 1,
"<a/>",
S_OK },
3792 while (
table->clsid)
3806 &IID_IMXWriter, (
void**)&writer);
3809 hr = IMXWriter_QueryInterface(writer, &IID_ISAXContentHandler, (
void**)&
content);
3812 hr = IMXWriter_put_omitXMLDeclaration(writer, VARIANT_TRUE);
3815 hr = ISAXContentHandler_startDocument(
content);
3832 hr = IMXWriter_get_output(writer, &
dest);
3840 ISAXContentHandler_Release(
content);
3841 IMXWriter_Release(writer);
3854 IVBSAXContentHandler *vb_content;
3857 BSTR bstr_null =
NULL, bstr_empty, bstr_a, bstr_b, bstr_ab;
3864 &IID_IMXWriter, (
void**)&writer);
3867 hr = IMXWriter_put_omitXMLDeclaration(writer, VARIANT_TRUE);
3870 hr = IMXWriter_QueryInterface(writer, &IID_IVBSAXContentHandler, (
void**)&vb_content);
3873 hr = IVBSAXContentHandler_startDocument(vb_content);
3881 hr = IVBSAXContentHandler_startElement(vb_content, &bstr_null, &bstr_empty, &bstr_b,
NULL);
3884 hr = IVBSAXContentHandler_startElement(vb_content, &bstr_empty, &bstr_b, &bstr_empty,
NULL);
3888 hr = IMXWriter_get_output(writer, &
dest);
3894 hr = IVBSAXContentHandler_startElement(vb_content, &bstr_empty, &bstr_empty, &bstr_b,
NULL);
3898 hr = IMXWriter_get_output(writer, &
dest);
3904 hr = IVBSAXContentHandler_endElement(vb_content, &bstr_null, &bstr_null, &bstr_b);
3907 hr = IVBSAXContentHandler_endElement(vb_content, &bstr_null, &bstr_a, &bstr_b);
3910 hr = IVBSAXContentHandler_endElement(vb_content, &bstr_a, &bstr_b, &bstr_null);
3913 hr = IVBSAXContentHandler_endElement(vb_content, &bstr_empty, &bstr_null, &bstr_b);
3916 hr = IVBSAXContentHandler_endElement(vb_content, &bstr_empty, &bstr_b, &bstr_null);
3919 hr = IVBSAXContentHandler_endElement(vb_content, &bstr_empty, &bstr_empty, &bstr_b);
3923 hr = IMXWriter_get_output(writer, &
dest);
3934 hr = IVBSAXContentHandler_endDocument(vb_content);
3937 IVBSAXContentHandler_Release(vb_content);
3938 IMXWriter_Release(writer);
3941 &IID_IMXWriter, (
void**)&writer);
3944 hr = IMXWriter_put_omitXMLDeclaration(writer, VARIANT_TRUE);
3947 hr = IMXWriter_QueryInterface(writer, &IID_ISAXContentHandler, (
void**)&
content);
3950 hr = ISAXContentHandler_startDocument(
content);
3958 hr = IMXWriter_get_output(writer, &
dest);
3968 hr = IMXWriter_get_output(writer, &
dest);
3988 hr = IMXWriter_get_output(writer, &
dest);
3994 hr = ISAXContentHandler_endDocument(
content);
3998 hr = IMXWriter_put_output(writer,
dest);
4002 hr = IMXWriter_get_output(writer, &
dest);
4008 hr = ISAXContentHandler_startDocument(
content);
4015 hr = IMXWriter_get_output(writer, &
dest);
4021 hr = ISAXContentHandler_endDocument(
content);
4023 IMXWriter_flush(writer);
4028 hr = IMXWriter_get_output(writer, &
dest);
4035 hr = IMXWriter_put_output(writer,
dest);
4042 hr = IMXWriter_get_output(writer, &
dest);
4048 ISAXContentHandler_Release(
content);
4049 IMXWriter_Release(writer);
4060 { &CLSID_MXXMLWriter,
"< > & \" \'",
"< > & \" \'" },
4061 { &CLSID_MXXMLWriter30,
"< > & \" \'",
"< > & \" \'" },
4062 { &CLSID_MXXMLWriter40,
"< > & \" \'",
"< > & \" \'" },
4063 { &CLSID_MXXMLWriter60,
"< > & \" \'",
"< > & \" \'" },
4069 static const WCHAR embedded_nullbytes[] =
L"a\0b\0\0\0c";
4071 IVBSAXContentHandler *vb_content;
4080 &IID_IMXWriter, (
void**)&writer);
4083 hr = IMXWriter_QueryInterface(writer, &IID_ISAXContentHandler, (
void**)&
content);
4086 hr = IMXWriter_QueryInterface(writer, &IID_IVBSAXContentHandler, (
void**)&vb_content);
4089 hr = IMXWriter_put_omitXMLDeclaration(writer, VARIANT_TRUE);
4092 hr = ISAXContentHandler_startDocument(
content);
4098 hr = ISAXContentHandler_characters(
content,
L"TESTCHARDATA .", 0);
4102 hr = IVBSAXContentHandler_characters(vb_content, &
str);
4105 hr = ISAXContentHandler_characters(
content,
L"TESTCHARDATA .", 14);
4109 hr = IMXWriter_get_output(writer, &
dest);
4115 hr = ISAXContentHandler_endDocument(
content);
4118 ISAXContentHandler_Release(
content);
4119 IVBSAXContentHandler_Release(vb_content);
4120 IMXWriter_Release(writer);
4124 &IID_IMXWriter, (
void**)&writer);
4127 hr = IMXWriter_QueryInterface(writer, &IID_ISAXContentHandler, (
void**)&
content);
4130 hr = IMXWriter_put_omitXMLDeclaration(writer, VARIANT_TRUE);
4133 hr = ISAXContentHandler_startDocument(
content);
4139 hr = ISAXContentHandler_characters(
content,
L"TESTCHARDATA .", 0);
4146 hr = IMXWriter_get_output(writer, &
dest);
4152 ISAXContentHandler_Release(
content);
4153 IMXWriter_Release(writer);
4157 &IID_IMXWriter, (
void**)&writer);
4160 hr = IMXWriter_QueryInterface(writer, &IID_ISAXContentHandler, (
void**)&
content);
4163 hr = IMXWriter_put_omitXMLDeclaration(writer, VARIANT_TRUE);
4166 hr = ISAXContentHandler_startDocument(
content);
4169 hr = ISAXContentHandler_characters(
content, embedded_nullbytes,
ARRAY_SIZE(embedded_nullbytes));
4173 hr = IMXWriter_get_output(writer, &
dest);
4181 ISAXContentHandler_Release(
content);
4182 IMXWriter_Release(writer);
4185 &IID_IMXWriter, (
void**)&writer);
4188 hr = IMXWriter_QueryInterface(writer, &IID_IVBSAXContentHandler, (
void**)&vb_content);
4191 hr = IMXWriter_put_omitXMLDeclaration(writer, VARIANT_TRUE);
4194 hr = IVBSAXContentHandler_startDocument(vb_content);
4198 hr = IVBSAXContentHandler_characters(vb_content, &
str);
4203 hr = IMXWriter_get_output(writer, &
dest);
4211 IVBSAXContentHandler_Release(vb_content);
4212 IMXWriter_Release(writer);
4215 while (
table->clsid)
4230 &IID_IMXWriter, (
void**)&writer);
4233 hr = IMXWriter_QueryInterface(writer, &IID_ISAXContentHandler, (
void**)&
content);
4236 hr = IMXWriter_put_omitXMLDeclaration(writer, VARIANT_TRUE);
4239 hr = ISAXContentHandler_startDocument(
content);
4249 hr = IMXWriter_get_output(writer, &
dest);
4259 hr = IMXWriter_put_output(writer,
dest);
4262 hr = IMXWriter_put_disableOutputEscaping(writer, VARIANT_TRUE);
4272 hr = IMXWriter_get_output(writer, &
dest);
4280 ISAXContentHandler_Release(
content);
4281 IMXWriter_Release(writer);
4292 VARIANT_TRUE,
"UTF-16",
4300 VARIANT_FALSE,
"UTF-16",
4307 VARIANT_TRUE,
"UTF-8",
4318 VARIANT_TRUE,
"utf-8",
4329 VARIANT_TRUE,
"UTF-16",
4337 VARIANT_TRUE,
"UTF-16",
4361 &IID_IMXWriter, (
void**)&writer);
4364 hr = IMXWriter_QueryInterface(writer, &IID_ISAXContentHandler, (
void**)&
content);
4367 hr = IMXWriter_put_encoding(writer,
_bstr_(
test->encoding));
4372 hr = IMXWriter_put_output(writer,
dest);
4375 hr = IMXWriter_put_byteOrderMark(writer,
test->bom);
4380 hr = ISAXContentHandler_startDocument(
content);
4383 hr = ISAXContentHandler_endDocument(
content);
4386 ISAXContentHandler_Release(
content);
4387 IMXWriter_Release(writer);
4394 &IID_IMXWriter, (
void**)&writer);
4400 hr = IMXWriter_QueryInterface(writer, &IID_ISAXContentHandler, (
void**)&
content);
4403 hr = IMXWriter_put_encoding(writer,
_bstr_(
"UTF-8"));
4408 hr = IMXWriter_put_output(writer,
dest);
4411 hr = ISAXContentHandler_startDocument(
content);
4418 hr = IMXWriter_put_output(writer,
dest);
4422 hr = IStream_Seek(
stream,
pos, STREAM_SEEK_CUR, &pos2);
4424 ok(pos2.
QuadPart != 0,
"expected stream position moved\n");
4426 hr = ISAXContentHandler_startDocument(
content);
4429 hr = ISAXContentHandler_endDocument(
content);
4433 hr = IMXWriter_get_output(writer, &
dest);
4442 hr = IMXWriter_put_output(writer,
dest);
4451 hr = IMXWriter_put_output(writer,
dest);
4454 hr = IMXWriter_put_byteOrderMark(writer, VARIANT_TRUE);
4457 hr = IMXWriter_put_encoding(writer,
_bstr_(
"UTF-16"));
4460 hr = ISAXContentHandler_startDocument(
content);
4465 hr = IStream_Seek(
stream,
pos, STREAM_SEEK_CUR, &pos2);
4467 ok(pos2.
QuadPart == 2,
"got wrong position\n");
4470 ISAXContentHandler_Release(
content);
4471 IMXWriter_Release(writer);
4486 LONG list_length = 0;
4490 hr =
CoCreateInstance(&CLSID_MXXMLWriter60,
NULL, CLSCTX_INPROC_SERVER, &IID_IMXWriter, (
void**)&writer);
4491 ok(
hr ==
S_OK,
"Failed to create a writer, hr %#lx.\n",
hr);
4493 hr = IMXWriter_QueryInterface(writer, &IID_ISAXContentHandler, (
void**)&
content);
4496 hr =
CoCreateInstance(&CLSID_DOMDocument60,
NULL, CLSCTX_INPROC_SERVER, &IID_IXMLDOMDocument, (
void **)&domdoc);
4497 ok(
hr ==
S_OK,
"Failed to create a document, hr %#lx.\n",
hr);
4502 hr = IMXWriter_put_output(writer,
dest);
4504 ok(
hr ==
S_OK,
"Failed to set writer output, hr %#lx.\n",
hr);
4507 IXMLDOMDocument_Release(domdoc);
4508 IMXWriter_Release(writer);
4513 hr = IXMLDOMDocument_createElement(domdoc,
_bstr_(
"TestElement"), &
root);
4517 IXMLDOMElement_Release(
root);
4519 hr = IXMLDOMDocument_get_documentElement(domdoc, &
root);
4521 ok(
root !=
NULL,
"Unexpected document root.\n");
4522 IXMLDOMElement_Release(
root);
4525 hr = ISAXContentHandler_startDocument(
content);
4528 hr = IXMLDOMDocument_get_documentElement(domdoc, &
root);
4532 hr = IXMLDOMDocument_createElement(domdoc,
_bstr_(
"TestElement"), &
root);
4537 hr = ISAXContentHandler_startElement(
content,
L"", 0,
L"", 0,
L"BankAccount", 11,
NULL);
4540 hr = IXMLDOMDocument_get_documentElement(domdoc, &
root);
4542 ok(
root !=
NULL,
"Unexpected document root.\n");
4544 hr = IXMLDOMElement_get_nodeName(
root, &
str);
4551 hr = ISAXContentHandler_startElement(
content,
L"", 0,
L"", 0,
L"Number", 6,
NULL);
4554 hr = IXMLDOMElement_get_childNodes(
root, &node_list);
4557 hr = IXMLDOMNodeList_get_length(node_list, &list_length);
4560 ok(list_length == 1,
"list length %ld, expected 1\n", list_length);
4562 hr = IXMLDOMNodeList_get_item(node_list, 0, &
node);
4566 hr = IXMLDOMNode_get_nodeName(
node, &
str);
4574 hr = ISAXContentHandler_characters(
content,
L"12345", 5);
4585 hr = ISAXContentHandler_endElement(
content,
L"", 0,
L"", 0,
L"Number", 6);
4595 IXMLDOMNode_Release(
node);
4599 hr = ISAXContentHandler_startElement(
content,
L"", 0,
L"", 0,
L"Name", 4,
NULL);
4602 hr = ISAXContentHandler_characters(
content,
L"Captain Ahab", 12);
4605 hr = ISAXContentHandler_endElement(
content,
L"", 0,
L"", 0,
L"Name", 4);
4608 hr = ISAXContentHandler_endElement(
content,
L"", 0,
L"", 0,
L"BankAccount", 11);
4611 hr = IXMLDOMNodeList_get_length(node_list, &list_length);
4614 ok(2 == list_length,
"list length %ld, expected 2\n", list_length);
4616 hr = IXMLDOMNodeList_get_item(node_list, 1, &
node);
4620 hr = IXMLDOMNode_get_nodeName(
node, &
str);
4635 IXMLDOMNode_Release(
node);
4636 IXMLDOMNodeList_Release(node_list);
4637 IXMLDOMElement_Release(
root);
4641 hr = ISAXContentHandler_endDocument(
content);
4644 hr = IXMLDOMDocument_createElement(domdoc,
_bstr_(
"TestElement"), &
root);
4646 IXMLDOMElement_Release(
root);
4649 hr = IXMLDOMDocument_get_xml(domdoc, &
str);
4654 "<Number>12345</Number>"
4655 "<Name>Captain Ahab</Name>"
4656 "</BankAccount>\r\n",
4662 IXMLDOMDocument_Release(domdoc);
4663 ISAXContentHandler_Release(
content);
4664 IMXWriter_Release(writer);
4696 &IID_IMXWriter, (
void**)&writer);
4699 hr = IMXWriter_QueryInterface(writer, &IID_ISAXContentHandler, (
void**)&
content);
4702 hr = IMXWriter_put_encoding(writer,
_bstr_(
"UTF-8"));
4705 hr = ISAXContentHandler_startDocument(
content);
4708 hr = ISAXContentHandler_endDocument(
content);
4715 hr = IMXWriter_get_output(writer, &
dest);
4728 hr = IMXWriter_put_output(writer,
dest);
4731 hr = IMXWriter_put_encoding(writer,
_bstr_(
"UTF-8"));
4742 hr = IMXWriter_put_encoding(writer,
_bstr_(
"UTF-16"));
4745 hr = IMXWriter_flush(writer);
4756 hr = IMXWriter_get_encoding(writer, &
s);
4767 char expectedA[200];
4774 hr = IMXWriter_put_output(writer,
dest);
4777 hr = IMXWriter_put_encoding(writer,
_bstr_(enc));
4779 "%s: encoding not accepted\n", enc);
4787 hr = ISAXContentHandler_startDocument(
content);
4790 hr = ISAXContentHandler_endDocument(
content);
4793 hr = IMXWriter_flush(writer);
4798 strcat(expectedA,
"<?xml version=\"1.0\" encoding=\"");
4800 strcat(expectedA,
"\" standalone=\"no\"?>\r\n");
4806 ok(!
strncmp(
ptr, expectedA,
strlen(expectedA)),
"%s: got %s, expected %.50s\n", enc,
ptr, expectedA);
4810 hr = IMXWriter_put_output(writer,
dest);
4818 ISAXContentHandler_Release(
content);
4819 IMXWriter_Release(writer);
4835 hr = IUnknown_QueryInterface(
obj, &IID_IDispatchEx, (
void**)&dispex);
4840 hr = IDispatchEx_GetTypeInfoCount(dispex, &ticnt);
4842 ok(ticnt == 1,
"ticnt=%u\n", ticnt);
4845 hr = IDispatchEx_DeleteMemberByName(dispex,
name, fdexNameCaseSensitive);
4849 hr = IDispatchEx_DeleteMemberByDispID(dispex, dispid);
4853 hr = IDispatchEx_GetMemberProperties(dispex, dispid, grfdexPropCanAll, &
props);
4857 hr = IDispatchEx_GetMemberName(dispex, dispid, &
name);
4865 hr = IDispatchEx_GetNameSpaceParent(dispex, &unk);
4867 ok(unk == (
IUnknown*)0xdeadbeef,
"got %p\n", unk);
4870 hr = IDispatchEx_GetDispID(dispex,
name, fdexNameEnsure, &did);
4874 IDispatchEx_Release(dispex);
4879 IVBSAXXMLReader *vbreader;
4881 DISPPARAMS dispparams;
4888 &IID_ISAXXMLReader, (
void**)&
reader);
4899 IUnknown_Release(unk);
4901 hr = ISAXXMLReader_QueryInterface(
reader, &IID_IVBSAXXMLReader, (
void**)&vbreader);
4903 hr = IVBSAXXMLReader_QueryInterface(vbreader, &
IID_IUnknown, (
void**)&unk);
4906 IUnknown_Release(unk);
4908 dispid = DISPID_PROPERTYPUT;
4909 dispparams.cArgs = 1;
4910 dispparams.cNamedArgs = 1;
4911 dispparams.rgdispidNamedArgs = &dispid;
4912 dispparams.rgvarg = &
arg;
4918 hr = IVBSAXXMLReader_Invoke(vbreader,
4929 hr = IVBSAXXMLReader_Invoke(vbreader,
4940 IVBSAXXMLReader_Release(vbreader);
4941 ISAXXMLReader_Release(
reader);
4948 IUnknown_Release(unk);
4960 &IID_IMXWriter, (
void**)&writer);
4963 hr = IMXWriter_QueryInterface(writer, &IID_IDispatchEx, (
void**)&dispex);
4965 hr = IDispatchEx_QueryInterface(dispex, &
IID_IUnknown, (
void**)&unk);
4967 IUnknown_Release(unk);
4968 IDispatchEx_Release(dispex);
4969 IMXWriter_Release(writer);
4976 IUnknown_Release(unk);
4982 IVBSAXLexicalHandler *vblexical;
4984 ISAXLexicalHandler *lexical;
4990 &IID_IMXWriter, (
void**)&writer);
4993 hr = IMXWriter_QueryInterface(writer, &IID_ISAXContentHandler, (
void**)&
content);
4996 hr = IMXWriter_QueryInterface(writer, &IID_ISAXLexicalHandler, (
void**)&lexical);
4999 hr = IMXWriter_QueryInterface(writer, &IID_IVBSAXLexicalHandler, (
void**)&vblexical);
5002 hr = IMXWriter_put_omitXMLDeclaration(writer, VARIANT_TRUE);
5005 hr = ISAXContentHandler_startDocument(
content);
5008 hr = ISAXLexicalHandler_comment(lexical,
NULL, 0);
5011 hr = IVBSAXLexicalHandler_comment(vblexical,
NULL);
5014 hr = ISAXLexicalHandler_comment(lexical,
L"comment", 0);
5018 hr = IMXWriter_get_output(writer, &
dest);
5024 hr = ISAXLexicalHandler_comment(lexical,
L"comment", 7);
5028 hr = IMXWriter_get_output(writer, &
dest);
5034 ISAXContentHandler_Release(
content);
5035 ISAXLexicalHandler_Release(lexical);
5036 IVBSAXLexicalHandler_Release(vblexical);
5037 IMXWriter_Release(writer);
5043 IVBSAXLexicalHandler *vblexical;
5045 ISAXLexicalHandler *lexical;
5051 &IID_IMXWriter, (
void**)&writer);
5054 hr = IMXWriter_QueryInterface(writer, &IID_ISAXContentHandler, (
void**)&
content);
5057 hr = IMXWriter_QueryInterface(writer, &IID_ISAXLexicalHandler, (
void**)&lexical);
5060 hr = IMXWriter_QueryInterface(writer, &IID_IVBSAXLexicalHandler, (
void**)&vblexical);
5063 hr = IMXWriter_put_omitXMLDeclaration(writer, VARIANT_TRUE);
5066 hr = ISAXContentHandler_startDocument(
content);
5069 hr = ISAXLexicalHandler_startCDATA(lexical);
5073 hr = IMXWriter_get_output(writer, &
dest);
5079 hr = IVBSAXLexicalHandler_startCDATA(vblexical);
5086 hr = ISAXLexicalHandler_endCDATA(lexical);
5090 hr = IMXWriter_get_output(writer, &
dest);
5096 ISAXContentHandler_Release(
content);
5097 ISAXLexicalHandler_Release(lexical);
5098 IVBSAXLexicalHandler_Release(vblexical);
5099 IMXWriter_Release(writer);
5111 &IID_IMXWriter, (
void**)&writer);
5114 hr = IMXWriter_QueryInterface(writer, &IID_ISAXContentHandler, (
void**)&
content);
5120 hr = ISAXContentHandler_processingInstruction(
content,
L"target", 0,
NULL, 0);
5123 hr = ISAXContentHandler_processingInstruction(
content,
L"target", 6,
NULL, 0);
5127 hr = IMXWriter_get_output(writer, &
dest);
5133 hr = ISAXContentHandler_processingInstruction(
content,
L"target", 4,
L"data", 4);
5137 hr = IMXWriter_get_output(writer, &
dest);
5144 hr = IMXWriter_put_output(writer,
dest);
5147 hr = ISAXContentHandler_processingInstruction(
content,
L"target", 6,
L"data", 0);
5151 hr = IMXWriter_get_output(writer, &
dest);
5158 ISAXContentHandler_Release(
content);
5159 IMXWriter_Release(writer);
5170 &IID_IMXWriter, (
void**)&writer);
5173 hr = IMXWriter_QueryInterface(writer, &IID_ISAXContentHandler, (
void**)&
content);
5176 hr = ISAXContentHandler_ignorableWhitespace(
content,
NULL, 0);
5179 hr = ISAXContentHandler_ignorableWhitespace(
content,
L"data", 0);
5182 hr = ISAXContentHandler_ignorableWhitespace(
content,
L"data", 4);
5185 hr = ISAXContentHandler_ignorableWhitespace(
content,
L"data", 1);
5189 hr = IMXWriter_get_output(writer, &
dest);
5195 ISAXContentHandler_Release(
content);
5196 IMXWriter_Release(writer);
5201 IVBSAXLexicalHandler *vblexical;
5203 ISAXLexicalHandler *lexical;
5204 IVBSAXDeclHandler *vbdecl;
5205 ISAXDeclHandler *decl;
5206 ISAXDTDHandler *dtd;
5212 &IID_IMXWriter, (
void**)&writer);
5215 hr = IMXWriter_QueryInterface(writer, &IID_ISAXContentHandler, (
void**)&
content);
5218 hr = IMXWriter_QueryInterface(writer, &IID_ISAXLexicalHandler, (
void**)&lexical);
5221 hr = IMXWriter_QueryInterface(writer, &IID_ISAXDeclHandler, (
void**)&decl);
5224 hr = IMXWriter_QueryInterface(writer, &IID_IVBSAXDeclHandler, (
void**)&vbdecl);
5227 hr = IMXWriter_QueryInterface(writer, &IID_IVBSAXLexicalHandler, (
void**)&vblexical);
5230 hr = IMXWriter_put_omitXMLDeclaration(writer, VARIANT_TRUE);
5233 hr = ISAXContentHandler_startDocument(
content);
5236 hr = ISAXLexicalHandler_startDTD(lexical,
NULL, 0,
NULL, 0,
NULL, 0);
5242 hr = ISAXLexicalHandler_startDTD(lexical,
NULL, 0,
L"pub", 3,
NULL, 0);
5245 hr = ISAXLexicalHandler_startDTD(lexical,
NULL, 0,
NULL, 0,
L"sys", 3);
5248 hr = ISAXLexicalHandler_startDTD(lexical,
NULL, 0,
L"pub", 3,
L"sys", 3);
5251 hr = ISAXLexicalHandler_startDTD(lexical,
L"name", 4,
NULL, 0,
NULL, 0);
5255 hr = IMXWriter_get_output(writer, &
dest);
5262 hr = ISAXLexicalHandler_startDTD(lexical,
L"name", 4,
L"pub", 3,
NULL, 0);
5265 hr = ISAXLexicalHandler_startDTD(lexical,
L"name", 4,
L"pub", 3,
L"sys", 3);
5269 hr = IMXWriter_get_output(writer, &
dest);
5276 hr = ISAXLexicalHandler_endDTD(lexical);
5279 hr = IVBSAXLexicalHandler_endDTD(vblexical);
5283 hr = IMXWriter_get_output(writer, &
dest);
5287 "<!DOCTYPE name PUBLIC \"pub\" \"sys\" [\r\n]>\r\n]>\r\n"),
5293 hr = IMXWriter_put_output(writer,
dest);
5296 hr = ISAXDeclHandler_elementDecl(decl,
NULL, 0,
NULL, 0);
5299 hr = IVBSAXDeclHandler_elementDecl(vbdecl,
NULL,
NULL);
5302 hr = ISAXDeclHandler_elementDecl(decl,
L"name", 4,
NULL, 0);
5305 hr = ISAXDeclHandler_elementDecl(decl,
L"name", 4,
L"content", 7);
5309 hr = IMXWriter_get_output(writer, &
dest);
5317 hr = IMXWriter_put_output(writer,
dest);
5320 hr = ISAXDeclHandler_elementDecl(decl,
L"name", 4,
L"content", 0);
5324 hr = IMXWriter_get_output(writer, &
dest);
5333 hr = IMXWriter_put_output(writer,
dest);
5336 hr = ISAXDeclHandler_attributeDecl(decl,
_bstr_(
"element"),
strlen(
"element"),
5342 hr = IMXWriter_get_output(writer, &
dest);
5345 ok(!
lstrcmpW(
L"<!ATTLIST element attribute CDATA #REQUIRED \"value\">\r\n",
5349 hr = ISAXDeclHandler_attributeDecl(decl,
_bstr_(
"element"),
strlen(
"element"),
5354 hr = ISAXDeclHandler_attributeDecl(decl,
_bstr_(
"element2"),
strlen(
"element2"),
5360 hr = IMXWriter_get_output(writer, &
dest);
5363 ok(!
lstrcmpW(
_bstr_(
"<!ATTLIST element attribute CDATA #REQUIRED \"value\">\r\n"
5364 "<!ATTLIST element attribute2 CDATA #REQUIRED \"value2\">\r\n"
5365 "<!ATTLIST element2 attribute3 CDATA #REQUIRED \"value3\">\r\n"),
5371 hr = IMXWriter_put_output(writer,
dest);
5374 hr = ISAXDeclHandler_internalEntityDecl(decl,
NULL, 0,
NULL, 0);
5377 hr = IVBSAXDeclHandler_internalEntityDecl(vbdecl,
NULL,
NULL);
5380 hr = ISAXDeclHandler_internalEntityDecl(decl,
_bstr_(
"name"), -1,
NULL, 0);
5387 hr = IMXWriter_get_output(writer, &
dest);
5395 hr = IMXWriter_put_output(writer,
dest);
5398 hr = ISAXDeclHandler_externalEntityDecl(decl,
NULL, 0,
NULL, 0,
NULL, 0);
5401 hr = IVBSAXDeclHandler_externalEntityDecl(vbdecl,
NULL,
NULL,
NULL);
5404 hr = ISAXDeclHandler_externalEntityDecl(decl,
_bstr_(
"name"), 0,
NULL, 0,
NULL, 0);
5407 hr = ISAXDeclHandler_externalEntityDecl(decl,
_bstr_(
"name"), -1,
NULL, 0,
NULL, 0);
5422 hr = IMXWriter_get_output(writer, &
dest);
5426 "<!ENTITY name PUBLIC \"pubid\" \"sysid\">\r\n"
5427 "<!ENTITY name SYSTEM \"sysid\">\r\n"),
5433 hr = IMXWriter_QueryInterface(writer, &IID_ISAXDTDHandler, (
void**)&dtd);
5437 hr = IMXWriter_put_output(writer,
dest);
5440 hr = ISAXDTDHandler_notationDecl(dtd,
NULL, 0,
NULL, 0,
NULL, 0);
5455 hr = IMXWriter_get_output(writer, &
dest);
5460 "<!NOTATION name PUBLIC \"pubid\">\r\n"
5461 "<!NOTATION name PUBLIC \"pubid\" \"sysid\">\r\n"
5462 "<!NOTATION name SYSTEM \"sysid\">\r\n"),
5467 ISAXDTDHandler_Release(dtd);
5469 ISAXContentHandler_Release(
content);
5470 ISAXLexicalHandler_Release(lexical);
5471 IVBSAXLexicalHandler_Release(vblexical);
5472 IVBSAXDeclHandler_Release(vbdecl);
5473 ISAXDeclHandler_Release(decl);
5474 IMXWriter_Release(writer);
5497 { &CLSID_SAXAttributes60,
NULL,
"qname",
"ns:qname",
NULL,
"value",
S_OK },
5499 { &CLSID_SAXAttributes,
"uri",
"qname",
"ns:qname",
NULL,
"value",
E_INVALIDARG },
5500 { &CLSID_SAXAttributes30,
"uri",
"qname",
"ns:qname",
NULL,
"value",
E_INVALIDARG },
5501 { &CLSID_SAXAttributes40,
"uri",
"qname",
"ns:qname",
NULL,
"value",
E_INVALIDARG },
5502 { &CLSID_SAXAttributes60,
"uri",
"qname",
"ns:qname",
NULL,
"value",
S_OK },
5504 { &CLSID_SAXAttributes,
"uri",
"qname",
"ns:qname",
"type",
"value",
S_OK },
5505 { &CLSID_SAXAttributes30,
"uri",
"qname",
"ns:qname",
"type",
"value",
S_OK },
5506 { &CLSID_SAXAttributes40,
"uri",
"qname",
"ns:qname",
"type",
"value",
S_OK },
5507 { &CLSID_SAXAttributes60,
"uri",
"qname",
"ns:qname",
"type",
"value",
S_OK },
5517 while (
table->clsid)
5519 ISAXAttributes *saxattr;
5520 IMXAttributes *mxattr;
5533 &IID_IMXAttributes, (
void**)&mxattr);
5536 hr = IMXAttributes_QueryInterface(mxattr, &IID_ISAXAttributes, (
void**)&saxattr);
5543 hr = ISAXAttributes_getLength(saxattr,
NULL);
5548 hr = ISAXAttributes_getLength(saxattr, &
len);
5552 hr = ISAXAttributes_getValue(saxattr, 0, &
value, &
len);
5555 hr = ISAXAttributes_getValue(saxattr, 0,
NULL, &
len);
5558 hr = ISAXAttributes_getValue(saxattr, 0, &
value,
NULL);
5561 hr = ISAXAttributes_getValue(saxattr, 0,
NULL,
NULL);
5564 hr = ISAXAttributes_getType(saxattr, 0, &
value, &
len);
5567 hr = ISAXAttributes_getType(saxattr, 0,
NULL, &
len);
5570 hr = ISAXAttributes_getType(saxattr, 0, &
value,
NULL);
5573 hr = ISAXAttributes_getType(saxattr, 0,
NULL,
NULL);
5586 hr = ISAXAttributes_getValue(saxattr, 0,
NULL, &
len);
5589 hr = ISAXAttributes_getValue(saxattr, 0, &
value,
NULL);
5592 hr = ISAXAttributes_getValue(saxattr, 0,
NULL,
NULL);
5595 hr = ISAXAttributes_getType(saxattr, 0,
NULL, &
len);
5598 hr = ISAXAttributes_getType(saxattr, 0, &
value,
NULL);
5601 hr = ISAXAttributes_getType(saxattr, 0,
NULL,
NULL);
5606 hr = ISAXAttributes_getValue(saxattr, 0, &
value, &
len);
5613 value = (
void*)0xdeadbeef;
5614 hr = ISAXAttributes_getType(saxattr, 0, &
value, &
len);
5626 ok(
len == 0,
"%d: got wrong type value length %d\n",
i,
len);
5629 hr = ISAXAttributes_getIndexFromQName(saxattr,
NULL, 0,
NULL);
5638 hr = ISAXAttributes_getIndexFromQName(saxattr,
NULL, 0, &
index);
5642 hr = ISAXAttributes_getIndexFromQName(saxattr,
_bstr_(
"nonexistent"), 11, &
index);
5664 hr = ISAXAttributes_getValueFromQName(saxattr,
NULL, 0,
NULL,
NULL);
5684 hr = ISAXAttributes_getValueFromQName(saxattr,
NULL, 0,
NULL,
NULL);
5737 hr = ISAXAttributes_getLength(saxattr, &
len);
5740 ok(
len == 1,
"%d: got %d length, expected 1\n",
i,
len);
5742 ok(
len == 0,
"%d: got %d length, expected 0\n",
i,
len);
5744 ISAXAttributes_Release(saxattr);
5745 IMXAttributes_Release(mxattr);
5756 ISAXAttributes *saxattr;
5757 IMXAttributes *mxattr;
5763 &IID_IMXAttributes, (
void**)&mxattr);
5766 hr = IMXAttributes_QueryInterface(mxattr, &IID_ISAXAttributes, (
void**)&saxattr);
5769 hr = ISAXAttributes_getQName(saxattr, 0,
NULL,
NULL);
5772 hr = ISAXAttributes_getQName(saxattr, 0, &
ptr, &
len);
5775 hr = IMXAttributes_clear(mxattr);
5778 hr = IMXAttributes_addAttribute(mxattr,
_bstr_(
"uri"),
_bstr_(
"local"),
5783 hr = ISAXAttributes_getLength(saxattr, &
len);
5788 hr = ISAXAttributes_getQName(saxattr, 0,
NULL, &
len);
5792 ptr = (
void*)0xdeadbeef;
5793 hr = ISAXAttributes_getQName(saxattr, 0, &
ptr,
NULL);
5795 ok(
ptr == (
void*)0xdeadbeef,
"got %p\n",
ptr);
5798 hr = ISAXAttributes_getQName(saxattr, 0, &
ptr, &
len);
5803 hr = IMXAttributes_clear(mxattr);
5807 hr = ISAXAttributes_getLength(saxattr, &
len);
5812 ptr = (
void*)0xdeadbeef;
5813 hr = ISAXAttributes_getQName(saxattr, 0, &
ptr, &
len);
5816 ok(
ptr == (
void*)0xdeadbeef,
"got %p\n",
ptr);
5818 IMXAttributes_Release(mxattr);
5819 ISAXAttributes_Release(saxattr);
5825 IMXAttributes *mxattr;
5831 &IID_IMXAttributes, (
void**)&mxattr);
5834 hr = IMXAttributes_QueryInterface(mxattr, &IID_IDispatchEx, (
void**)&dispex);
5836 hr = IDispatchEx_QueryInterface(dispex, &
IID_IUnknown, (
void**)&unk);
5838 IUnknown_Release(unk);
5839 IDispatchEx_Release(dispex);
5841 IMXAttributes_Release(mxattr);
5846 IMXAttributes *mxattr;
5850 &IID_IMXAttributes, (
void **)&mxattr);
5859 IMXAttributes_Release(mxattr);
5864 { &CLSID_SAXAttributes,
"SAXAttributes" },
5865 { &CLSID_SAXAttributes30,
"SAXAttributes30" },
5866 { &CLSID_SAXAttributes40,
"SAXAttributes40" },
5867 { &CLSID_SAXAttributes60,
"SAXAttributes60" },
5875 while (
table->clsid)
5877 ISAXAttributes *saxattr;
5878 IMXAttributes *mxattr;
5889 &IID_IMXAttributes, (
void**)&mxattr);
5892 hr = IMXAttributes_QueryInterface(mxattr, &IID_ISAXAttributes, (
void**)&saxattr);
5895 hr = ISAXAttributes_getIndexFromName(saxattr,
NULL, 0,
NULL, 0, &
index);
5899 hr = IMXAttributes_addAttribute(mxattr,
_bstr_(
"uri"),
_bstr_(
"localname"),
5902 hr = IMXAttributes_addAttribute(mxattr,
_bstr_(
"uri"),
_bstr_(
"localname"),
5907 hr = ISAXAttributes_getIndexFromName(saxattr,
L"uri", 3,
L"localname", 9, &
index);
5912 hr = ISAXAttributes_getIndexFromName(saxattr,
L"uri1", 4,
L"localname", 9, &
index);
5917 hr = ISAXAttributes_getIndexFromName(saxattr,
L"uri", 3,
L"localname1", 10, &
index);
5924 hr = ISAXAttributes_getIndexFromName(saxattr,
NULL, 0,
NULL, 0,
NULL);
5927 hr = ISAXAttributes_getIndexFromName(saxattr,
L"uri", 3,
L"localname1", 10,
NULL);
5932 hr = ISAXAttributes_getIndexFromName(saxattr,
NULL, 0,
NULL, 0,
NULL);
5935 hr = ISAXAttributes_getIndexFromName(saxattr,
L"uri", 3,
L"localname1", 10,
NULL);
5939 hr = ISAXAttributes_getIndexFromName(saxattr,
L"uri", 3,
NULL, 0, &
index);
5942 hr = ISAXAttributes_getIndexFromName(saxattr,
NULL, 0,
L"localname1", 10, &
index);
5947 ISAXAttributes_Release(saxattr);
5948 IMXAttributes_Release(mxattr);
5963 hr = IMXWriter_put_indent(writer, VARIANT_TRUE);
5966 hr = IMXWriter_QueryInterface(writer, &IID_ISAXContentHandler, (
void**)&
content);
5969 hr = ISAXContentHandler_startDocument(
content);
5993 hr = ISAXContentHandler_endDocument(
content);
5997 hr = IMXWriter_get_output(writer, &
dest);
6000 ok(!
lstrcmpW(
L"<?xml version=\"1.0\" encoding=\"UTF-16\" standalone=\"no\"?>\r\n<a><b>\r\n\t\t<c/>\r\n\t</b>\r\n</a>",
V_BSTR(&
dest)),
6004 ISAXContentHandler_Release(
content);
6005 IMXWriter_Release(writer);
6016 ok(
hr ==
S_OK,
"failed to init com\n");
6019 &IID_ISAXXMLReader, (
void**)&
reader);
6023 win_skip(
"Failed to create SAXXMLReader instance\n");
6027 ISAXXMLReader_Release(
reader);
6061 win_skip(
"MXXMLWriter not supported\n");
6074 win_skip(
"SAXAttributes not supported\n");
int memcmp(void *Buffer1, void *Buffer2, ACPI_SIZE Count)
ACPI_SIZE strlen(const char *String)
int strncmp(const char *String1, const char *String2, ACPI_SIZE Count)
static struct sockaddr_in sa
#define InterlockedIncrement
#define InterlockedDecrement
#define INVALID_HANDLE_VALUE
#define CreateFileA(a, b, c, d, e, f, g)
#define FILE_ATTRIBUTE_NORMAL
#define MultiByteToWideChar
BOOL WINAPI DeleteFileA(IN LPCSTR lpFileName)
BOOL WINAPI WriteFile(IN HANDLE hFile, IN LPCVOID lpBuffer, IN DWORD nNumberOfBytesToWrite OPTIONAL, OUT LPDWORD lpNumberOfBytesWritten, IN LPOVERLAPPED lpOverlapped OPTIONAL)
int WINAPI lstrcmpW(LPCWSTR str1, LPCWSTR str2)
UINT(* handler)(MSIPACKAGE *)
HRESULT WINAPI DECLSPEC_HOTPATCH CoCreateInstance(REFCLSID rclsid, LPUNKNOWN pUnkOuter, DWORD dwClsContext, REFIID iid, LPVOID *ppv)
HRESULT WINAPI CoInitialize(LPVOID lpReserved)
void WINAPI DECLSPEC_HOTPATCH CoUninitialize(void)
HRESULT WINAPI GetHGlobalFromStream(IStream *pstm, HGLOBAL *phglobal)
HRESULT WINAPI CreateStreamOnHGlobal(HGLOBAL hGlobal, BOOL fDeleteOnRelease, LPSTREAM *ppstm)
HRESULT WINAPI SafeArrayAccessData(SAFEARRAY *psa, void **ppvData)
HRESULT WINAPI SafeArrayUnaccessData(SAFEARRAY *psa)
HRESULT WINAPI SafeArrayDestroy(SAFEARRAY *psa)
SAFEARRAY *WINAPI SafeArrayCreate(VARTYPE vt, UINT cDims, SAFEARRAYBOUND *rgsabound)
static unsigned char buff[32768]
GLint GLenum GLsizei GLsizei GLsizei GLint GLsizei const GLvoid * data
GLboolean GLboolean GLboolean b
GLenum GLuint GLenum GLsizei const GLchar * buf
GLuint GLsizei GLsizei * length
GLenum GLenum GLenum input
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble const GLfloat const GLdouble const GLfloat GLint i
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble const GLfloat const GLdouble const GLfloat GLint GLint GLint j
BOOL NTAPI GlobalUnlock(HGLOBAL hMem)
static ERESOURCE GlobalLock
#define todo_wine_if(is_todo)
#define memcpy(s1, s2, n)
static IStream * create_test_stream(void)
static HMODULE MODULEINFO DWORD cb
static HRESULT get_expected_ret(void)
static const mxwriter_write_test * current_write_test
static struct attribute_entry read_test_attrs[]
static struct call_entry xmlspaceattr_test[]
static ISAXAttributes saxattributes
static HRESULT WINAPI contentHandler_startElement(ISAXContentHandler *iface, const WCHAR *uri, int uri_len, const WCHAR *localname, int local_len, const WCHAR *qname, int qname_len, ISAXAttributes *saxattr)
static struct call_entry cdata_test3_alt[]
static struct call_entry attribute_norm[]
static HRESULT WINAPI contentHandler_endDocument(ISAXContentHandler *iface)
static struct call_entry content_handler_test_attributes_alternate_6[]
static ULONG WINAPI isaxerrorHandler_Release(ISAXErrorHandler *iface)
static const struct writer_startendelement2_t writer_startendelement2[]
static BSTR _bstr_(const char *str)
static void test_mxwriter_dispex(void)
static struct call_entry cdata_test[]
static void test_mxattr_qi(void)
static HRESULT WINAPI istream_Commit(IStream *iface, DWORD grfCommitFlags)
static const struct saxreader_props_test_t props_test_data[]
static const char * get_event_name(CH event)
static HRESULT WINAPI isaxattributes_getTypeFromQName(ISAXAttributes *iface, const WCHAR *pQName, int nQName, const WCHAR **pType, int *nType)
static HRESULT WINAPI isaxlexical_QueryInterface(ISAXLexicalHandler *iface, REFIID riid, void **out)
static const char test2_cdata_xml[]
static const char startendelement_noescape_xml[]
static void test_mxwriter_pi(void)
static void test_mxwriter_handlers(void)
static ISAXContentHandler contentHandler
static HRESULT WINAPI contentHandler_skippedEntity(ISAXContentHandler *iface, const WCHAR *name, int len)
static ISAXErrorHandler errorHandler
static const char * encoding_names[]
static struct call_entry content_handler_test_attributes_alt_no_ns[]
static ULONG WINAPI isaxattributes_AddRef(ISAXAttributes *iface)
static ULONG WINAPI istream_Release(IStream *iface)
static HRESULT WINAPI isaxattributes_getLength(ISAXAttributes *iface, int *length)
static void test_mxwriter_flush(void)
static struct msxmlsupported_data_t mxwriter_support_data[]
static const struct mxwriter_props_t mxwriter_default_props[]
static struct call_entry content_handler_testerror[]
static struct msxmlsupported_data_t reader_support_data[]
static const char test3_cdata_xml[]
static void check_interface_(unsigned int line, void *iface_ptr, REFIID iid, BOOL supported)
static void test_saxreader_properties(void)
static const struct enc_test_entry_t encoding_test_data[]
static void test_saxstr(const char *file, unsigned line, BSTR str, const char *expected, BOOL todo, int *failcount)
static void init_saxdeclhandler(struct saxdeclhandler *handler, HRESULT hr)
static void test_mxwriter_properties(void)
static HRESULT WINAPI istream_UnlockRegion(IStream *iface, ULARGE_INTEGER libOffset, ULARGE_INTEGER cb, DWORD dwLockType)
static void test_mxattr_clear(void)
static ULONG WINAPI isaxattributes_Release(ISAXAttributes *iface)
static BSTR alloc_str_from_narrow(const char *str)
static HRESULT WINAPI istream_Write(IStream *iface, const void *pv, ULONG cb, ULONG *pcbWritten)
static ULONG WINAPI contentHandler_AddRef(ISAXContentHandler *iface)
static HRESULT WINAPI contentHandler_endPrefixMapping(ISAXContentHandler *iface, const WCHAR *prefix, int len)
static HRESULT WINAPI isaxerrorHandler_QueryInterface(ISAXErrorHandler *iface, REFIID riid, void **ppvObject)
static struct call_entry cdata_test2_alt[]
static void test_mxwriter_startendelement_batch(const struct writer_startendelement_t *table)
static struct msxmlsupported_data_t mxattributes_support_data[]
static void test_mxwriter_startenddocument(void)
static struct call_entry content_handler_test_attributes_no_prefix[]
static ISAXXMLReader * g_reader
static const char * event_names[EVENT_LAST]
@ CH_PROCESSINGINSTRUCTION
static ULONG WINAPI isaxdecl_Release(ISAXDeclHandler *iface)
static HRESULT WINAPI instream_Read(IStream *iface, void *pv, ULONG cb, ULONG *pcbRead)
static struct call_entry cdata_test3[]
static const CHAR UTF8BOMTest[]
static const struct writer_characters_t writer_characters[]
static HRESULT WINAPI isaxerrorHandler_fatalError(ISAXErrorHandler *iface, ISAXLocator *pLocator, const WCHAR *message, HRESULT hr)
static const mxwriter_stream_test mxwriter_stream_tests[]
#define CONTENT_HANDLER_INDEX
static const CHAR szUtf16BOM[]
static HRESULT WINAPI isaxlexical_endCDATA(ISAXLexicalHandler *iface)
static HRESULT WINAPI contentHandler_characters(ISAXContentHandler *iface, const WCHAR *chars, int len)
static void _expect_ref(IUnknown *obj, ULONG ref, int line)
static struct saxlexicalhandler * impl_from_ISAXLexicalHandler(ISAXLexicalHandler *iface)
static void add_call(struct call_sequence **seq, int sequence_index, const struct call_entry *call)
static struct saxdeclhandler declhandler
static void test_mxwriter_comment(void)
static struct attribute_entry attribute_norm_attrs[]
static HRESULT WINAPI mxstream_Write(IStream *iface, const void *pv, ULONG cb, ULONG *pcbWritten)
static const char attribute_normalize[]
static const char startelement_xml[]
static HRESULT WINAPI istream_Read(IStream *iface, void *pv, ULONG cb, ULONG *pcbRead)
static struct attribute_entry ch_attributes1[]
static void test_mxattr_localname(void)
static int alloced_bstrs_count
static struct call_entry content_handler_test_callback_rets[]
static HRESULT WINAPI isaxattributes_getValue(ISAXAttributes *iface, int index, const WCHAR **value, int *nValue)
static HRESULT WINAPI isaxattributes_getValueFromQName(ISAXAttributes *iface, const WCHAR *pQName, int nQName, const WCHAR **pValue, int *nValue)
static ULONG WINAPI isaxerrorHandler_AddRef(ISAXErrorHandler *iface)
static HRESULT WINAPI isaxattributes_getValueFromName(ISAXAttributes *iface, const WCHAR *pUri, int nUri, const WCHAR *pLocalName, int nLocalName, const WCHAR **pValue, int *nValue)
static void free_bstrs(void)
static HRESULT WINAPI isaxattributes_getIndexFromName(ISAXAttributes *iface, const WCHAR *pUri, int cUriLength, const WCHAR *pLocalName, int cocalNameLength, int *index)
static HRESULT WINAPI contentHandler_ignorableWhitespace(ISAXContentHandler *iface, const WCHAR *chars, int len)
static const char xmlspace_attr[]
static struct attribute_entry xmlspace_attrs[]
static void test_saxreader(void)
static HRESULT WINAPI isaxdecl_internalEntityDecl(ISAXDeclHandler *iface, const WCHAR *pName, int nName, const WCHAR *pValue, int nValue)
static HRESULT WINAPI isaxerrorHandler_ignorableWarning(ISAXErrorHandler *iface, ISAXLocator *pLocator, const WCHAR *pErrorMessage, HRESULT hrErrorCode)
static struct call_entry content_handler_test_attributes_alt_no_prefix[]
static void test_mxwriter_characters(void)
static struct call_entry content_handler_test1[]
static struct call_entry cdata_test_alt[]
static struct call_entry xmlspaceattr_test_alternate[]
static HRESULT WINAPI contentHandler_QueryInterface(ISAXContentHandler *iface, REFIID riid, void **ppvObject)
static const char * feature_names[]
static void init_call_sequences(struct call_sequence **seq, int n)
static HRESULT WINAPI istream_Revert(IStream *iface)
static void test_mxattr_addAttribute(void)
static struct attribute_entry ch_attributes_alt_no_ns[]
static const char startendelement_xml[]
static struct saxdeclhandler * impl_from_ISAXDeclHandler(ISAXDeclHandler *iface)
static const WCHAR carriage_ret_test[]
static struct call_entry content_handler_test_callback_rets_alt[]
static HRESULT WINAPI istream_Seek(IStream *iface, LARGE_INTEGER dlibMove, DWORD dwOrigin, ULARGE_INTEGER *plibNewPosition)
static HRESULT WINAPI isaxdecl_QueryInterface(ISAXDeclHandler *iface, REFIID riid, void **out)
static const char test_cdata_xml[]
static HRESULT WINAPI contentHandler_startPrefixMapping(ISAXContentHandler *iface, const WCHAR *prefix, int prefix_len, const WCHAR *uri, int uri_len)
static void test_mxwriter_startendelement_batch2(const struct writer_startendelement2_t *table)
struct mxwriter_stream_test_t mxwriter_stream_test
static const addattribute_test_t addattribute_data[]
static void test_mxwriter_encoding(void)
static const ISAXLexicalHandlerVtbl SAXLexicalHandlerVtbl
static LONG get_refcount(void *iface)
static struct call_entry * expectCall
static HRESULT WINAPI contentHandler_putDocumentLocator(ISAXContentHandler *iface, ISAXLocator *pLocator)
static HRESULT WINAPI isaxattributes_getQName(ISAXAttributes *iface, int index, const WCHAR **QName, int *QNameLength)
#define ok_sequence(seq, index, exp, contx, todo)
static struct msxmlsupported_data_t saxattr_support_data[]
static HRESULT WINAPI isaxattributes_getType(ISAXAttributes *iface, int nIndex, const WCHAR **pType, int *pTypeLength)
static const CHAR szUtf8XML[]
static ULONG WINAPI istream_AddRef(IStream *iface)
static ISAXLocator * locator
static struct call_entry content_handler_test2[]
static const WCHAR szUtf16XML[]
static void ok_sequence_(struct call_sequence **seq, int sequence_index, const struct call_entry *expected, const char *context, BOOL todo, const char *file, int line)
static struct saxlexicalhandler lexicalhandler
static const IStreamVtbl instreamVtbl
static void test_mxwriter_stream(void)
static ULONG WINAPI isaxlexical_Release(ISAXLexicalHandler *iface)
static HRESULT WINAPI isaxlexical_endDTD(ISAXLexicalHandler *iface)
static struct call_entry attribute_norm_alt[]
static struct attribute_entry ch_attributes_alt_6[]
static HRESULT WINAPI isaxattributes_QueryInterface(ISAXAttributes *iface, REFIID riid, void **ppvObject)
static HRESULT WINAPI istream_Clone(IStream *iface, IStream **ppstm)
static HRESULT WINAPI isaxattributes_getName(ISAXAttributes *iface, int nIndex, const WCHAR **pUri, int *pUriLength, const WCHAR **pLocalName, int *pLocalNameSize, const WCHAR **pQName, int *pQNameLength)
static const ISAXContentHandlerVtbl contentHandlerVtbl
static HRESULT WINAPI isaxdecl_elementDecl(ISAXDeclHandler *iface, const WCHAR *pName, int nName, const WCHAR *pModel, int nModel)
static const ISAXErrorHandlerVtbl errorHandlerVtbl
static void test_saxreader_features(void)
static void test_saxreader_encoding(void)
#define EXPECT_REF(obj, ref)
static HRESULT WINAPI isaxattributes_getIndexFromQName(ISAXAttributes *iface, const WCHAR *pQName, int nQNameLength, int *index)
static const char utf8xml2[]
struct mxwriter_write_test_t mxwriter_write_test
static void test_mxwriter_ignorablespaces(void)
#define NUM_CALL_SEQUENCES
static BSTR alloced_bstrs[512]
static HRESULT WINAPI isaxlexical_startDTD(ISAXLexicalHandler *iface, const WCHAR *pName, int nName, const WCHAR *pPublicId, int nPublicId, const WCHAR *pSystemId, int nSystemId)
static struct call_entry content_handler_testerror_alternate[]
static const IStreamVtbl mxstreamVtbl
static struct call_entry content_handler_test1_alternate[]
static void test_mxwriter_indent(void)
static void init_saxlexicalhandler(struct saxlexicalhandler *handler, HRESULT hr)
static void get_class_support_data(struct msxmlsupported_data_t *table, REFIID riid)
static ULONG WINAPI isaxdecl_AddRef(ISAXDeclHandler *iface)
static HRESULT WINAPI istream_QueryInterface(IStream *iface, REFIID riid, void **ppvObject)
static ULONG WINAPI isaxlexical_AddRef(ISAXLexicalHandler *iface)
static HRESULT WINAPI contentHandler_endElement(ISAXContentHandler *iface, const WCHAR *uri, int uri_len, const WCHAR *localname, int local_len, const WCHAR *qname, int qname_len)
static HRESULT WINAPI isaxattributes_getLocalName(ISAXAttributes *iface, int nIndex, const WCHAR **pLocalName, int *pLocalNameLength)
static HRESULT WINAPI isaxattributes_getTypeFromName(ISAXAttributes *iface, const WCHAR *pUri, int nUri, const WCHAR *pLocalName, int nLocalName, const WCHAR **pType, int *nType)
static struct attribute_entry ch_attributes2[]
static struct call_entry content_handler_test2_alternate[]
static HRESULT WINAPI contentHandler_processingInstruction(ISAXContentHandler *iface, const WCHAR *target, int target_len, const WCHAR *data, int data_len)
static HRESULT WINAPI isaxerrorHandler_error(ISAXErrorHandler *iface, ISAXLocator *pLocator, const WCHAR *pErrorMessage, HRESULT hrErrorCode)
static void test_mxwriter_startendelement(void)
static HRESULT WINAPI istream_CopyTo(IStream *iface, IStream *pstm, ULARGE_INTEGER cb, ULARGE_INTEGER *pcbRead, ULARGE_INTEGER *plibWritten)
static void init_call_entry(ISAXLocator *locator, struct call_entry *call)
#define check_interface(a, b, c)
static const struct writer_startendelement_t writer_startendelement[]
static HRESULT WINAPI isaxdecl_attributeDecl(ISAXDeclHandler *iface, const WCHAR *pElementName, int nElementName, const WCHAR *pAttributeName, int nAttributeName, const WCHAR *pType, int nType, const WCHAR *pValueDefault, int nValueDefault, const WCHAR *pValue, int nValue)
static struct attribute_entry ch_attributes_no_prefix[]
static HRESULT WINAPI isaxdecl_externalEntityDecl(ISAXDeclHandler *iface, const WCHAR *pName, int nName, const WCHAR *pPublicId, int nPublicId, const WCHAR *pSystemId, int nSystemId)
static HRESULT WINAPI isaxattributes_getURI(ISAXAttributes *iface, int nIndex, const WCHAR **pUrl, int *pUriSize)
static void test_saxreader_dispex(void)
static unsigned int current_stream_test_index
static void test_mxwriter_dtd(void)
static const WCHAR szSimpleXML[]
static struct attribute_entry ch_attributes2_6[]
static void test_mxwriter_domdoc(void)
static struct call_entry read_test_seq[]
static const char test_attributes[]
static struct call_entry cdata_test2[]
static void test_mxwriter_default_properties(const struct mxwriter_props_t *table)
static HRESULT WINAPI istream_SetSize(IStream *iface, ULARGE_INTEGER libNewSize)
static void test_mxwriter_cdata(void)
static HRESULT WINAPI contentHandler_startDocument(ISAXContentHandler *iface)
static struct call_sequence * sequences[NUM_CALL_SEQUENCES]
static struct attribute_entry ch_attributes_alt_4[]
static HRESULT WINAPI istream_LockRegion(IStream *iface, ULARGE_INTEGER libOffset, ULARGE_INTEGER cb, DWORD dwLockType)
static void compare_attributes(const struct call_entry *actual, const struct call_entry *expected, const char *context, BOOL todo, const char *file, int line, int *failcount)
static void test_obj_dispex(IUnknown *obj)
static HRESULT WINAPI istream_Stat(IStream *iface, STATSTG *pstatstg, DWORD grfStatFlag)
static const ISAXAttributesVtbl SAXAttributesVtbl
static HRESULT WINAPI isaxlexical_startCDATA(ISAXLexicalHandler *iface)
static HRESULT WINAPI isaxlexical_comment(ISAXLexicalHandler *iface, const WCHAR *pChars, int nChars)
static struct call_entry content_handler_test_attributes_alternate_4[]
static void set_expected_seq(struct call_entry *expected)
static BOOL is_clsid_supported(const GUID *clsid, const struct msxmlsupported_data_t *table)
static void test_mxattr_dispex(void)
static const ISAXDeclHandlerVtbl SAXDeclHandlerVtbl
static const struct feature_ns_entry_t feature_ns_entry_data[]
static struct call_entry content_handler_test_attributes[]
static const char testXML[]
static ULONG WINAPI contentHandler_Release(ISAXContentHandler *iface)
static HRESULT WINAPI isaxlexical_startEntity(ISAXLexicalHandler *iface, const WCHAR *pName, int nName)
static HRESULT WINAPI isaxlexical_endEntity(ISAXLexicalHandler *iface, const WCHAR *pName, int nName)
static ISAXAttributes * test_attr_ptr
#define cmp(status, error)
static VARIANTARG static DISPID
#define DISPID_SAX_XMLREADER_GETFEATURE
#define DISPID_SAX_XMLREADER_CONTENTHANDLER
const struct _GUID CLSID_DOMDocument
BSTR WINAPI SysAllocString(LPCOLESTR str)
UINT WINAPI SysStringLen(BSTR str)
void WINAPI DECLSPEC_HOTPATCH SysFreeString(BSTR str)
BSTR WINAPI SysAllocStringLen(const OLECHAR *str, unsigned int len)
#define DISPATCH_PROPERTYPUT
#define DISPATCH_PROPERTYPUTREF
const GUID IID_IPersistStream
#define IsEqualGUID(rguid1, rguid2)
static __inline const char * wine_dbgstr_guid(const GUID *id)
struct attribute_entry * attributes
struct call_entry * sequence
VARIANT_BOOL disable_escape
mxwriter_write_test expected_writes[4]
ISAXDeclHandler ISAXDeclHandler_iface
ISAXLexicalHandler ISAXLexicalHandler_iface
Character const *const prefix
#define CONTAINING_RECORD(address, type, field)
HRESULT WINAPI DECLSPEC_HOTPATCH VariantClear(VARIANTARG *pVarg)
static const WCHAR props[]
wchar_t tm const _CrtWcstime_Writes_and_advances_ptr_ count wchar_t ** out
DWORD WINAPI GetLastError(void)
#define DISP_E_UNKNOWNNAME
ActualNumberDriverObjects * sizeof(PDRIVER_OBJECT)) PDRIVER_OBJECT *DriverObjectList