xom-interest AT lists.ibiblio.org
Subject: XOM API for Processing XML with Java
List archive
Re: [XOM-interest] Sending a document across a socket
- From: "Steve Loughran" <steve.loughran AT gmail.com>
- Cc: xom-interest AT lists.ibiblio.org
- Subject: Re: [XOM-interest] Sending a document across a socket
- Date: Sat, 7 Oct 2006 11:52:50 +0100
On 06/10/06, Michael Kay <mike AT saxonica.com> wrote:
> If I have created a document (which seems straightforward)
> what do I do with it to be able to send it across a socket
> that I have opened.
You serialize it to XML.
> And also the opposite. What do I do if I need to receive a
> file from a socket.
>
You parse the XML arriving on the socket and build a new document.
XML was specifically designed for serializing documents, so it makes sense
to use it when that's what you need to do.
The other thing to think about is whether you want to do all the low
level socket work yourself.
the Smack XMPP library: http://www.jivesoftware.org/smack/ is a nice
little java library for doing XMPP/Jabber work, where any packet you
send can include arbitrary XML inside. You get encryption and some
through-the-firewall work (though not XMPP-over-HTTP proxying). Worth
looking at if you have complex network setups to deal with (like a
WS-Notification endpoint hosted in public routing events to a roaming
laptop behind a firewall)
-steve
-
[XOM-interest] Sending a document across a socket,
Altman, Alan, 10/06/2006
- Re: [XOM-interest] Sending a document across a socket, Elliotte Harold, 10/06/2006
-
Re: [XOM-interest] Sending a document across a socket,
Michael Kay, 10/06/2006
- Re: [XOM-interest] Sending a document across a socket, Wolfgang Hoschek, 10/06/2006
- Re: [XOM-interest] Sending a document across a socket, Steve Loughran, 10/07/2006
Archive powered by MHonArc 2.6.24.