Hi, I see it the same way as you do; narrowing down the return type in the implementation class shouldn't be a problem.
I'm also getting no compilation error when compiling the user's code (as you said, IdentifierLoadAccessImpl shouldn't even be visible at the call site). Maybe it's a problem with a certain compiler/environment only? --Gunnar 2012/3/13 Steve Ebersole <st...@hibernate.org>: > Can someone verify I am not off my rocker here? Re : > https://hibernate.onjira.com/browse/HHH-7161 > > We have a case where Session defines a method that returns a public > interface org.hibernate.IdentifierLoadAccess. When SessionImpl > implements those methods it redefines the return to instead be a private > inner class that implements that org.hibernate.IdentifierLoadAccess > interface. > > As I understood it, when accessed through the Session interface what > return type is defined by SessionImpl is irrelevant. And indeed I am > not able to reproduce this when access those methods via Session. My > IDE gives me errors if I try to cast that reference to SessionImpl > instead. > > -- > st...@hibernate.org > http://hibernate.org > _______________________________________________ > hibernate-dev mailing list > hibernate-dev@lists.jboss.org > https://lists.jboss.org/mailman/listinfo/hibernate-dev _______________________________________________ hibernate-dev mailing list hibernate-dev@lists.jboss.org https://lists.jboss.org/mailman/listinfo/hibernate-dev