Difference Between XML Schema and DTD -

XML Schema vs DTD

XML stands for EXtensible Markup Language. It is defined in the XML 1.0 specification, which is developed by the W3C (World Wide Web Consortium). XML provides a standard way, which is also simple, to encode data and text such that the content could be exchanged across driver hardware, operating systems and applications with little human intervention. XML Schema describes the structure of a XML document. XML schema imposes constraints on the structure and the content of a XML document in addition to the syntactical rules that should be followed in XML. XML schema is a recommendation provided by World Wide Web Consortium (W3C) and it became a recommendation in May, 2001. DTD (Document Type Definition) also defines how the elements of document are ordered and nested, what elements are included in the document and the attributes of the included elements. DTD defines the structure of documents in SGML-family markup languages.

What is XML Schema?

XML schema describes the structure of a XML document. It defines the elements that can appear in a XML document and their attributes such as whether an element is empty or whether it can contain text. It also defines what elements would be child elements and the order of the child elements. Further, XML schema defines data types used in elements and their attributes. XML schemas are widely used in web applications since it is extensible and provides support for data types and name spaces. Biggest strength with XML schema is providing support for data types. It provides easy methods to define the content allowed in a document and methods to ensure the correctness of data. Furthermore, XML schema has provisions to work with data in databases and allows conversion between data types.

What is DTD?

DTD defines the structure of documents in SGML-family markup languages such as SGML, XML, and HTML. It defines how the elements of documents are ordered and nested, what elements are included in the documents and the attributes of the included elements. In a XML document, DTD is declared in a DOCTYPE declaration, which is beneath the XML declaration. The body of the DTD holds the definitions for the elements in the document and their attributes and it can be defined as an inline definition or an external definition. Having an external DTD is very useful when you use XML protocol to communicate between separate systems since it reduces the overhead of resending the DTD each time as with inline definition. The external DTD could be placed in a place like a web server that could be accessed by both the systems.

What is the difference between XML Schema and DTD?

DTD is the predecessor of XML schema. While DTD provides the basic structure/grammar for defining a XML document, in addition to that XML schema provides methods to define constraints on the data contained in the document. Therefore XML schema is considered to be richer and powerful than DTD. Also, XML schema provides an object oriented approach for defining the structure of a XML document. But since XML schema is a new technology, some XML parsers do not support it yet. Furthermore, most of rich and complex definitions of legacy systems are defined with DTD. So rewriting them would not be an easy task.

Key Difference – Pleural Effusion vs Pneumonia   Pleural effusion and pneumonia are two conditions that affect our respiratory system. Pleural effusion is actually a complication of many illnesses that directly or indirectly exert an adverse impact on the airways and lung parenchyma whereas pneumonia is one such illness that can give rise to pleural effusion. This is the key difference between these two. Medically pleural effusion can be defined as an excessive accumulation of fluid in the pleural space is known as a pleural effusion. On the other hand, pneumonia can be defined as the invasion of lung parenchyma by microorganisms. CONTENTS 1. Overview and Key Difference 2. What is Pleural Effusion 3. What is Pneumonia 4. Similarities Between Pleural Effusion and Pneumonia 5. Side by Side Comparison – Pleural Effusion vs Pneumonia in Tabular Form 6. Summary What is Pleural Effusion? An excessive accumulation of fluid in the....... READ

HP webOS vs Android HP webOS and Android are commonly known mobile operating systems. HP webOS is owned by HP while Android is distributed as free and open source software. Android platform is developed in collaboration with Google, Inc. and members of Open Handset Alliance. HP webOS was initially introduced in 2009, while Android was initially released in 2008. Today, Android stands as the best selling mobile operating system in the world. Following is a review of the two operating systems considering their difference and similarity. HP webOS HP webOS is a Linux based proprietary mobile operating system initially developed by Palm, Inc. and later owned by HP. The webOS allows applications to be developed using web technologies and hence has acquired the prefix “web”. Initially, webOS has organized the applications using a concept termed ‘cards’; all open applications can be moved in and out of the screen by swipe.......READ

Be the first to comment

Leave a Reply

Your email address will not be published.