Hi,
I am using hibernate3 and think its quite a nice piece of software. Unfornutately I am having the job to extend hibernate for use with objectteams Java (
http://www.objectteams.org) and the codebase of hibernate is somewhat overwhelming to me.
As a short explanation, Objectteams is an extension to java that introduces teamclasses and roleclasses. An example of Objectteams looks like this:
Code:
public team class myTeam {
synthetic WeakHashMap _OT$cache$MyRole <MyBase, MyRole>
...
public class MyRole playedBy MyBase {
synthetic final MyBase _OT$base
...
}
}
As you can see Teamclasses are the outer classes that contain roleclasses as nested classes. In this case playedBy means a relation to some kind of baseclass. These classes are related to each other with references (the synthetic values), that are generated by a compiler. Such a thing shoud be stored with hibernate including the generated values.
My question at the moment is, how can I store some kind of nested class in normal style java with hibernate. how can I store a thing like this:
Code:
public class myClass {
...
public class myNestedClass {
...
}
}
Probably this can be done in some way. If not, someone might have enough knowledge on how to extend hibernate to do this, e.g. with
custom types (I am not that far with knowledge about hibernate extension programming :-( ). If you have more suggestion how a thing like this can be realized with hibernate, feel free.
Regards,
Micha K.