Java Mapping concepts Understanding - Mapping is the way of transforming one XML structure to another XML Structure. As a part of it we do certain operations like breaking child nodes and attaching them to its parent node and more in an XML structure. |
|
Business Related Topics...
Computer Related Topics...
Entertainment, Recreation & Sports Related Topics...
Health & Fitness Related Topics...
Home & Family Related Topics...
Shopping Related Topics...
Would you like to submit articles to our site? Have a question or a problem?
You are here: DIME Home > Programming and Scripting > Java Mapping concepts Understanding
Mapping is the way of transforming one XML structure to another XML Structure. As a part of it we do certain operations like breaking child nodes and attaching them to its parent node and more in an XML structure.
Author: Venkatesh Pai
Date: Oct 25, 2009 - 1:44:37 AM
Mapping is the way of transforming one XML structure to
another XML Structure. As a part of it we do certain operations like breaking
child nodes and attaching them to its parent node and more in an XML structure.
In XI/PI we have the following mapping
techniques
1. Graphical Mapping
2. ABAP Mapping
3. JAVA Mapping and
4. XSLT Mapping.
Among all the above mapping techniques, JAVA mappings improve the performance and are preferred as they get executed on J2EE engine directly. But in case of graphical mapping, XI/PI converts the mapping program into executable Java code internally based on graphical design and executes it on J2EE engine making it comparatively less efficiency. Java mappings are more useful when performance of integration server is concerned during runtime. Java mappings are Parsing Programs that can be developed in NWDS (NetWeaver Developer Studio), import as .jar files and can be used in the mapping part of Integration Repository. NWDS provides suitable Java environment and higher level tools to parse XML documents through the Simple API for XML (SAX) and the Document Object Model (DOM) interfaces. The SAX and DOM parsers are standards that are implemented in several different languages. In the Java programming language, you can instantiate the parsers by using the Java API for XML Parsing (JAXP).
JAVA
mapping can be done in two ways:
1. DOM
Parsing
2. SAX
Parsing
At the core of the DOM API are the Document and Node interfaces. A Document is a top-level object that represents an XML document. The Document holds the data as a tree of Nodes, where a Node is a base type that can be an element, an attribute, or some other type of content. The Document also acts as a factory for new Nodes. Nodes represent a single piece of data in the tree, and provide all of the popular tree operations. You can query nodes for their parent, their siblings, or their children. You can also modify the document by adding or removing Nodes.
SAX
PARSING TECHNIQUE
SAX
(Simple API for XML) is an
event-driven model for processing XML. The SAX model is quite different. Rather
than building a complete representation of the document, a SAX parser fires off
a series of events as it reads the document from beginning to end. Those events
are passed to
event handlers, which provide access
to the contents of the document.
Event Handlers
There are three types of event handlers: DTD Handlers, for accessing the contents of XML Document-Type Definitions; Error Handlers, for low-level access to parsing errors; and, by far the most often used, Document Handlers, for accessing the contents of the document. A SAX processor will pass the following events to a Document Handler:
a). The start of the document.
b). A processing instruction element.
c). A comment element.
d). The beginning of an element, including that element’s attributes.
e). The text contained within an element.
f). The end of an element.
g). The end of the document.
Advantages
and Disadvantages
SAX
Advantages:
DOM
Advantages:
1. It is good when random access
to widely separated parts of a document is required.
2. It supports both read and
write operations.
Disadvantage:
It is memory inefficient because DOM consumes more memory to
construct the XML tree Object in the memory corresponding to the input XML its
not advisable to use for parsing large XML documents In that case SAX is
preferred over DOM.
1. It is simple to program.
2. It is memory efficient as SAX
parser does not keep any of the document tree in memory.
Disadvantage:
The data is broken
into pieces and clients never have all the information as a whole unless they
create their own data structure.
Differences
between SAX and DOM parser at a glance
SAX
1. Parses node by node
2. Doesn’t store the XML in
memory
3. We cant insert or delete a
node
4. Top to bottom traversing
DOM
1. Stores the entire XML document into memory before processing
2. Occupies more memory
3. We can insert or delete nodes
4. Traverse in any direction.
Spec
HTML5 - The End of PSD to HTML Slicing Providers?Oct 18, 2010 - 11:20:32 AM In 2009 the World Wide Web Consortium (W3C) decided to concentrate their efforts on HTML5, a new revision of HTML, rather than XHTML2. HTML5 is strongly supported by Apple, Opera, Mozilla, Microsoft, Google and other leading IT companies and web browser developers. All this means that HTML5 is becoming a mainstream of the Internet.... [Read the full story] |
Top 10 Points to Remember While Doing Web DevelopmentSep 17, 2010 - 6:44:25 AM The web developers have a vital role to play in the success of the online business as they are actual programmers of the web site. No one is going to fence on the fame of the web development in today’s competitive world. This is a high tech decade and you have to be on your toes all the time to contend well. The design of the website sets the tone for the success. If its attractive people would love it but if it’s not they are going to leave the page next moment.... [Read the full story] |
Top 5 PHP Frame Work List to speed up your Programming efficiencyJan 9, 2010 - 3:23:32 AM PHP is a widely used and open source scripting language which designed for web development to build dynamic web pages. PHP Applications are normally hosted or found on Linux Servers. Its functionality same as Windows platform by Active Server Pages Technology.... [Read the full story] |
Ethical Hacking for Strong SecurityJan 7, 2010 - 12:53:55 PM Ethical hacking is a process that utilizes the same techniques that malicious hackers use, but for the purpose of assessing security threats to your organization’s information assets. Entities of all types (private businesses, government agencies, non-profit corporations, Hospitals, Universities, Etc.) need strong IT security now more than ever. It is imperative that IT security personnel learn “Black Hat” (malicious) hacking techniques in order to counter or prevent attacks on critical IT systems and assets.... [Read the full story] |
Search for articles: |
Latest Articles in All Categories |
Putting Up a Small Commercial Printing Business |
So You Might Be Unemployed And Desire To Become A San Francisco Real Estate Investor Now |
Meditation and Mindfulness: Dealing With Emotion |
CPA Websites: Five Essential Ideas for Composing Convincing Articles |
Set Goals In Order to Come Up With Your Action Plan |
Is the Air in Your Home Safe to Breathe? |
Coarse Fishing Tackle Review: The JW Young 13ft Trotter Rod |
Section 1031 Exchanges For San Diego Real Estate Investors |
Phoenix Real Estate Investing For Highest Possible Earnings |
Legendary are the Volk Racing TE37 Wheels |
Developing the Next Generation Wall Station (ChaseDesk™) for Healthcare - A Case Study |
What are step down transformers? |
Introducing Sharehype, the Revolutionary Tool for Online Marketers |
Rewards To Shopping For Austin Real Estate On The Web |
Hydroponics for Beginners |
Would you like submit your articles and have them approved on a priority status? Find out more about how you can become a Priority author for pennies a day! Click here.
Dime-co.com Home |
|
|
|
|
|
|
|
|
|
|
|
|
|
Disclaimer: Dime-Co.Com is an online information article and video article network. All articles, video articles, comments, and other features herein are for informational purposes only and are provided "as is" without warranties, representations or guarantees of any kind. The views and opinions expressed in an article, comments, links or blogs are the author's own, and not necessarily those of dime-co.com's owners. For full disclaimer, please read our TOS.