public String giveOpinionOfNeil() {
        return "YOU DA MAN!";
}

Ahh, the missing "/".  Thanks!  Now, Part Deux of this question. Another
"Windows path" problem crops up in the resolveEntity method of the
EntityResolver.  There was a thread that I started last week about the fact
that if someone references a dtd in their XML file, e.g. data.dtd, the
systemId passed in as a parameter (assuming the xml file is
"c:\test\data.xml") will have a value of "file:///test/data.dtd".  This is a
problem for a couple of reasons -- first, it isn't the literal value present
in the XML file, so instead of evaluating what literally resides in the XML
file, the parser requires "intelligence" to be added to the resolveEntity
method beyond simply testing for the String present in the XML file.
Secondly, there is no drive information there.  In my app, all of my paths
are set dynamically, from user input that "configures" my server
application.  At the point of my application where the entityResolver must
return a resolved string for a dtd, I literally have no idea what drive this
resides on.  Question 1: Is there any way around this?  Suggestions -- I
received a good one from Milind last week, but I still want to use the
SystemId, not the PublicId.  Question 2: I am curious as to the reasoning
behind the "additive" path information to the value given in the SystemId in
the xml file.

Brad

-----Original Message-----
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
Sent: Monday, February 19, 2001 1:45 PM
To: [EMAIL PROTECTED]
Subject: RE: Windows Paths




Hi Brad.  That's what I thought, and you can accomplish this using the
"file:///c:/dir/file.name" syntax.  Give this a shot and let me know how it
works.

Cheers,
Neil

Neil Graham
XML Parser Development
IBM Toronto Lab
Phone:  416-448-3519, T/L 778-3519
E-mail:  [EMAIL PROTECTED]



"Brad O'Hearne" <[EMAIL PROTECTED]> on 02/19/2001 04:31:05 PM

Please respond to [EMAIL PROTECTED]

To:   <[EMAIL PROTECTED]>
cc:
Subject:  RE: Windows Paths


Neil,

I have already tried using the following:

parser.parse("file:///test/data.xml");

and that does work.  However, being on a Windows platform, I need to be
able
to reference the drive that this path information refers to. I may have any
number of drives available (c:, d:, e:, etc.), and need to be able to
specify what drive test/data.xml resides on.  Does anyone know how to
accomplish this?

Brad

-----Original Message-----
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
Sent: Monday, February 19, 2001 1:31 PM
To: [EMAIL PROTECTED]
Subject: RE: Windows Paths




Hi Brad.  Try "file:///xxx" where xxx is your c:/ stuff.  This should
hopefully solve your problem.

Cheers,
Neil

Neil Graham
XML Parser Development
IBM Toronto Lab
Phone:  416-448-3519, T/L 778-3519
E-mail:  [EMAIL PROTECTED]



"Brad O'Hearne" <[EMAIL PROTECTED]> on 02/19/2001 04:21:39 PM

Please respond to [EMAIL PROTECTED]

To:   <[EMAIL PROTECTED]>, "Milind Gadre"
      <[EMAIL PROTECTED]>
cc:
Subject:  RE: Windows Paths


I must still be missing something. Neither

parser.parse("c:/test/data.xml");

or

parser.parse("file://c:/test/data.xml");

are working.  They are both causing a NullPointerException to be thrown,
same as the "c:\test\data.xml" string below.

Any other ideas, or have I missed something?

Brad

-----Original Message-----
From: Milind Gadre [mailto:[EMAIL PROTECTED]
Sent: Monday, February 19, 2001 12:56 PM
To: [EMAIL PROTECTED]
Subject: Re: Windows Paths


Brad, use forward slashes ... c:/a/b/c

Regards...

Milind Gadre
ecPlatforms, Inc
901 Mariner's Island Blvd, Suite 565
San Mateo, CA 94404
C: 510-919-0596
F: 815-352-0779
[EMAIL PROTECTED]

>
> parser.parse("c:\test\data.xml");
>



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]






---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]






---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to