I believe that this property allows to instrument not only entity classes but other code as well in order to intercept field access.
Consider following code:
Code:
@Entity public class MyEntityClass {
@Id public long id;
@Basic public String data;
}
In case of extended instrumentation it will transform this method:
Code:
@PersistenceContext em;
void businessMethod() {
MyEntityClass mec = em.find(1l);
System.out.println(mec.data);
}
To something like this:
In case of extended instrumentation it will transform this method:
Code:
@PersistenceContext em;
void businessMethod() {
MyEntityClass mec = em.find(1l);
System.out.println(mec.$javassist_read_data());
}
This will allow lazy loading work even for public field access strategies