[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[xmlblaster-devel] Email parsing
Michele,
you told me that you are working on the mail plugin,
just some thought concerning the mail xml parsing:
# Email #1 (connect and publish)
<xmlBlaster>
<connect requestId="123456">
<qos>...</qos>
</connect>
<publish requestId="4357439068">
<key oid='myPhoto'/>
<content refid='Attachment#1'/>
<qos/>
</publish>
</xmlBlaster>
# Email #2 (response)
<xmlBlaster>
<qos reply="connect" requestId="123456">
<session>
<sessionId>04368ddfzh308346</sessionId>
</session>
</qos>
<qos reply="publish" requestId="4357439068">
<qos><state>OK</state></qos>
</qos>
</xmlBlaster>
# Email #3 (another publish)
<xmlBlaster>
<publish sessionId='04368ddfzh308346' requestId="4711">
<key oid='myText'/>
<content>Hello world</content>
<qos/>
</publish>
</xmlBlaster>
We have the XML sax parser already parsing the different
parts in those email.
How do you want to reuse the parser?
One approach could be
xmlBlaster/src/java/org/xmlBlaster/engine/cluster/NodeParser.java
where NodeParser is the 'father' parser, delegating
the sub-parses to other objects.
Do you know a better approach?
thanks,
Marcel
--
Marcel Ruff
mailto:ruff at swand.lake.de
http://www.lake.de/home/lake/swand/
http://www.xmlBlaster.org