473,385 Members | 1,409 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 software developers and data experts.

How DOMLocator operate?

Max
Hello!

I would want to understand the operation of DOMLocator. In practical,
the coordinates (column and line number) of a DOMError (recovered by
inner implementation) only can be calculated during the parsing (on the
document originally formatted)? If i add a node to document (or any
other operation that modify the structure of the document), is it
impossible to recover the coordinates?

Max
Oct 13 '06 #1
2 1140
Max wrote:
I would want to understand the operation of DOMLocator.
Information stored during parsing, referring to the original document
contents. No, it isn't maintained during DOM manipulations, not least
because the DOM doesn't know how the document is going to be serialized
back out (different serializers may generate different-but-equivalent
results) and so has no way to tell you what line something will be on in
the future.

I recommend very strongly against trying to express XML locations in
terms of line and column number. Generate an XPath to that location instead.

--
Joe Kesselman / Beware the fury of a patient man. -- John Dryden
Oct 13 '06 #2
Max
Joseph Kesselman ha scritto:
Max wrote:
>I would want to understand the operation of DOMLocator.

Information stored during parsing, referring to the original document
contents. No, it isn't maintained during DOM manipulations...
Good! In this case, since DOMLocator is connected to DOMError, when is
DOMError used?

I recommend very strongly against trying to express XML locations in
terms of line and column number. Generate an XPath to that location
instead.
I think XML Locations must be in terms of line and column number! It's
most simple! You recommend to use XPath instead of line and column
number, but DOMLocator cannot have this format.
Is DOMLocator Uri the document Uri?
How to define UTF16 and Byte offset?

More thanks,

Max
Oct 14 '06 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

6
by: ÒÊÃÉɽÈË | last post by:
i want to compare the content in excel,but i don't know whick module to use! can you help me?
3
by: Richard Cavell | last post by:
#include <gmp.h> vector<mpz_t> v_bigints; v_bigints.resize(20); This fails. error: ISO C++ forbids casting to an array type '__mpz_struct' (GCC on a G4) What's wrong with this? (GMP...
1
by: Mamatha | last post by:
Hi I have one application in VB.NET. When we click on particular button,it connects to the net and getback with the source code of a particular web page.While connecting to net it blocks all...
7
by: Hardy &&& | last post by:
Please can any body tell me: How can I operate (or deliver) the " Visual C++.NET ", from its mother program " MS Visual Studio 2005"?? A beginner needs Help. Thank you all....
3
by: key9 | last post by:
Hi all I am confuse of how to override operate "<<" Sample , I've got 2 class class Terminal { public:
4
by: manjesh | last post by:
hi , kindly help to create a toolbar with that new , save , edit, cancel button , if i open each form to operate this buttons ,instead of placing in each form . regards manjesh
0
by: michalfromczech | last post by:
Hi, i have problem, i want connect and operate with my FTP server in VISUAL BASIC 6.0, but i don't have dll, which can this function do. I have download any dlls (Chilkat FTP) but there are not for...
4
by: neehakale | last post by:
I m trying to write an event for the CheckedListBox...here m using foreach loop syntsx: (type identifier in expression) but it is giving error :foreach statment cannot operate on variables of...
8
by: Jerry Spence1 | last post by:
Do Timers operate on the UI thread, or do they have it's own thread? I'm trying to assess the pros and cons for using a timer or a thread for a certain application. -Jerry
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.