[JDEV] Net::Jabber
amarjeetkaur at credenceanalytics.com
amarjeetkaur at credenceanalytics.com
Sun Dec 8 03:14:23 CST 2002
<PRE>
List-Subscribe: <http://mailman.jabber.org/listinfo/jdev>,
<mailto:jdev-request at jabber.org?subject=subscribe>
List-Id: Very active list for Jabber developers <jdev.jabber.org>
List-Unsubscribe: <http://mailman.jabber.org/listinfo/jdev>,
<mailto:jdev-request at jabber.org?subject=unsubscribe>
List-Archive: <http://mailman.jabber.org/pipermail/jdev/>
Date: Sun, 8 Dec 2002 02:46:42 -0600
<PRE>
If you take a look at:
man Net::Jabber::Protocol
you will see a function called DefineNamespace, which allows you to
create the same access functions that all of the other piece share.
Right now you should still be able to use it as is. In the future, I'll
be tweaking it to be more inline with the current data storage model for
Net::Jabber.
Or, you take the object that is passed to the function, and use the
GetTree() function to return the full XML::Sream::Node object tree that
"should" contain all of the piece you want access to. I haven't tested
this piece all that well since I just added support for it in the last
couple of releases, but if there is something missing then I'll be happy
to look into it.
Tiago Almeida wrote:
> Hi all,
> i'm using the perl module Net::Jabber to create some BOTs for my jabber
> server,and i'm having some difficulties retrieving some xml namespaces.
>
> I'm using the Net::Jabber:X, thats has some methods, but only for
> default namespaces.
> i want to retrieve data in namespaces created by me.
>
> i.e.
>
> i have this xml data
> <message to=user1 at someserver.whatever from=user2 >
> <x xmlns=mic_alert>
> <alert type=remove name=alert name />
> </x>
> </message>
>
>
> or this data
>
> <message to=user1 at someserver.whatever from=user2 >
> <x xmlns=mic_alert>
> <alert name=alert name alerttime=alerttime1 in utc
> eventtime=eventtime1 in utc alldayevent="yes/no"
> category="alert/invitation/anything _else" message=mention
the alert
> message><categoryinfo>some
> string</categoryinfo></alert>
> </x>
> </message>
>
> now how can i retrieve the data in <x></x> namespace?
>
> Best regards,
> tsa
>
--
Ryan Eatmon
reatmon at jabber.org
_______________________________________________
jdev mailing list
jdev at jabber.org
http://mailman.jabber.org/listinfo/jdev
</PRE>
_______________________________________________
jdev mailing list
jdev at jabber.org
http://mailman.jabber.org/listinfo/jdev
</PRE>
More information about the JDev
mailing list