| /* |
| * Copyright (c) 2019, 2020 Oracle and/or its affiliates. All rights reserved. |
| * Copyright (c) 2019 IBM Corporation. All rights reserved. |
| * |
| * This program and the accompanying materials are made available under the |
| * terms of the Eclipse Public License v. 2.0 which is available at |
| * http://www.eclipse.org/legal/epl-2.0, |
| * or the Eclipse Distribution License v. 1.0 which is available at |
| * http://www.eclipse.org/org/documents/edl-v10.php. |
| * |
| * SPDX-License-Identifier: EPL-2.0 OR BSD-3-Clause |
| */ |
| |
| // Contributors: |
| // IBM - initial drop |
| // 05/06/2019 - Jody Grassel |
| // - 547023 : Add LOB Locator support for core Oracle platform. |
| |
| package org.eclipse.persistence.jpa.test.oraclefeatures.model; |
| |
| import jakarta.persistence.Column; |
| import jakarta.persistence.Entity; |
| import jakarta.persistence.GeneratedValue; |
| import jakarta.persistence.GenerationType; |
| import jakarta.persistence.Id; |
| import jakarta.persistence.Lob; |
| |
| @Entity |
| public class OracleLobEntity { |
| @Id |
| @GeneratedValue(strategy = GenerationType.AUTO) |
| private Integer id; |
| |
| private String strData; |
| |
| @Lob |
| private byte[] blobData; |
| |
| @Lob |
| @Column(columnDefinition = "CLOB NOT NULL") |
| private String clobData; |
| |
| public Integer getId() { |
| return id; |
| } |
| |
| public void setId(Integer id) { |
| this.id = id; |
| } |
| |
| public String getStrData() { |
| return strData; |
| } |
| |
| public void setStrData(String strData) { |
| this.strData = strData; |
| } |
| |
| public byte[] getBlobData() { |
| return blobData; |
| } |
| |
| public void setBlobData(byte[] blobData) { |
| this.blobData = blobData; |
| } |
| |
| public String getClobData() { |
| return clobData; |
| } |
| |
| public void setClobData(String clobData) { |
| this.clobData = clobData; |
| } |
| |
| @Override |
| public String toString() { |
| return "OracleBlobEntity [id=" + id + ", strData=" + strData + "]"; |
| } |
| |
| } |