Article From:
import javax.persistence.Basic;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.Lob;
import javax.persistence.Transient;

import org.hibernate.bytecode.internal.javassist.FieldHandled;
import org.hibernate.bytecode.internal.javassist.FieldHandler;

import com.fasterxml.jackson.annotation.JsonIgnore;

 * Created by ll on 2017/12/15.
public class AnimalScience2   implements FieldHandled {
    @Basic(fetch = FetchType.LAZY)   
    private String detail; //Graph and text alternation type content (with text editor)

    public String getDetail() { 
         if (fieldHandler != null) {  
             return (String) fieldHandler.readObject(this, "detail    ", detail);  
      return null;

    public void setDetail(String detail) {
                fieldHandler.writeObject(this, "detail", this.detail, detail);  
            this.detail = detail; 
    private FieldHandler fieldHandler;//It does not require this technology to delay the loading of table fields and associate objects with lazy loading.
    public FieldHandler getFieldHandler() {  
        return fieldHandler;  
    public void setFieldHandler(FieldHandler fieldHandler) {  
        this.fieldHandler = fieldHandler;  

The above is the lazy loading of detail


Leave a Reply

Your email address will not be published. Required fields are marked *