Re: [libxml++] question about Document::set_entity_declaration()



OK. I have fixed this in HEAD, but not in the 2.8 branch, because it
seems like a slightly risky change of behaviour.

I have not added new API. set_entity_declaration_without_public_id() and
set_entity_declaration_without_system_id() and
set_entity_declaration_without_public_id_or_system_id() seems awkward.
It would be easier if we could reorder the parameters and make the last
2 optional, but we can't break API like that.

On Mon, 2005-03-14 at 09:18 +0100, Murray Cumming wrote:
> Christophe, could we branch for gnome-2-10, so I can fix this in HEAD,
> please?
> 
> On Fri, 2005-03-04 at 09:51 +0100, Murray Cumming wrote:
> > On Fri, 2005-02-25 at 17:38 +0100, Kike Fernandez wrote:
> > > Hello,
> > > 
> > > Is there a way to create an entity declaration of this type with
> > > Document::set_entity_declaration() function?
> > > 
> > > <!ENTITY TDoc01 SYSTEM "proba.xml" NDATA CorpusId>
> > > 
> > > set_entity_declaration() takes five arguments, one of which is the
> > > publicId. In libxml I can pass a NULL pointer as publicId
> > 
> > We did not know that null was a possible value for some of these
> > xmlAddDocEntity() parameters. The libxml documentation is not clear
> > about this.
> > 
> > We will have to add some method overloads in libxml++ 2.11/12. It's too
> > late to add them to libxml++ 2.10 now.
> > 
> > In the meantime, you should be able to call cobj() and use the
> > xmlAddDocEntity() function directly.
> > 
> > >  so the library
> > > creates correctly the entity but in libxml++ I cannot pass a NULL
> > > pointer (I get "Exception caught: attempt to create string with null
> > > pointer") and passing an empty string always creates something like 
> > > 
> > > <!ENTITY TDoc01 PUBLIC "" "proba.xml" NDATA CorpusId> 
> > > 
> > > Am I doing something wrong or is this a bug? 
> > > 
> > > Thank you.
> > > 
-- 
Murray Cumming
murrayc murrayc com
www.murrayc.com
www.openismus.com





[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]