niit pre xml

Upload: sumit-sharma

Post on 07-Apr-2018

231 views

Category:

Documents


0 download

TRANSCRIPT

  • 8/4/2019 Niit Pre XML

    1/19

  • 8/4/2019 Niit Pre XML

    2/19

    XML was designed to transport and storedata.HTML was designed to display data.

  • 8/4/2019 Niit Pre XML

    3/19

    XML stands for Extensible Markup Language.XML is a markup language much like HTML.

    XML was designed to carry data, not to display data.

    XML tags are not predefined. You must define your owntags.

    XML is designed to be self-descriptive.

    XML is a W3C Recommendation.

  • 8/4/2019 Niit Pre XML

    4/19

    XML and HTML were designed

    with different goalsXML was designed to transport and store

    data, with focus onwhat data is.

    HTML was designed to display data, with

    focus on how data

    looks.HTML is about displaying information, while XML

    is about carrying information. XML is not a

    replacement for HTML.

  • 8/4/2019 Niit Pre XML

    5/19

    Maybe it is a little hard to understand, but XML does not DO anything.

    XML was created to structure, store, and transport information.

    XML is Just Plain Text

    XML is nothing special. It is just plain text. Software that can handle plain textcan also handle XML.

    With XML You Invent Your Own Tags

    The tags in the example above (like and ) are not defined in anyXML standard. These tags are "invented" by the author of the XML document

    That is because the XML language has no predefined tags.

  • 8/4/2019 Niit Pre XML

    6/19

    XML is a complement to HTMLIt is important to understand that XML is not a replacement forHTML.

    In most web applications, XML is used to transport data, whileHTML is used to format and display the data.

    EG:- XML is a software- and hardware-independent tool forcarrying information.

  • 8/4/2019 Niit Pre XML

    7/19

    Clean Semantics -Any query languagefor XML must be able to express simple queries

    simply. A good XML query language should be

    usable by novice web-users, not just databaseexperts.

    SELECT expr

    FROM path

    WHERE condOne possibility for a cleansemantics is to base the query language upon

    the SQL select-from-wherestatement.

  • 8/4/2019 Niit Pre XML

    8/19

    Path Expressions Since XML elements often contain childelements, the query language shouldsupport "path expressions," which allow the

    writer easy access to nested elements.

  • 8/4/2019 Niit Pre XML

    9/19

    Ability to Return an XMLDocumentThe standard behavior of most query languages is

    to return a set of elements of some type.

    For an XML query language the returned valueshould be an XML document

  • 8/4/2019 Niit Pre XML

    10/19

    Ability to Query and Return XMLTags and Attributes -An XML data element contains data, a tag, and

    optionally, attributes. It is imperative that an XML

    query language be able to query the element tagsand attributes as well as the data.

  • 8/4/2019 Niit Pre XML

    11/19

    Intelligent Type Coercion Since both textual and numeric data are

    represented as strings in XML, the query language

    should be intelligent enough in comparisonoperations to determine whether a stringcomparison is intended or if a coercion isrequired.

  • 8/4/2019 Niit Pre XML

    12/19

    Handle Unexpected Data Data in XML does not have to conform to a fully-

    structured DTD. Therefore, it is critical that an XML

    query language "do the right thing" in the face ofunexpected data as much as possible.

  • 8/4/2019 Niit Pre XML

    13/19

    Allow Queries When the DTD IsNot Fully Known It may often be the case with XML that the query

    writer understands a part of the DTD, but not in itsentirety. The query language needs to support

    wildcards in the path expressions to allow thequery writer to "skip past" parts of the documentstructure of which he or she is not aware.

  • 8/4/2019 Niit Pre XML

    14/19

    Return Unnamed Attributes In restructuring information it is often useful to

    express things like "return all child elements," or

    "return all child elements except this one." An XMLquery language should support queries that returnelements even when their tags are unknown

  • 8/4/2019 Niit Pre XML

    15/19

    Return Trees Instead of Sets-Although query languages usually return sets, when

    restructuring an XML document it is likely that the user

    will want to have the query return a more nestedstructure.

  • 8/4/2019 Niit Pre XML

    16/19

    Preserve Order SGML documents have an implicit order, and XML

    documents do as well. It is important for an XML

    query language to be able to optionally guaranteethat the order of returned results is the same as in

    the original document.

  • 8/4/2019 Niit Pre XML

    17/19

    It is as easy as HTML.

    XML is fully compatible with applications likeJAVA, and it can be combined with anyapplication which is capable of processing XML

    irrespective of the platform it is being used on. XML is an extremely portable language to the

    extent that it can be used on large networks withmultiple platforms like the internet, and it can be

    used on handhelds or palmtops or PDAs. XML is an extendable language, meaning that

    you can create your own tags, or use the tagswhich have already been created

  • 8/4/2019 Niit Pre XML

    18/19

    It is a platform independent language

    It can be deployed on any network if it is amicablefor usage with the application in use

    If the application can work along with XML, thenXML can work on any platform and has noboundaries

    It is also vendor independent and systemindependent. While data is being exchanged usingXML, there will be no loss of data even betweensystems that use totally different formats.

  • 8/4/2019 Niit Pre XML

    19/19