From c934b0c93fa55a2b8677b16564d26472108c1319 Mon Sep 17 00:00:00 2001
From: tpylak <tpylak>
Date: Fri, 20 Mar 2009 15:35:58 +0000
Subject: [PATCH] LMS-791 revert (tests broken): index datasets when sample
 properties are changed

SVN: 10307
---
 .../openbis/generic/shared/dto/SamplePE.java  | 40 -------------------
 1 file changed, 40 deletions(-)

diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/generic/shared/dto/SamplePE.java b/openbis/source/java/ch/systemsx/cisd/openbis/generic/shared/dto/SamplePE.java
index f74d8b09c88..647eb991128 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/generic/shared/dto/SamplePE.java
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/generic/shared/dto/SamplePE.java
@@ -50,7 +50,6 @@ import org.hibernate.annotations.Cascade;
 import org.hibernate.annotations.Check;
 import org.hibernate.annotations.Generated;
 import org.hibernate.annotations.GenerationTime;
-import org.hibernate.search.annotations.ContainedIn;
 import org.hibernate.search.annotations.DocumentId;
 import org.hibernate.search.annotations.Field;
 import org.hibernate.search.annotations.Index;
@@ -146,45 +145,6 @@ public class SamplePE implements IIdAndCodeHolder, Comparable<SamplePE>,
 
     private Date modificationDate;
 
-    // -------------
-    // These methods are here only to make the Hibernate Search working. They should not be
-    // used as they do not maintain the bidirectional connections properly
-    // -------------
-
-    private Set<DataPE> acquiredDatasets = new HashSet<DataPE>();
-
-    private Set<DataPE> derivedDatasets = new HashSet<DataPE>();
-
-    @SuppressWarnings("unused")
-    @OneToMany(fetch = FetchType.LAZY, mappedBy = "sampleAcquiredFrom")
-    @ContainedIn
-    private Set<DataPE> getAcquiredDatasets()
-    {
-        return acquiredDatasets;
-    }
-
-    @SuppressWarnings("unused")
-    private void setAcquiredDatasets(Set<DataPE> acquiredDatasets)
-    {
-        this.acquiredDatasets = acquiredDatasets;
-    }
-
-    @SuppressWarnings("unused")
-    @OneToMany(fetch = FetchType.LAZY, mappedBy = "sampleDerivedFrom")
-    @ContainedIn
-    private Set<DataPE> getDerivedDatasets()
-    {
-        return derivedDatasets;
-    }
-
-    @SuppressWarnings("unused")
-    private void setDerivedDatasets(Set<DataPE> derivedDatasets)
-    {
-        this.derivedDatasets = derivedDatasets;
-    }
-
-    // --------------------
-
     @ManyToOne(fetch = FetchType.EAGER)
     @JoinColumn(name = ColumnNames.INVALIDATION_COLUMN)
     public InvalidationPE getInvalidation()
-- 
GitLab