Skip to Content.
Sympa Menu

xom-interest - [XOM-interest] enhancements

xom-interest AT lists.ibiblio.org

Subject: XOM API for Processing XML with Java

List archive

Chronological Thread  
  • From: dvholten AT computer.org
  • To: xom-interest AT lists.ibiblio.org
  • Cc:
  • Subject: [XOM-interest] enhancements
  • Date: Tue, 07 Dec 2004 17:03:21 GMT

hi there,

as you discuss technical performance matters, i'd like to throw in some
more 'stylistic' enhancements:

i propose these changes in xom/Attribute.java enumeration class 'Type':
- drop int member ' type'
- add String member 'name' (i propose 'final String' as it is immutable)
- change constructor (and constructor calls) to accept the symbolic names
- drop switch statement in getName(), just return name
- change hashCode() to return name's hashCode

HTH
dvholten
>From brian AT slesinsky.org Tue Dec 7 12:51:48 2004
Return-Path: <brian AT slesinsky.org>
X-Original-To: xom-interest AT lists.ibiblio.org
Delivered-To: xom-interest AT lists.ibiblio.org
Received: from smtp810.mail.sc5.yahoo.com (smtp810.mail.sc5.yahoo.com
[66.163.170.80])
by happyhouse.metalab.unc.edu (Postfix) with SMTP id B463F4C005
for <xom-interest AT lists.ibiblio.org>;
Tue, 7 Dec 2004 12:51:47 -0500 (EST)
Received: from unknown (HELO ?192.168.0.1?)
(skybrian AT sbcglobal.net@64.161.212.170 with plain)
by smtp810.mail.sc5.yahoo.com with SMTP; 7 Dec 2004 17:51:46 -0000
In-Reply-To: <41B57D54.5010608 AT metalab.unc.edu>
References: <90C430D5-4804-11D9-B9EA-000393A2E426 AT slesinsky.org>
<41B57D54.5010608 AT metalab.unc.edu>
Mime-Version: 1.0 (Apple Message framework v619)
Content-Type: multipart/mixed; boundary=Apple-Mail-8--419345779
Message-Id: <A947A7A8-4878-11D9-B9EA-000393A2E426 AT slesinsky.org>
From: Brian Slesinsky <brian AT slesinsky.org>
Subject: Re: [XOM-interest] mysterious error when parsing OpenOffice document
Date: Tue, 7 Dec 2004 09:51:45 -0800
To: Elliotte Harold <elharo AT metalab.unc.edu>
X-Mailer: Apple Mail (2.619)
X-Content-Filtered-By: Mailman/MimeDel 2.1.5
Cc: xom-interest AT lists.ibiblio.org
X-BeenThere: xom-interest AT lists.ibiblio.org
X-Mailman-Version: 2.1.5
Precedence: list
List-Id: xom-interest.lists.ibiblio.org
List-Unsubscribe: <http://lists.ibiblio.org/mailman/listinfo/xom-interest>,
<mailto:xom-interest-request AT lists.ibiblio.org?subject=unsubscribe>
List-Archive: <https://lists.ibiblio.org/sympa/arc/xom-interest>
List-Post: <mailto:xom-interest AT lists.ibiblio.org>
List-Help: <mailto:sympa AT lists.ibiblio.org?subject=HELP>
List-Subscribe: <http://lists.ibiblio.org/mailman/listinfo/xom-interest>,
<mailto:xom-interest-request AT lists.ibiblio.org?subject=subscribe>
X-List-Received-Date: Tue, 07 Dec 2004 17:51:48 -0000


--Apple-Mail-8--419345779
Content-Transfer-Encoding: 7bit
Content-Type: text/plain;
charset=US-ASCII;
format=flowed


On Dec 7, 2004, at 1:52 AM, Elliotte Harold wrote:
>
> The {0} looks like a parser bug to me. I suspect it's reporting the
> index of a parameter entity in some internal table rather than its
> actual name. (Just a guess, though. Could be something else.) Which
> parser are you using?

I didn't specify a SAX parser, so I believe it's just whatever comes
with Java 1.4.

>> The thing is, I can't find the line that has the error. It think it
>> must be one of the files included by office.dtd, but which one? A
>> grep doesn't any such parameter entry. It sure would be nice if XOM
>> reported both file and line number for errors in included files.
>
> OK. Possibly I could add this, but it would help if I had a
> reproducible test case of the problem. If the document you're parsing
> is not private, could you send me a copy? If it is, could you possibly
> create a test case that demonstrates the problem? Doe sit occur with
> all OpenOffice documents or just this one?

My suspicion is that any OpenOffice document would do. Since then I
tried parsing it with an XML pull parser (xpp3) and that seems to work,
but it appears to be skipping the DTD. The DTD I'm using is from the
RedHat rpm for OpenOffice 1.0.2.

My test document is just a spreadsheet with a single cell, which I've
attached. (OpenOffice documents are zip files that contain XML. The
content.xml file is the one you want. )

- Brian


--Apple-Mail-8--419345779--





Archive powered by MHonArc 2.6.24.

Top of Page