-->
These old forums are deprecated now and set to read-only. We are waiting for you on our new forums!
More modern, Discourse-based and with GitHub/Google/Twitter authentication built-in.

All times are UTC - 5 hours [ DST ]



Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 6 posts ] 
Author Message
 Post subject: Persistence in xml or flat files
PostPosted: Thu Dec 08, 2005 1:05 pm 
Beginner
Beginner

Joined: Thu Apr 07, 2005 5:12 pm
Posts: 27
Location: Hamburg
Hello,

all business objects are mapped with hibernate of course. Is there a way to export them to a file, for example xml, when objects are achieved by a query? Or any other idea for an import / export function of application data near to object structure? (no sql dumps).

Thanks in advance

Marcus


Top
 Profile  
 
 Post subject:
PostPosted: Thu Dec 08, 2005 1:15 pm 
Regular
Regular

Joined: Wed Feb 02, 2005 6:33 am
Posts: 70
Well, you could try using Hibernate's DOM4J entity mode (see hibernate reference manual), and writing the retrieved objects out however you desire, or you could use some third-party library such as XStream To convert the Pojo's to XML.

I'm sure others have different ways of doing this.


Top
 Profile  
 
 Post subject:
PostPosted: Thu Dec 08, 2005 1:28 pm 
Beginner
Beginner

Joined: Thu Apr 07, 2005 5:12 pm
Posts: 27
Location: Hamburg
Thanks you. Had XStream in mind. I will look for the Dom4J Entity Mode. Another thing I found is HyperJAXB. If anyone of it will work for it, I tell you.


Top
 Profile  
 
 Post subject:
PostPosted: Thu Dec 08, 2005 11:37 pm 
Expert
Expert

Joined: Mon Jul 04, 2005 5:19 pm
Posts: 720
Each object of the domain model should be Serializable ... ;)


Top
 Profile  
 
 Post subject:
PostPosted: Wed Dec 14, 2005 10:07 am 
Beginner
Beginner

Joined: Thu Apr 07, 2005 5:12 pm
Posts: 27
Location: Hamburg
I decided to use the Dom4J Model, sounds promising. Just wonder how i can specifiy if an HQL query returns a DOM or Objects.


Top
 Profile  
 
 Post subject:
PostPosted: Wed Dec 14, 2005 10:14 am 
Beginner
Beginner

Joined: Thu Apr 07, 2005 5:12 pm
Posts: 27
Location: Hamburg
polarbaerhh wrote:
I decided to use the Dom4J Model, sounds promising. Just wonder how i can specifiy if an HQL query returns a DOM or Objects.


sorry... ignore this post. scrolled over it. *shamed*


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 6 posts ] 

All times are UTC - 5 hours [ DST ]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.