-->
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.  [ 2 posts ] 
Author Message
 Post subject: Extending Hibernate Internals
PostPosted: Mon Jun 21, 2004 3:45 pm 
Regular
Regular

Joined: Mon Feb 23, 2004 10:42 pm
Posts: 102
Location: Washington DC
I am looking to plugin a framework, Meta-JB (http://sourceforge.net/projects/meta-jb) into the Hibernate. Instead of returning concrete objects from a query, I would like to be able to wrap the invidual rows as metaObjects (basically Map-like name/value pairs). I was wondering if the Hibernate API has some interfaces that can be implemented to hook in as we need to. Is there any documentation about extending/hooking into the Hibernate framework?

Since our applications tend not to use concrete model objects, but rather metaObjects, we currently have to create the model objects just for Hibernate to use and then wrap them as metaObjects for use in the rest of the application.


Meta-JB description for background....

Meta-JB extends the Java Beans concept providing more generic access to object attributes and descriptions. The descriptions of a class's properties (the MetaClass) and access to an object's attributes are decoupled from actual implementations by adapters implementing a Map-like name/value interface (the MetaObject). Because the thin framework is built on generic interfaces, it is not tied directly to real Java bean implementations and can also be used for anything that can access values by name. (Some examples might be SQL result sets, HTTP request data, or simple hash maps.) Once a "class" has been described, the information can even be applied to different underlying implementations.


Top
 Profile  
 
 Post subject:
PostPosted: Tue Jun 22, 2004 2:05 am 
Hibernate Team
Hibernate Team

Joined: Tue Aug 26, 2003 6:10 am
Posts: 8615
Location: Neuchatel, Switzerland (Danish)
try to look into PropertyAccessor which allow you to change the way hibernate read and write properties to an object.

and look at Interceptor.instantiate

_________________
Max
Don't forget to rate


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 2 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.