]> SALOME platform Git repositories - tools/siman.git/blobdiff - Workspace/Siman-Common/src/org/splat/dal/bo/som/ProjectElement.java
Salome HOME
Refactoring continues: UserService is created instead of UserDirectory. Database...
[tools/siman.git] / Workspace / Siman-Common / src / org / splat / dal / bo / som / ProjectElement.java
index 7bf47337a1619cf1ae7034da60ff138283bc1460..9e8655d23ad4203e7443867d00a9dd9589e4e64d 100644 (file)
@@ -16,7 +16,6 @@ import java.util.Vector;
 import org.apache.log4j.Logger;
 
 import org.splat.dal.bo.kernel.User;
-import org.splat.dal.dao.som.Database;
 import org.splat.kernel.ObjectProperties;
 import org.splat.kernel.InvalidPropertyException;
 import org.splat.kernel.MissedPropertyException;
@@ -178,21 +177,11 @@ public abstract class ProjectElement extends Entity {
 //  --------------------------------------------------
       return  contex.remove(oldoc);
     }
-
-/**
- * Refreshes the internal data potentially out-of-date.
- * This function needs to be called when Publication objects are added to this Project Element before being saved. The reason is,
- * as saving a persistent object changes its hashcode, hashed data need to be rebuilt after saving for making functions based
- * on this hashcode such as remove(), working.
- */
-    public void refresh () {
-//  -------------------------
-      Publication[] curdoc = docums.toArray(new Publication[docums.size()]);
-
-      folders = null;                 // Just in case
-      docums.clear();
-      for (int i=0; i<curdoc.length; i++) docums.add(curdoc[i]);
-//    No need to rebuild the list of SimulationContext as it does not use hashcodes
-      Database.getSession().update(this);
-    }
+       /**
+        * Get the docums.
+        * @return the docums
+        */
+       public Set<Publication> getDocums() {
+               return docums;
+       }
 }
\ No newline at end of file