How do you deal with composite pattern when using hibernate and domain-driven design?
Does hibernate has support for hierarchical data in a database where
- you use a pa开发者_如何学CrentId
- you use a parentId and an orderId
- you use Modified Preorder Tree Traversal
Hibernate supports Modified Preorder Tree Traversal in that lets you define the left/right properties. It does not support hierarchic queries however, but it's pretty trivial to re-hierarchize objects out of linear query if you order that by left value.
Just found that the feature is in-progress
http://opensource.atlassian.com/projects/hibernate/browse/HHH-1395
精彩评论