AndyD wrote:
I have a situation where I would like to use Hibernate to read objects from a database with no requirement to ever write them back. Furthermore, it would be helpful if the resulting objects were based on the standard java collection classes, with no Hibernate classes present in the resulting data structures.
Is this possible, or must I do a manual copy from one form to the other?
Many thanks for any advice.
AD[/b]
If you don't want to write them back, you can specify mutable=false which tells hibernate that they're read only.
Why do you care what the underlying implementation of the Collections are since it's best practice to code to interfaces and Hibernate provides data in java.util.Set, java.util.List collections etc...