-->
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: Mapping to XML
PostPosted: Mon May 07, 2007 9:16 am 
Newbie

Joined: Fri Dec 09, 2005 12:34 pm
Posts: 6
Hi all,

I'm just curious about using the table to XML mapping functionality. Is there a way to map to elements with namespaces? I've been looking around, but there doesn't seem to be any verbiage around it in the docs. Thanks in advance.

- K


Top
 Profile  
 
 Post subject:
PostPosted: Mon May 07, 2007 11:15 pm 
Senior
Senior

Joined: Sat Aug 19, 2006 6:31 pm
Posts: 139
Sure...

look at "schema" or "catalog" in here

http://www.hibernate.org/hib_docs/v3/re ... on-mapping

and here

http://www.hibernate.org/hib_docs/v3/re ... tion-class

_________________
Don't forget to rate the reply if it helps..:)

Budyanto


Top
 Profile  
 
 Post subject:
PostPosted: Tue May 08, 2007 9:00 am 
Newbie

Joined: Fri Dec 09, 2005 12:34 pm
Posts: 6
Thanks for the help, but I meant namespaces within the XML. The two schema attributes that you pointed me to are for Database schemas, not xsds. I'm looking more for something like changing the result from a query to use namespaces (when using the new to-XML mapping mapping ability). Like this:

<core:Person xmlns:core="blah.com/core.xsd">
<core:name>kontakte</core:name>
<pretzel:toy xmlns:pretzel="blah.com/food.xsd">yoyo</pretzel:toy>
</core:Person>


Top
 Profile  
 
 Post subject:
PostPosted: Sat Jul 14, 2007 8:50 am 
Newbie

Joined: Mon Sep 04, 2006 9:03 am
Posts: 9
I would also vote for a namespace feature of the dom4j entity mode. I would be happy if I could put my XML export into a namespace.


Top
 Profile  
 
 Post subject:
PostPosted: Thu Jul 19, 2007 1:49 pm 
Newbie

Joined: Fri Dec 09, 2005 12:34 pm
Posts: 6
Yeah, one of the things my team at work is looking at is building web services in Java that provide CRUD functionality for Databases. In doing this, we figured that it's only logical to keep the information in an XML format because our transport is SOAP/XML and rarely do we do anything except display this data on a web page... So, if we can get the information in XML from the DB (namespaced so we don't have to do any crazy namespacing), we can keep it in XML until it gets to the client where they'd simply put it through a stylesheet for output! No unnecessary Java Objects!


Top
 Profile  
 
 Post subject:
PostPosted: Thu Jul 19, 2007 4:06 pm 
Newbie

Joined: Mon Sep 04, 2006 9:03 am
Posts: 9
Oh yes. Very good point, too. XML without namespaces is like no XML at all.


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.