1st.use..
You can use XMl to import data into your system and Export out of the system.
This will make you application easier to interact with other application written in different languages.
It depends on a Developer too, some prefer to bind grid with XML and some choose with objects.
2nd use of XML with Example..
Assume am validating a ZIP code (Server Side) that ensures that the user entered ZIP code is available in my ZIPCodes table in some X database. ( An arbitrary business requirement).
Now assume I have 100,000 customers hitting my website every 2 hrs (not realistic but possible. Consider this scenario for the reasons of explanation).
The database may get hammered 100,000 times every 2 hrs. The database may also need to serve other requests apart from the one under discussion.
So, database is a busy for most of the time.
Presuming that ZIPCodes dont change often or they dont change for ever, I would export the ZipCodes to an XML file and have it somewhere secure as part of the web-application.
Now, the validation is done against the XML file and not the database.
So, we might endup eliminating 100,000 hits to the database, in which case the database is open to serve other requests.
There are other possible uses too! But this should just give you a jist of the power xml has.
No comments:
Post a Comment