Wrox Programmer Forums
Go Back   Wrox Programmer Forums > Java > Java and JDK > J2EE
|
J2EE General J2EE (Java 2 Enterprise Edition) discussions. Questions not specific to EE will be redirected elsewhere.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the J2EE section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old June 25th, 2005, 10:02 PM
Registered User
 
Join Date: May 2005
Posts: 8
Thanks: 0
Thanked 0 Times in 0 Posts
Default help me its urgent

i am writing a mail server for lan i.e the members of a lan can write mail to the next
member of same lan
its only for the lan

i got a problem while storing the mail .......
i tried to do it using a simple file for each user and append the new mail to it
but this idea couldnot satisfy me

next idea struck i.e xml but i had problem in this

the problem is
i have the xml file as
......
..........
<mailbox>
   <mail id="1" flag="read">
       <from> cynic061 </from>
       <to> shankar </to>
       <subject> hi </subject>
       <date> 2061/3/13 </date>
       <message> hi how are the days going on thanks </message>
   </mail>
</mailbox>

here id specifies the mail number which can be used to delete the mail and the flag is to identify the unread mail

now every time the mail comes it has to be appended after </mail> i mean
when new mail comes then the xml file looks like

<mailbox>
   <mail id="1" flag="read">
       <from> cynic061 </from>
       <to> shankar </to>
       <subject> hi </subject>
       <date> 2061/3/13 </date>
       <message> hi how are the days going on thanks </message>
   </mail>
   <mail id="2" flag="unread">
          <from> cynic061 </from>
          <to> shankar subedi </to>
          <subject> problems </subject>
          <date> 2061/3/14 </date>
          <message> these problems are making tensed </message>
   </mail>
</mailbox>

is this possible
how can i do these stuffs using java
please help me

thanks


 
Old July 14th, 2005, 01:18 AM
Authorized User
 
Join Date: May 2005
Posts: 13
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via Yahoo to meetnaveen4u
Default

Hi shankar,
We can do it by using dom object where input xml is read into the class and then appending the content of mail to this xml object. Please search for creating and using dom using java, you will get much information on this.
Hope this help u.


Thanks and Regards
Naveen.
 
Old July 22nd, 2005, 11:09 AM
Authorized User
 
Join Date: Jul 2004
Posts: 29
Thanks: 0
Thanked 0 Times in 0 Posts
Default

I use a combination of JDom and Xerces which works very well for me.

Chris J






Similar Threads
Thread Thread Starter Forum Replies Last Post
urgent deb_kareng ASP.NET 2.0 Professional 1 August 13th, 2007 07:29 AM
it's urgent deb_kareng ASP.NET 2.0 Professional 3 August 7th, 2007 07:40 AM
urgent help yash_coolbuddy_forindia BOOK: Wrox's ASP.NET 2.0 Visual Web Developer 2005 Express Edition Starter ISBN: 978-0-7645-8807-5 1 May 7th, 2007 08:40 AM
urgent???????????? nsr35 Beginning VB 6 1 October 3rd, 2005 10:57 AM
urgent ??????????????? nsr35 Pro VB Databases 0 October 3rd, 2005 04:53 AM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.