-->
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.  [ 1 post ] 
Author Message
 Post subject: @CollectionOfElements and maps with the same Embedded types
PostPosted: Thu May 24, 2007 4:16 pm 
Newbie

Joined: Tue Jun 13, 2006 5:36 pm
Posts: 2
I have a CollectionOfElements where the elements are properly stored as a Map. The key and value of the map are Embedded objects of the same type. I cannot figure out how to rename the columns used for my embedded types for just the key or just the value. So I always end up with repeated column errors. Below is my latest attempt. The attribute overrides and column specifications on MapKey seemed to be ignored. Is there any way to do this with annotations?

Thanks!


Code:
  @CollectionOfElements
@MapKey(columns={@Column(name="src_row"),@Column(name="src_column")})
  @Column
  @AttributeOverrides({
     @AttributeOverride(name="array_column", column=@Column(name="dst_column"))
  })
  public Map<ArrayPosition,ArrayPosition> getMapping()
   {
      return this.mapping;
   }


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

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.