New features in the MSXML4.0 version _ Thieves/Collection

Source: Internet
Author: User
Tags html page object model versions xml parser xpath xsl xslt xslt processor
New features in the MSXML4.0 version

New features in Microsoft XML Core Services (MSXML) version 4.0, released in September 2001
Microsoft Corporation
October 2001

To download MSXML 4.0, the URL is MSDN Downloads (English).

Summary: This article focuses on new features and important changes in Microsoft XML Core Services (MSXML) version 4.0, published in September 2001, as compared to version 3.0.

Directory

Brief introduction
New features
Parallel functionality and delete substitution mode
Important Notes

Brief introduction
The first change you will notice is the full new full name of MSXML. Initially, MSXML is the component that provides XML parsing, so its full name is Microsoft®xml Parser. With time migrating, XML and MSXML are evolving. MSXML now offers far more functionality than is analyzed. Since the release of version 3.0, the name has been changing, it is now said to be done. The new name, Microsoft®xml Core Services, fully illustrates the new functionality provided by the component. Note that the initials of the name are still the same as before: MSXML.

The September 2001 release of Microsoft XML Core Services (MSXML) version 4.0 is the official release of MSXML 4.0. This release offers many important new features, as well as some important changes, especially in parallel capabilities. MSXML 4.0 also provides solutions to known problems, improves performance, consistency, and documentation, and provides additional examples.

Compared to version 3.0, MSXML 4.0 provides improvements and additional functionality that mainly covers the following three areas:

Extended support for the final world Wide Web Consortium XML Schema (XSD) recommendation.
A great improvement in performance.
Extended support for continuous XML processing structures based on the actual standard simple API for XML (SAX2).
Another significant change was the deletion of the substitution pattern. MSXML version 4.0 and subsequent versions will be installed strictly in parallel mode. This means that version-independent ProgIDs will no longer be supported, and the existing microsoft®internet Explorer version will not automatically use MSXML 4.0 (if there are no scripts). The reason for this change is that, depending on customer feedback, a stand-alone version of ProgIDs can cause many problems when maintaining an application using MSXML version 2.6 and subsequent versions.

The Serverxmlhttprequest object, introduced in MSXML 3.0, provides reliable server-side HTTP access (independent of WinInet). The server-side HTTP stack feature now contains the new WinHTTP 5.0 component (rolled out with MSXML 4.0 installation). Serverxmlhttprequest only provides front-end for this component.

For new features in the Microsoft XML Parser (MSXML) 4.0 Technology Preview, published in July 2001, see What's New in the July 2001 Microsoft XML Parser 4.0 B2 Te Chnology Preview (English). For more information about all the features of MSXML 4.0, see the documentation that came with the component.

New features
XML Schema Support
Many of the features in this release provide XML schema support. You can use external schema caching or Xsi:schemalocation/xsi:nonamespaceschemalocation properties to validate XML against XML Schemas in SAX and DOM. Although there is no XPath 2.0, MSXML 4.0 can provide extended functionality (conforming to the standard) to support the processing of XSD types in XPath and XSLT.

MSXML 4.0 also allows you to use type discovery in SAX with the schema Object Model (SOM) in the DOM to obtain schema information from the validated document. In addition to the recommended support for the final XML schema, MSXML continues to support Xml-data reduced (XDR) and document type definition validation.

Performance improvements
In addition, MSXML 4.0 provides a new, faster XML analyzer and a significantly improved XSLT engine. The DOM and the new analyzer can be used together by setting the Newparser property to True.

The new analyzer cannot support asynchronous DOM loading or DTD validation. In addition, all other features are the same as the old analyzer, but faster. In Tests, MSXML performs twice times more than the analysis, and if XSLT transforms, the performance is 4 times times higher.

Extended support for continuous XML processing
MSXML 4.0 provides extended support for continuous XML processing structures based on the SAX2 API. Includes the following areas:

Integration of DOM and SAX analysis models
Ability to generate HTML output
The ability to insert a SAX content handler into the output of an XSLT processor
Trace namespace declaration
You can now use the MXXMLWriter object to generate SAX events from the DOM tree. Similarly, you can create a DOM tree from a SAX event. This feature allows you to tightly integrate DOM and SAX into your application.

Mxhtmlwriter, this new object allows you to output HTML with SAX events in the same way that the elements in <xsl:output>xslt generate HTML from the result tree. The new Mxhtmlwriter object provides the necessary support for the performance of Active Server Pages (ASP), which allows the ASP to read XML documents, place them in a custom sax filter, and export the data to the user as an HTML page. Mxhtmlwriter objects can also be used in many other applications, such as manually generating HTML pages.

The XSLT processor now accepts SAX content handlers as output. This means that the SAX filter chain can directly process the converted XML. For example, you can use this feature to delete XML for further generation and analysis so that an XML document can be consumed by an application immediately when the incoming XML document needs to be translated into the same dictionary.

The new Mxnamespacemanager object allows you to manually track a namespace declaration and parse it in the context of the current context or a DOM node. Although MSXML supports namespaces and can automatically resolve the names of elements and attributes, in many cases, property values or element content use qualified names. The new Mxnamespacemanager object is able to track and resolve these qualified names.

Parallel functionality and delete substitution mode
Remove alternate mode
Until MSXML version 3.0, you can use alternative mode to make the latest MSXML component simulate MSXML 2.0 (Internet Explorer 5.0 and 5.5 to demonstrate XML when browsing). This can be done because there is a special utility, Xmlinst.exe, that manipulates Microsoft Windows® registrations. While alternative mode is not a recommended method, many users still try to use it, and the results, based on Microsoft customer support surveys, find many problems in maintaining applications. In addition, you need to maintain the old functionality and make the MSXML component exceed its original component.

Alternative mode is now completely removed from MSXML 4.0, and you cannot use MSXML 2.0 instead of Internet Explorer in alternative mode. This means that if you open an XML file with Internet Explorer as your default program, and then double-click the XML document, Internet Explorer will not display the document using MSXML 4.0来. You can still use MSXML 4.0 in traditional ways, using scripts to manipulate XML in HTML pages.

Delete Version Independent ProgIDs
For the same reason, version independent ProgIDs has been deleted. The deletion was to provide a true parallel installation, whereas in previous releases only certain ProgIDs were upgraded when the new MSXML version was installed. Now CreateObject ("MSXML2.") DOMDocument ") instantiation is not the MSXML 4.0 DOM, but the previous version. If you want to use MSXML 4.0, you must create the following objects: CreateObject (MSXML2. Domdocument.4.0 "). Therefore, you should create "MSXML2" for C + + and Microsoft Visual basic®. DOMDOCUMENT40 ". If you want to use MSXML version 4.0, all other MSXML objects have similar changes.

This is because you want to improve the maintainability of your code, and the previous design is prone to errors as long as the environment changes unexpectedly. In short, a version-independent ProgIDs is very handy for beta MSXML, but in a production environment, the risk is extremely high. For example, the user developed the code using a version independent ProgIDs and assumed that MSXML 3.0 does exist. If you later install or reinstall Microsoft SQL Server™, you may be surprised to find that they are using MSXML 2.6 instead of MSXML 3.0. Removing version-independent ProgIDs from MSXML 4.0 eliminates this instability and improves MSXML to make it a server-side enterprise component.

Delete old code
This version discards many of the old features. Because of the substitution mode, most of the functionality is no longer needed. The features that have been cleared include:

Legacy, inconsistent XSL is now completely superseded by the W3 Standard XSLT 1.0. The full XSLT 1.0 is ready to use since MSXML 3.0.
The old-style, Xslpattern language is now completely replaced by the W3 standard of XPAHT 1.0. The full XPath 1.0 is ready to use since MSXML 3.0.
Legacy, Non-uniform XDR primary uuid:namespaces. The correct namespaces supported by old XDR are now HTTP based namespaces: Urn:schemas-microsoft-com:xml-data and Urn:schemas-microsoft-com:datatype.
The old, non-standard Nodefactory interface was demoted in MSXML 3.0. This interface is used for XML continuous parsing. It has been completely replaced by the SAX2 analysis program. Since MSXML 3.0, the SAX2 Analyzer can be used.
The Normalize-line-break feature now has no effect on the SAX parser. By the XML specification, the break is fully normalized.
Parallel functionality
When the final version of MSXML 4.0 is launched, its DLL name (Msxml4.dll, Msxml4r.dll, and Msxml4a.dll) is identical to the preview version. By removing version independent ProgIDs, MSXML 4.0 is guaranteed to not interfere with previously installed MSXML (2.0, 2.6, or 3.0). Windows XP is installed in parallel for Windows XP users to do more thoroughly. That is, Windows XP can use special parallelism to manage the way your application uses MSXML and the version you use (from 4.0 later). To do this, you must create a special application declaration to link the application to a specific version of MSXML 4.0. For more information, see Microsoft XML Parser 4.0 B2 and Windows XP (English). If you want to use MSXML in the same way that you used it in the past, you don't have to do anything; MSXML is installed on Windows XP both globally (as before) and in parallel (new) mode.

Standalone WinHTTP version 5.0 components
The functionality of the ServerHTTPRequest component is now provided by an independent WinHTTP component. This is a new server-side component that provides reliable HTTP stack functionality. Without the WinHTTP component, ServerHTTPRequest and Dom/sax using server-side mode will not be able to access HTTP based data. If you install MSXML 4.0 on a computer running Windows nt®/2000/xp OS, the WinHTTP component is automatically installed. However, unlike Windows 98/me, WinHTTP cannot run on such a system. You can still install MSXML on Windows 98 or Windows Me, but you must use the default Dom/sax mode, or use the XMLHttpRequest object of the WinInet component to provide HTTP functionality. The WinInet component has been preinstalled with Internet Explorer on these versions of Windows.

This release delivers lighter, faster, and more consistent XML processing components that users can safely use in an enterprise-class system server environment. As long as you ensure that the required components are installed on the client computer, MSXML 4.0 can still be successfully used for environment-control-appropriate clients (as in the case of non-thin clients).

Important Notes
If MSXML 4.0 previews (April or July MSXML 4.0 Technology Preview version) is installed
can still support direct upgrades from Technology Preview to RTM. You must uninstall the preview version before installing RTM. You may need to manually unregister and remove Msxml4*.dll files from the system32 directory. To unregister the MSXML 4.0 preview, run:

Regsvr32/u Msxml4.dll

If the MSXML 4.0 Technical Preview version of MSXML 4.0 was installed in April
Note that version-independent ProgIDs has been removed from MSXML 4.0 (although it still exists in releases released in April), so installing this version will make them unusable. This can also seriously affect many applications that use MSXML 3.0, such as the Microsoft Visual studio®.net installer. To avoid this problem, run the following two commands from the command line and remove the Msxml4*.dll file from the system32 directory before you install this version.

Regsvr32/u Msxml4.dll
regsvr32 msxml3.dll

This ensures that the version-independent ProgIDs points to MSXML 3.0. Be sure to do this before you install this version. If there is no Regsvr32.exe on your computer, you can download it from here (in English). If you have installed a version released since April, ask the newsgroup for help. Again, you may need to manually remove the Msxml4*.dll file from the system32 directory.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.