I actually had a look at that API documentation, and thats what confused me a bit.
Quote:
it is not guaranteed that the elements INSIDE the collection will be initialized/materialized
It does not mention whether the elements in the collection will be loaded by querying the database. The above statement uses the word 'not guaranteed' which i interpreted as may or may not. Suppose the child elements are not loaded but only is collection is initialized, then when the contents of the collection are used at some later point(when the session is closed) will it throw some exception(LazyInitializationException).
Well, i can surely try out the above things on my own, but currently i dont have the required setup. So if this has a quick answer, i would appreciate.
Thank you.