-->
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: Dynamic Model: using a different Map?
PostPosted: Wed Mar 30, 2005 1:37 am 
Newbie

Joined: Thu May 13, 2004 7:47 pm
Posts: 11
I like the "Dynamic Model" feature in Hibernate 3.0.

However, it seems Hibernate assumes the dynamic model is a HashMap in the implementation (see DynamicInstantiator). My question is if I can use my own implementation of Map?

Thanks.

- Wei Chen


Top
 Profile  
 
 Post subject:
PostPosted: Thu Mar 31, 2005 7:06 pm 
Hibernate Team
Hibernate Team

Joined: Sun Sep 14, 2003 3:54 am
Posts: 7256
Location: Paris, France
You can't AFAIK. What is your use case?

_________________
Emmanuel


Top
 Profile  
 
 Post subject:
PostPosted: Thu Mar 31, 2005 7:48 pm 
Newbie

Joined: Thu May 13, 2004 7:47 pm
Posts: 11
emmanuel wrote:
You can't AFAIK. What is your use case?


There are many use cases:

1. I want a faster implementation of Map than HashMap
2. I want additional processing around get/put operation such as have default values for certain field
3. I want additional domain semantics on this Map:
Code:
    class DomainObject implements Map {
       ... standard Map methods such as get/put ....
       .... other domain methods ....
    }


Thanks.

- Wei Chen


Top
 Profile  
 
 Post subject:
PostPosted: Thu Mar 31, 2005 11:16 pm 
Hibernate Team
Hibernate Team

Joined: Tue Aug 26, 2003 3:00 pm
Posts: 1816
Location: Austin, TX
The "hooks" are there (i.e., the Instantiator interface) but we have just not yet exposed this for configuration. Add a JIRA enhancement request.


Top
 Profile  
 
 Post subject:
PostPosted: Thu Mar 31, 2005 11:19 pm 
Newbie

Joined: Thu May 13, 2004 7:47 pm
Posts: 11
steve wrote:
The "hooks" are there (i.e., the Instantiator interface) but we have just not yet exposed this for configuration. Add a JIRA enhancement request.


I guess no short-term workaround available, is there?


Top
 Profile  
 
 Post subject:
PostPosted: Thu Mar 31, 2005 11:23 pm 
Hibernate Team
Hibernate Team

Joined: Tue Aug 26, 2003 3:00 pm
Posts: 1816
Location: Austin, TX
Aside from changing the Hibernate source yourself, no; until we expose the ability for users to configure the various instantiators to be used.


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.