XML

Responsive image
0 Comments         3196 Views

To Learn XML, you must know about the markup Language.

Markup Language: A markup language is a computer language that uses tags to define elements within a document. Ex: of tags <Br>,<H1>,<HEAD>; Every Tags has define documentation.

XML: Extensible Markup Language (XML) allows you to describe and organize information in ways that are easily understandable by both humans and computers. You can then share that information and its description with others over the Internet, an extranet, network, or in other ways.

XML derived from Standard Generalised Markup language. Standard Generalized Markup Language (SGML), is a metalanguage. A metalanguage allows you to define a document markup language and its structure. For example, both XML and Hypertext Markup Language (HTML) are derived from SGML.

It is easy to scalable and simple to develop. In Android XML is use to implement UI related data and it is a light weight language that does not make layout heavy. XML only contains tags when implementing need to call the tag.

Types of XML Files:

1.    Layout XML Files.

2.    Android Manifest XML Files.

3.    Strings XML Files.

4.    Themes XML Files.

5.    Drawable XML Files.

6.    Colors XML Files.

7.    Dimens XML Files.  

Why XML Use For?

Xml is a simple text-based format for representing structured information.There are various use of xml in multiple platform like Portable application, e-business and web. Also xml allows you to create interactive pages.

Use of xml is:

  1. Web Publishing : User can create and customize interactive web page.
  2. web Task : web searching and automatic search.
  3. General applications: All kinds of applications can benefit from XML as it offers a streamlined method of accessing information.
  4. e-business applications: XML implementations make electronic data interchange (EDI) more accessible for information interchange, business-to-business transactions, and business-to-consumer transactions.
  5. Metadata applications: XML makes it easier to express metadata in a portable, reusable format.
  6. Pervasive computing: XML provides portable and structured information types for display on pervasive (wireless) computing devices such as cellular phones.

Advantage of XML:

  1. XML is completely compatible with Java and 100% portable.
  2. XML is extendable.
  3. XML uses human, not computer, language. XML is readable and understandable.
  4. It supports Unicode, allowing almost any information in any written human language to be communicated.
  5. It can represent common computer science data structures: records, lists, and trees.
  6. Its self-documenting format describes structure and field names as well as specific values.
  7. The strict syntax and parsing requirements make the necessary parsing algorithms extremely simple, efficient, and consistent.
  8. XML is heavily used as a format for document storage and processing, both online and offline.
  9. It is based on international standards.
  10. It can be updated incrementally.

Disadvantage of XML:

  1. XML syntax is redundant or large relative to binary representations of similar data, especially with tabular data.
  2. The redundancy may affect application efficiency through higher storage, transmission and processing costs
  3.  XML syntax is verbose, especially for human readers, relative to other alternatives ‘text-based’ data transmission formats.
  4. The hierarchical model for representation is limited in comparison to an object-oriented graph
  5. Expressing overlapping (non-hierarchical) node relationships requires extra effort.
  6. XML namespaces are problematic to use and namespace support can be difficult to correctly implement in an XML parser.
  7.  XML is commonly depicted as “self-documenting” but this depiction ignores critical ambiguities.