/* * Hibernate, Relational Persistence for Idiomatic Java * * License: GNU Lesser General Public License (LGPL), version 2.1 or later. * See the lgpl.txt file in the root directory or <http://www.gnu.org/licenses/lgpl-2.1.html>. */ package org.hibernate.userguide.model; import javax.persistence.Basic; import javax.persistence.Entity; import javax.persistence.FetchType; import javax.persistence.Id; import javax.persistence.Lob; /** * @author Vlad Mihalcea */ @Entity public class Image { @Id private Long id; @Lob @Basic( fetch = FetchType.LAZY ) private byte[] content; public Long getId() { return id; } public void setId(Long id) { this.id = id; } public byte[] getContent() { return content; } public void setContent(byte[] content) { this.content = content; } }