You are viewing a plain text version of this content. The canonical link for it is here.
Posted to p-dev@xerces.apache.org by Gero Meißner <me...@zentrale.heinze.de> on 2001/07/24 11:37:08 UTC

converting DOM_Node back to DOM_Attr

I used the function 'importNode' to import an attribute-node from one
document to another one. How can I convert the resulting node (DOM_Node)
back to an attribute (DOM_Attr) in Perl?

Thank you!

Gero Meißner

Heinze GmbH
Geschäftsstelle Ost
Paradiesstraße 206B
12526 Berlin

Tel: +49 (030) 67 97 09 24
Fax: +49 (030) 67 97 09 34
email: gero.meissner@heinze.de


---------------------------------------------------------------------
To unsubscribe, e-mail: xerces-p-dev-unsubscribe@xml.apache.org
For additional commands, e-mail: xerces-p-dev-help@xml.apache.org


Re: converting DOM_Node back to DOM_Attr

Posted by "Jason E. Stewart" <ja...@openinformatics.com>.
"Gero Meißner" <me...@zentrale.heinze.de> writes:

> I used the function 'importNode' to import an attribute-node from
> one document to another one. How can I convert the resulting node
> (DOM_Node) back to an attribute (DOM_Attr) in Perl?

Hey Gero,

The first answer is you shouldn't need to, but if you do for some
reason, let me know - it might mean something needs fixing.

The second aswer is try $node->actual_cast(). If it is a DOM_Attr
node, it should recast the object into that class. That's a piece of
the perl-specific API. 

jas.

---------------------------------------------------------------------
To unsubscribe, e-mail: xerces-p-dev-unsubscribe@xml.apache.org
For additional commands, e-mail: xerces-p-dev-help@xml.apache.org