]> SALOME platform Git repositories - modules/yacs.git/commitdiff
Salome HOME
- Deleted Study as an input parameter and class field.
authormpa <mpa@opencascade.com>
Tue, 31 Jan 2017 08:48:58 +0000 (11:48 +0300)
committermpa <mpa@opencascade.com>
Tue, 31 Jan 2017 08:48:58 +0000 (11:48 +0300)
- Deleted methods GetStudy from Study and SObject interfaces

33 files changed:
idl/SALOMEDS.idl
src/KernelHelpers/SALOME_StudyEditor.cxx
src/KernelHelpers/SALOME_StudyEditor.hxx
src/SALOMEDS/CMakeLists.txt
src/SALOMEDS/SALOMEDS.cxx
src/SALOMEDS/SALOMEDS_Client.cxx
src/SALOMEDS/SALOMEDS_IParameters.cxx
src/SALOMEDS/SALOMEDS_IParameters.hxx
src/SALOMEDS/SALOMEDS_SObject.cxx
src/SALOMEDS/SALOMEDS_SObject.hxx
src/SALOMEDS/SALOMEDS_SObject_i.cxx
src/SALOMEDS/SALOMEDS_SObject_i.hxx
src/SALOMEDS/SALOMEDS_Server.cxx
src/SALOMEDS/SALOMEDS_Study.cxx
src/SALOMEDS/SALOMEDS_Study.hxx
src/SALOMEDS/SALOMEDS_Study_i.cxx
src/SALOMEDS/SALOMEDS_Study_i.hxx
src/SALOMEDS/Test/SALOMEDSTest_SObject.cxx
src/SALOMEDS/Test/SALOMEDSTest_Study.cxx
src/SALOMEDSClient/SALOMEDSClient_ClientFactory.cxx
src/SALOMEDSClient/SALOMEDSClient_ClientFactory.hxx
src/SALOMEDSClient/SALOMEDSClient_IParameters.hxx
src/SALOMEDSClient/SALOMEDSClient_SObject.hxx
src/SALOMEDSClient/SALOMEDSClient_Study.hxx
src/SALOMEDSImpl/SALOMEDSImpl_AttributeIOR.cxx
src/SALOMEDSImpl/SALOMEDSImpl_GenericAttribute.cxx
src/SALOMEDSImpl/SALOMEDSImpl_IParameters.cxx
src/SALOMEDSImpl/SALOMEDSImpl_IParameters.hxx
src/SALOMEDSImpl/SALOMEDSImpl_SObject.cxx
src/SALOMEDSImpl/SALOMEDSImpl_SObject.hxx
src/SALOMEDSImpl/SALOMEDSImpl_Study.cxx
src/SALOMEDSImpl/SALOMEDSImpl_Study.hxx
src/SALOMEDSImpl/SALOMEDSImpl_UseCaseBuilder.cxx

index c193837dbb0a80dca6bdd9afa2fbda62b11883d6..bc22b3d339437d8859e606cefd945c9eadf4b7d1 100644 (file)
@@ -408,8 +408,6 @@ Searches for a definite %SObject with a definite GUID and returns True if it fin
     typedef sequence<SObject> ListOfSObject;
 //!  Get the persistent reference to the %Study.
     PersistentReference  GetPersistentReference() raises(StudyInvalidReference);
-//! Get a transient reference to the %Study.
-    SalomeReference      GetTransientReference() raises(StudyInvalidReference);
 
 /*! \brief indicate whether the %Study is empty
 
@@ -924,11 +922,6 @@ Searches for a definite %SObject with a definite GUID and returns True if it fin
 */
     ListOfAttributes     GetAllAttributes();
 
-/*! Gets the study of a given %SObject.
-    \return The study containing the given %SObject.
-*/
-    Study GetStudy();
-
 /*! Gets the CORBA object by its own IOR attribute.
     Returns nil, if can't.
     \return The CORBA object of the %SObject.
index fe79af59de6d677b5ed284827602a6f422c14da9..39199d4a998a2ff0f36f1561e11ed223e310ccaa 100644 (file)
 
 /** Canonic constructor. The object can't be used without a setStudy() */
 SALOME_StudyEditor::SALOME_StudyEditor() {
-}
-
-void SALOME_StudyEditor::setStudy(SALOMEDS::Study_ptr study) {
-  _study = study;
-  _sbuilder = _study->NewBuilder();    
-}
-
-SALOME_StudyEditor::SALOME_StudyEditor(SALOMEDS::Study_ptr study) {
-  this->setStudy(study);
+  _sbuilder = KERNEL::getStudy()->NewBuilder();
 }
 
 SALOMEDS::SObject_ptr SALOME_StudyEditor::newObject(SALOMEDS::SObject_ptr parent) {
@@ -39,7 +31,7 @@ SALOMEDS::SObject_ptr SALOME_StudyEditor::newObject(SALOMEDS::SObject_ptr parent
 }
 
 SALOMEDS::SObject_ptr SALOME_StudyEditor::findObject(const char * entry) {
-  SALOMEDS::SObject_var sobject = _study->FindObjectID(entry);
+  SALOMEDS::SObject_var sobject = KERNEL::getStudy()->FindObjectID(entry);
   return sobject._retn();
 }
 
@@ -66,7 +58,7 @@ bool SALOME_StudyEditor::bindEngine(SALOMEDS::SComponent_var studyRoot,
 }
 
 SALOMEDS::SComponent_ptr SALOME_StudyEditor::findRoot(const char * moduleName) {
-  return _study->FindComponent(moduleName);
+  return KERNEL::getStudy()->FindComponent(moduleName);
 }
 
 void SALOME_StudyEditor::setName(SALOMEDS::SObject_var sobject, const char * value) {
index 52b98fc5ad891ec75e5f264f1d99315ed1804d13..334f953b944101fe028df42ccb25fc60cc81340a 100644 (file)
@@ -32,7 +32,7 @@
 class KERNELHELPERS_EXPORT SALOME_StudyEditor {
 
 public:
-  SALOME_StudyEditor(SALOMEDS::Study_ptr study);
+  SALOME_StudyEditor();
 
   typedef std::vector<SALOMEDS::SObject_ptr> SObjectList;
 
@@ -54,12 +54,6 @@ public:
 
   static const int UNDEFINED = -1;
 
-protected:
-  SALOME_StudyEditor();
-  void setStudy(SALOMEDS::Study_ptr study);
-
-  SALOMEDS::Study_var _study;
-
 private:
   SALOMEDS::StudyBuilder_var _sbuilder;
 };
index 68c5a4b8be190622b0f56d01ad16002f433c9281..14ae8420828a8c3b19890c6189b0e76a25333661 100755 (executable)
@@ -57,6 +57,7 @@ SET(COMMON_LIBS
   SalomeGenericObj
   SalomeLifeCycleCORBA
   SalomeIDLKernel
+  SalomeDSClient
   ${HDF5_C_LIBRARIES}
 )
 
index 4324440853387c8cd0d7c34b83aa0c8cb10e9709..2d86b26de6f34157141879e41fcbb2e5891d8db9 100644 (file)
@@ -116,10 +116,6 @@ extern "C"
       PortableServer::ObjectId_var aStudy_iid =  root_poa->activate_object(aStudy_i);
       aStudy = aStudy_i->_this();
       namingService.Register(aStudy, "/Study");
-
-      // Assign the value of the IOR in the study->root
-      CORBA::String_var IORStudy = orb->object_to_string(aStudy);
-      aStudy_i->GetImpl()->SetTransientReference((char*)IORStudy.in());
       aStudy_i->GetImpl()->GetDocument()->SetModified(false);
       aStudy_i->_remove_ref();
     }
@@ -140,15 +136,6 @@ extern "C"
     return so->GetSObject();
   }
 
-  SALOMEDS_EXPORT
-  SALOMEDS::Study_ptr ConvertStudy(const _PTR(Study)& theStudy)
-  {
-    SALOMEDS_Study* study = _CAST(Study, theStudy);
-    if ( !theStudy || !study )
-      return SALOMEDS::Study::_nil();
-    return study->GetStudy();
-  }
-
   SALOMEDS_EXPORT
   SALOMEDS::StudyBuilder_ptr ConvertBuilder(const _PTR(StudyBuilder)& theBuilder)
   {
index 1f5ef1d3a341bdd6c398f46e2e131064f4399821..29f9ba1a2d804fd130ae08e31f066da3e37dd258 100644 (file)
@@ -29,7 +29,7 @@
 #include <SALOMEconfig.h>
 #include CORBA_SERVER_HEADER(SALOMEDS)
 #include "SALOMEDS_AttributeName_i.hxx"
-#include "SALOME_NamingService.hxx"
+#include "SALOME_KernelServices.hxx"
 #include "utilities.h"
 #include "HDFOI.hxx"
 
@@ -38,9 +38,9 @@
  *  Purpose  : 
  */
 //============================================================================
-static void DumpComponent(SALOMEDS::Study_ptr Study,SALOMEDS::SObject_ptr SO, int offset) {
+static void DumpComponent(SALOMEDS::SObject_ptr SO, int offset) {
   SALOMEDS::SObject_var RefSO;
-  SALOMEDS::ChildIterator_var it = Study->NewChildIterator(SO);
+  SALOMEDS::ChildIterator_var it = KERNEL::getStudy()->NewChildIterator(SO);
   for (; it->More();it->Next()){
     SALOMEDS::SObject_var CSO= it->Value();
     SALOMEDS::GenericAttribute_var anAttr;
@@ -57,7 +57,7 @@ static void DumpComponent(SALOMEDS::Study_ptr Study,SALOMEDS::SObject_ptr SO, in
         MESSAGE(" ");
       MESSAGE("*Reference"<<RefSO->GetID());
     }
-    DumpComponent(Study,CSO,offset+2);
+    DumpComponent(CSO,offset+2);
   }
 }
 
@@ -66,17 +66,17 @@ static void DumpComponent(SALOMEDS::Study_ptr Study,SALOMEDS::SObject_ptr SO, in
  *  Purpose  : 
  */
 //============================================================================
-static void DumpStudy (SALOMEDS::Study_ptr Study) {
+static void DumpStudy() {
   MESSAGE("Explore Study and Write name of each object if it exists");
   
   char* name;
-  SALOMEDS::SComponentIterator_var itcomp = Study->NewComponentIterator();
+  SALOMEDS::SComponentIterator_var itcomp = KERNEL::getStudy()->NewComponentIterator();
   int offset = 1;
   for (; itcomp->More(); itcomp->Next()) {
     SALOMEDS::SComponent_var SC = itcomp->Value();
     name = SC->ComponentDataType();
     MESSAGE("-> ComponentDataType is "<<name);  
-    DumpComponent(Study,SC,offset);
+    DumpComponent(SC,offset);
   }
 }
 
@@ -85,11 +85,13 @@ static void DumpStudy (SALOMEDS::Study_ptr Study) {
  *  Purpose  : 
  */
 //============================================================================
-static void Test(SALOMEDS::Study_ptr myStudy)
+static void Test()
 {
   try {
   char* name;
 
+  SALOMEDS::Study_var myStudy = KERNEL::getStudy();
+
   MESSAGE("Create Builder ");
   SALOMEDS::StudyBuilder_var StudyBuild = myStudy->NewBuilder();
 
@@ -183,15 +185,11 @@ static void Test(SALOMEDS::Study_ptr myStudy)
   Name->SetValue("mesh_cylinder_0");
   StudyBuild->CommitCommand();
 
-  MESSAGE("Test GetStudy");
-  SALOMEDS::Study_var stu = mesh_cylinder->GetStudy();
-  MESSAGE ("-> Study Name is "<<stu->Name());
-
-  DumpStudy(myStudy);
+  DumpStudy();
 
   StudyBuild->Undo();
   // Study should have no trace of object mesh_cylinder
-  DumpStudy(myStudy);
+  DumpStudy();
   
   // Save as
   myStudy->SaveAs("/home/edeville/Study1.hdf", false, false);
@@ -200,10 +198,6 @@ static void Test(SALOMEDS::Study_ptr myStudy)
   name = myStudy->GetPersistentReference();
   MESSAGE("Persitent Reference of the study " << name);
 
-  // Get Transient Reference of the study test
-  name = myStudy->GetTransientReference();
-  MESSAGE("Transient Reference of the study " << name);
-
   // FindComponent Test
   SALOMEDS::SComponent_var compo = myStudy->FindComponent("GEOM");
   // Get ComponentDataType test
@@ -243,7 +237,7 @@ static void Test(SALOMEDS::Study_ptr myStudy)
   else {
     MESSAGE("-> Name is not found");
   }
-  //DumpStudy(myStudy);
+  //DumpStudy();
   }
   catch(HDFexception)
     {
@@ -267,21 +261,14 @@ int main(int argc, char** argv)
     CORBA::Object_var obj = orb->resolve_initial_references("RootPOA");
     PortableServer::POA_var poa = PortableServer::POA::_narrow(obj);
 
-    SALOME_NamingService * salomens = new SALOME_NamingService(orb);
-
-    MESSAGE("Find Study ");
-    CORBA::Object_ptr obj2 = salomens->Resolve("/Study");
-    SALOMEDS::Study_var myStudy = SALOMEDS::Study::_narrow(obj2);
-
     // Obtain a POAManager, and tell the POA to start accepting
     // requests on its objects.
     PortableServer::POAManager_var pman = poa->the_POAManager();
     pman->activate();
 
     // Test basic services
-    Test(myStudy);
+    Test();
 
-    delete salomens;
     orb->run();
     orb->destroy();
   }
index 8329a78ef93074330c02e6d50523aea18261f2a4..8439c8b0d31c71dec506c44045bacfdf895dd246 100644 (file)
@@ -21,6 +21,8 @@
 //
 
 #include "SALOMEDS_IParameters.hxx"
+#include <SALOMEDSClient_ClientFactory.hxx>
+#include <SALOME_KernelServices.hxx>
 #include <utilities.h>
 
 #define PT_INTEGER   0
@@ -46,8 +48,6 @@ SALOMEDS_IParameters::SALOMEDS_IParameters(const _PTR(AttributeParameter)& ap)
 {
   if(!ap) return;
   _ap = ap;
-  _PTR(SObject) so = _ap->GetSObject();
-  _study = so->GetStudy();
 }
 
 SALOMEDS_IParameters::~SALOMEDS_IParameters()
@@ -258,14 +258,13 @@ std::string SALOMEDS_IParameters::encodeEntry(const std::string& entry, const st
 
 std::string SALOMEDS_IParameters::decodeEntry(const std::string& entry)
 {
-  if(!_study) return entry;
   int pos = entry.rfind("_");
   if(pos < 0 || pos >= entry.length()) return entry;
 
   std::string compName(entry, 0, pos), compID, tail(entry, pos+1, entry.length()-1);
   
   if(_compNames.find(compName) == _compNames.end()) {
-    _PTR(SObject) so = _study->FindComponent(compName);
+    _PTR(SObject) so = ClientFactory::Study(KERNEL::getStudy())->FindComponent(compName);
     if(!so) return entry;
     compID = so->GetID();
     _compNames[compName] = compID;
@@ -278,23 +277,23 @@ std::string SALOMEDS_IParameters::decodeEntry(const std::string& entry)
   return newEntry;
 }
 
-void SALOMEDS_IParameters::setDumpPython(_PTR(Study) study, const std::string& theID)
+void SALOMEDS_IParameters::setDumpPython(const std::string& theID)
 {
   std::string anID;
   if(theID == "") anID = getDefaultVisualComponent();
   else anID = theID;
 
-  _PTR(AttributeParameter) ap = study->GetCommonParameters(anID, 0);
-  ap->SetBool(_AP_DUMP_PYTHON_, !isDumpPython(study, theID));
+  _PTR(AttributeParameter) ap = ClientFactory::Study(KERNEL::getStudy())->GetCommonParameters(anID, 0);
+  ap->SetBool(_AP_DUMP_PYTHON_, !isDumpPython(theID));
 }
 
-bool SALOMEDS_IParameters::isDumpPython(_PTR(Study) study, const std::string& theID)
+bool SALOMEDS_IParameters::isDumpPython(const std::string& theID)
 {
   std::string anID;
   if(theID == "") anID = getDefaultVisualComponent();
   else anID = theID;
 
-  _PTR(AttributeParameter) ap = study->GetCommonParameters(anID, 0);
+  _PTR(AttributeParameter) ap = ClientFactory::Study(KERNEL::getStudy())->GetCommonParameters(anID, 0);
   if(!ap) return false;
   if(!ap->IsSet(_AP_DUMP_PYTHON_, PT_BOOLEAN)) return false;
   return (bool)ap->GetBool(_AP_DUMP_PYTHON_);
index 24468d0113ce2d265f9a8762b120f9ed75adf700..197eace7d34154c9c367506f4361ae23917f865a 100644 (file)
@@ -142,12 +142,12 @@ public:
   /*!
     Enables/Disables the dumping visual parameters
    */
-  virtual void setDumpPython(_PTR(Study) study, const std::string& theID = "");
+  virtual void setDumpPython(const std::string& theID = "");
 
   /*!
     Returns whether there is the dumping visual parameters
    */
-  virtual bool isDumpPython(_PTR(Study) study, const std::string& theID = "");  
+  virtual bool isDumpPython(const std::string& theID = "");
 
   /*!
     Returns a default name of the component where the visula parameters are stored.
@@ -156,7 +156,6 @@ public:
 
 private:
   _PTR(AttributeParameter) _ap;
-  _PTR(Study) _study;
   std::map<std::string, std::string> _compNames;
 };
 
index 2a6adb8c4137731965924abc38be0ec17c6e72a4..6f3332f6b6314f60949f669231ae157572a38bba 100644 (file)
@@ -196,16 +196,6 @@ bool SALOMEDS_SObject::FindSubObject(int theTag, _PTR(SObject)& theObject)
   return ret;   
 }
 
-_PTR(Study) SALOMEDS_SObject::GetStudy()
-{
-  if (_isLocal) {
-    SALOMEDS::Locker lock;
-    return _PTR(Study)(new SALOMEDS_Study(_local_impl->GetStudy()));
-  }
-  SALOMEDS::Study_var study=_corba_impl->GetStudy();
-  return _PTR(Study)(new SALOMEDS_Study(study));
-}
-
 std::string SALOMEDS_SObject::Name()
 {
   std::string aName;
index 4635829ae82001af6f268883c297c67876fa62d5..da8bf79fd699d81506be3bb164f74169187649bc 100644 (file)
@@ -60,7 +60,6 @@ public:
   virtual bool FindAttribute(_PTR(GenericAttribute)& anAttribute, const std::string& aTypeOfAttribute);
   virtual bool ReferencedObject(_PTR(SObject)& theObject);
   virtual bool FindSubObject(int theTag, _PTR(SObject)& theObject);
-  virtual _PTR(Study) GetStudy();
   virtual std::string Name();
   virtual void  Name(const std::string& theName);
   virtual std::vector<_PTR(GenericAttribute)> GetAllAttributes();
index 0378e30036f471717206c14d40b24dc1003105d1..2cf28a4cc388ef647e5fb7b153f065dd9d8fcaf6 100644 (file)
@@ -130,27 +130,6 @@ SALOMEDS::SObject_ptr SALOMEDS_SObject_i::GetFather()
   return so._retn();
 }
 
-//============================================================================
-/*! Function :
- *  Purpose  :
- */
-//============================================================================
-SALOMEDS::Study_ptr SALOMEDS_SObject_i::GetStudy()
-{
-  SALOMEDS::Locker lock;
-  SALOMEDSImpl_Study* aStudy = _impl->GetStudy();
-  if(!aStudy) {
-    MESSAGE("Problem GetStudy");
-    return SALOMEDS::Study::_nil();
-  }
-
-  std::string IOR = aStudy->GetTransientReference();
-  CORBA::Object_var obj = _orb->string_to_object(IOR.c_str());
-  SALOMEDS::Study_var Study = SALOMEDS::Study::_narrow(obj) ;
-  ASSERT(!CORBA::is_nil(Study));
-  return SALOMEDS::Study::_duplicate(Study);
-}
-
 //============================================================================
 /*! Function : FindAttribute
  *  Purpose  : Find attribute of given type on this SObject
index f996197fb2f8e70a41e5a63a82a9b05030b778f8..fea6ecab604db64433dc9a35d6530332c6c23848 100644 (file)
@@ -62,7 +62,6 @@ public:
   virtual CORBA::Boolean ReferencedObject(SALOMEDS::SObject_out obj) ;
   virtual CORBA::Boolean FindSubObject(CORBA::Long atag, SALOMEDS::SObject_out obj );
 
-  virtual SALOMEDS::Study_ptr    GetStudy() ;
   virtual char* Name();
   virtual void  Name(const char*);
   virtual SALOMEDS::ListOfAttributes* GetAllAttributes();
index addbbba1af426dca841cefbb67355a19f88eea4d..e973353876f99b5ff4614fb55575047c48b9e954 100644 (file)
@@ -167,13 +167,6 @@ int main(int argc, char** argv)
         NS->init_orb( orb );
       }
       NS->Register(Study, "/Study");
-
-      // Assign the value of the IOR in the study->root
-      if ( myStudy_i->GetImpl()->GetTransientReference().empty() ) {
-        CORBA::String_var IORStudy = orb->object_to_string(Study);
-        myStudy_i->GetImpl()->SetTransientReference((char*)IORStudy.in());
-      }
-
       myStudy_i->_remove_ref();
        
       // Obtain a POAManager, and tell the POA to start accepting
index c197b66a67d8fc7fa895162c332a1dedfcff48fd..0583c10cacbac8fc165140fbcb3cd25b51b0a0f5 100644 (file)
@@ -134,13 +134,17 @@ bool SALOMEDS_Study::Open(const std::string& theStudyUrl)
 
 bool SALOMEDS_Study::Save(bool theMultiFile, bool theASCII)
 {
-  //SRN: Pure CORBA save as the save operation require CORBA in any case
+  if(CORBA::is_nil(_corba_impl))
+    return false;
+
   return _corba_impl->Save(theMultiFile, theASCII);
 }
 
 bool SALOMEDS_Study::SaveAs(const std::string& theUrl, bool theMultiFile, bool theASCII)
 {
-  //SRN: Pure CORBA save as the save operation require CORBA in any case
+  if(CORBA::is_nil(_corba_impl))
+    return false;
+
   return _corba_impl->SaveAs((char*)theUrl.c_str(), theMultiFile, theASCII);
 }
 
@@ -253,17 +257,6 @@ std::string SALOMEDS_Study::GetPersistentReference()
   else aRef = (CORBA::String_var)_corba_impl->GetPersistentReference();
   return aRef;
 }
-
-std::string SALOMEDS_Study::GetTransientReference()
-{
-  std::string aRef;
-  if (_isLocal) {
-    SALOMEDS::Locker lock;
-    aRef = _local_impl->GetTransientReference();
-  }
-  else aRef = _corba_impl->GetTransientReference();
-  return aRef;
-}
  
 bool SALOMEDS_Study::IsEmpty()
 {
@@ -658,10 +651,10 @@ bool SALOMEDS_Study::DumpStudy(const std::string& thePath,
                                bool isPublished,
                                bool isMultiFile)
 {
-  //SRN: Pure CORBA DumpStudy as it does more cleaning than the local one
-  if(CORBA::is_nil(_corba_impl)) GetStudy(); //If CORBA implementation is null then retrieve it
-  bool ret = _corba_impl->DumpStudy(thePath.c_str(), theBaseName.c_str(), isPublished, isMultiFile);
-  return ret;
+  if(CORBA::is_nil(_corba_impl))
+    return false;
+
+  return _corba_impl->DumpStudy(thePath.c_str(), theBaseName.c_str(), isPublished, isMultiFile);
 }     
 
 void SALOMEDS_Study::SetStudyLock(const std::string& theLockerID)
@@ -962,36 +955,6 @@ CORBA::Object_ptr SALOMEDS_Study::ConvertIORToObject(const std::string& theIOR)
   return _orb->string_to_object(theIOR.c_str()); 
 } 
 
-SALOMEDS::Study_ptr SALOMEDS_Study::GetStudy()
-{
-  if (_isLocal) {
-    SALOMEDS::Locker lock;
-
-    if (!CORBA::is_nil(_corba_impl)) return SALOMEDS::Study::_duplicate(_corba_impl);
-    std::string anIOR = _local_impl->GetTransientReference();
-    SALOMEDS::Study_var aStudy;
-    if (!_local_impl->IsError() && anIOR != "") {
-      aStudy = SALOMEDS::Study::_narrow(_orb->string_to_object(anIOR.c_str()));
-    }
-    else {
-      SALOME_NamingService* namingService = KERNEL::getNamingService();
-      CORBA::Object_var obj = namingService->Resolve("/Study");
-      aStudy = SALOMEDS::Study::_narrow(obj);
-      if( !CORBA::is_nil( aStudy ) )  { 
-        _local_impl->SetTransientReference(_orb->object_to_string(aStudy));
-      }
-    }
-    _corba_impl = SALOMEDS::Study::_duplicate(aStudy);
-    return aStudy._retn();
-  }
-  else {
-    return SALOMEDS::Study::_duplicate(_corba_impl);
-  }
-
-  return SALOMEDS::Study::_nil();
-}
-
-
 _PTR(AttributeParameter) SALOMEDS_Study::GetCommonParameters(const std::string& theID, int theSavePoint)
 {
   SALOMEDSClient_AttributeParameter* AP = NULL;
@@ -1025,12 +988,16 @@ _PTR(AttributeParameter) SALOMEDS_Study::GetModuleParameters(const std::string&
 
 void SALOMEDS_Study::attach(SALOMEDS::Observer_ptr theObserver,bool modify)
 {
-  if(CORBA::is_nil(_corba_impl)) GetStudy(); //If CORBA implementation is null then retrieve it
+  if(CORBA::is_nil(_corba_impl))
+    return;
+
   _corba_impl->attach(theObserver,modify);
 }
 
 void SALOMEDS_Study::detach(SALOMEDS::Observer_ptr theObserver)
 {
-  if(CORBA::is_nil(_corba_impl)) GetStudy(); //If CORBA implementation is null then retrieve it
+  if(CORBA::is_nil(_corba_impl))
+    return;
+
   _corba_impl->detach(theObserver);
 }
index d7231e139ebe4fdb0bc4d6e72bfc61c85448d5ea..4f3b6db1fcb544d28f9b92875d01ab64e14f9ff7 100644 (file)
@@ -66,7 +66,6 @@ public:
   virtual _PTR(SObject) Paste(const _PTR(SObject)& theSO);
 
   virtual std::string GetPersistentReference();
-  virtual std::string GetTransientReference();
   virtual bool IsEmpty();
   virtual _PTR(SComponent) FindComponent (const std::string& aComponentName);
   virtual _PTR(SComponent) FindComponentID(const std::string& aComponentID);
@@ -130,8 +129,6 @@ public:
 
   std::string ConvertObjectToIOR(CORBA::Object_ptr theObject);
   CORBA::Object_ptr ConvertIORToObject(const std::string& theIOR);     
-
-  SALOMEDS::Study_ptr GetStudy();
   
   SALOMEDSImpl_Study* GetLocalImpl() { return _local_impl; }
 
index cdd6dd3b90292e85557c34f129ce9bdc37b4871f..cd586ec2f80023d78afc04392e2afcadf5bd4b98 100644 (file)
@@ -288,16 +288,6 @@ void SALOMEDS_Study_i::Init()
     aSession->emitMessageOneWay(str.c_str());
     SALOMEDS::lock();
   }
-
-  std::string anIOR = _impl->GetTransientReference();
-  if ( anIOR.empty() ) {
-    CORBA::Object_var obj = aNamingService->Resolve("/Study");
-    SALOMEDS::Study_var aStudy = SALOMEDS::Study::_narrow( obj );
-    CORBA::String_var IORStudy = _orb->object_to_string(aStudy);
-    _impl->SetTransientReference((char*)IORStudy.in());
-  }
-  _impl->GetDocument()->SetModified(false);
-
 }
 
 //============================================================================
@@ -543,18 +533,6 @@ char* SALOMEDS_Study_i::GetPersistentReference()
     throw SALOMEDS::Study::StudyInvalidReference();  
   return CORBA::string_dup(_impl->GetPersistentReference().c_str());
 }
-//============================================================================
-/*! Function : GetTransientReference
- *  Purpose  : Get IOR of the Study (registred in OCAF document in doc->Root)
- */
-//============================================================================
-char* SALOMEDS_Study_i::GetTransientReference()
-{
-  SALOMEDS::Locker lock; 
-  if (_closed)
-    throw SALOMEDS::Study::StudyInvalidReference();  
-  return CORBA::string_dup(_impl->GetTransientReference().c_str());
-}
 
 //============================================================================
 /*! Function : IsEmpty
@@ -949,23 +927,6 @@ void SALOMEDS_Study_i::UpdateIORLabelMap(const char* anIOR, const char* anEntry)
   _impl->UpdateIORLabelMap(std::string((char*)anIOR), std::string((char*)anEntry));
 }
 
-SALOMEDS::Study_ptr SALOMEDS_Study_i::GetStudy(const DF_Label& theLabel, CORBA::ORB_ptr orb)
-{
-  SALOMEDS::Locker lock;
-
-  SALOMEDSImpl_AttributeIOR* Att = NULL;
-  if ((Att=(SALOMEDSImpl_AttributeIOR*)theLabel.Root().FindAttribute(SALOMEDSImpl_AttributeIOR::GetID()))){
-    char* IOR = CORBA::string_dup(Att->Value().c_str());
-    CORBA::Object_var obj = orb->string_to_object(IOR);
-    SALOMEDS::Study_ptr aStudy = SALOMEDS::Study::_narrow(obj) ;
-    ASSERT(!CORBA::is_nil(aStudy));
-    return SALOMEDS::Study::_duplicate(aStudy);
-  } else {
-    MESSAGE("GetStudy: Problem to get study");
-  }
-  return SALOMEDS::Study::_nil();
-}
-
 void SALOMEDS_Study_i::IORUpdated(SALOMEDSImpl_AttributeIOR* theAttribute) 
 {
   SALOMEDS::Locker lock; 
index 18a8f0d666e0db5ca07de55b7f04946fa4bad125..232b0fb4cadfaaae13362c299e5f5bd91402d9fe 100644 (file)
@@ -107,13 +107,6 @@ public:
   */  
   virtual char* GetPersistentReference();
 
-
-  //! method to Get transient reference of study
-  /*!
-    \return char* arguments, the transient reference of the study
-  */  
-  virtual char* GetTransientReference();
-
   //! method to detect if a study is empty
   /*!
     \return bool arguments, true if study is empty
@@ -244,8 +237,6 @@ public:
   */
   virtual void  URL(const char* url);
 
-  static SALOMEDS::Study_ptr GetStudy(const DF_Label& theLabel, CORBA::ORB_ptr orb);
-
   static void IORUpdated(SALOMEDSImpl_AttributeIOR* theAttribute);
 
   virtual void UpdateIORLabelMap(const char* anIOR, const char* aLabel);
index 2899ce0380ab83068d1d7e21814efb7efd5dd24b..4da0748a895d15b16a064e9e4e4bdc18e197deb1 100755 (executable)
@@ -87,9 +87,6 @@ void SALOMEDSTest::testSObject()
   CPPUNIT_ASSERT(so->FindSubObject(1, so2));
   CPPUNIT_ASSERT(so2->GetID() == so1->GetID());
 
-  //Check method GetStudy
-  CPPUNIT_ASSERT(so->GetStudy() == study);
-
   //Check methods Name
   so->Name("test");
   CPPUNIT_ASSERT(so->Name() == "test");
index dbf65e2e601696e1fa1ce27e4a0df2622041ab03..3c1574cc94b279aaa22d284d64f6857a102cc17a 100755 (executable)
@@ -42,9 +42,6 @@ void SALOMEDSTest::testStudy()
 
   CPPUNIT_ASSERT(componentIterator);
 
-  //Check method GetTransientReference
-  CPPUNIT_ASSERT(!study->GetTransientReference().empty());
-
   //Check method URL (get/set)
   study->URL("");
   CPPUNIT_ASSERT(study->URL() == "");
index 77d1861b754aa8c0f54aff494bbf3d8005f4a7a8..344abda6d2e0ee3d3f0fc4702027f74733712eba 100644 (file)
@@ -39,7 +39,6 @@ static void* _libHandle = NULL;
 #define BUILDER_FACTORY      "BuilderFactory"
 #define GET_PARAMETERS       "GetIParameters"
 #define CONVERT_SOBJECT      "ConvertSObject"
-#define CONVERT_STUDY        "ConvertStudy"
 #define CONVERT_BUILDER      "ConvertBuilder"
 
 typedef SALOMEDSClient_SObject* (*SOBJECT_FACTORY_FUNCTION) (SALOMEDS::SObject_ptr);
@@ -49,7 +48,6 @@ typedef void                  (*STUDY_CREATE_FUNCTION) (CORBA::ORB_ptr, Portable
 typedef SALOMEDSClient_StudyBuilder* (*BUILDER_FACTORY_FUNCTION) (SALOMEDS::StudyBuilder_ptr);
 typedef SALOMEDSClient_IParameters* (*GET_PARAMETERS_FACTORY) (const _PTR(AttributeParameter)&);
 typedef SALOMEDS::SObject_ptr (*CONVERT_SOBJECT_FUNCTION) (const _PTR(SObject)&);
-typedef SALOMEDS::Study_ptr (*CONVERT_STUDY_FUNCTION) (const _PTR(Study)&);
 typedef SALOMEDS::StudyBuilder_ptr (*CONVERT_BUILDER_FUNCTION) (const _PTR(StudyBuilder)&);
 
 
@@ -60,7 +58,6 @@ static STUDY_CREATE_FUNCTION aCreateFactory = NULL;
 static BUILDER_FACTORY_FUNCTION aBuilderFactory = NULL;
 static GET_PARAMETERS_FACTORY aGetIParameters = NULL;
 static CONVERT_SOBJECT_FUNCTION aConvertSObject = NULL;
-static CONVERT_STUDY_FUNCTION aConvertStudy = NULL;
 static CONVERT_BUILDER_FUNCTION aConvertBuilder = NULL;
 
 _PTR(SObject) ClientFactory::SObject(SALOMEDS::SObject_ptr theSObject)
@@ -174,25 +171,6 @@ SALOMEDS::SObject_ptr ClientFactory::crbSObject(const _PTR(SObject)& theSObject)
   return so._retn();
 }
 
-
-SALOMEDS::Study_ptr ClientFactory::crbStudy(const _PTR(Study)& theStudy)
-{
-  SALOMEDS::Study_var study;
-
-#ifdef WIN32
-  if(!_libHandle) _libHandle = ::LoadLibrary(SALOMEDS_LIB_NAME);
-  if(!aConvertStudy) aConvertStudy = (CONVERT_STUDY_FUNCTION)::GetProcAddress(_libHandle, CONVERT_STUDY);
-#else
-  if(!_libHandle) _libHandle = dlopen(SALOMEDS_LIB_NAME, RTLD_LAZY | RTLD_GLOBAL);
-  if(!aConvertStudy) aConvertStudy = (CONVERT_STUDY_FUNCTION) dlsym(_libHandle, CONVERT_STUDY);
-#endif
-
-  if(aConvertStudy) study = aConvertStudy(theStudy); 
-  
-  if(CORBA::is_nil(study)) return SALOMEDS::Study::_nil();
-  return study._retn();
-}
-
 SALOMEDS::StudyBuilder_ptr ClientFactory::crbStudyBuilder(const _PTR(StudyBuilder)& theStudyBuilder)
 {
   SALOMEDS::StudyBuilder_var studyBuilder;
index 6e4afdf4331bbdaf5528fc4352ee737a7ae927da..6293ce2941aa57cb0a6561ff8a8b1a073eb7f4c6 100644 (file)
@@ -79,11 +79,6 @@ public:
    */
   static SALOMEDS::SObject_ptr crbSObject(const _PTR(SObject)& theSObject);
 
-  /*!
-   *  Returns a CORBA Study that corresponds %theStudy
-   */
-  static SALOMEDS::Study_ptr crbStudy(const _PTR(Study)& theStudy);  
-
   /*!
    *  Returns a CORBA StudyBuilder that corresponds %theStudyBuilder
    */
index 78a8fc6ace79cdfa6ee9aca8aaed3ec508ae3215..1ceaabe1e14769b06113b4d1b1f01cffa8a101fc 100644 (file)
@@ -141,12 +141,12 @@ public:
   /*!
     Enables/Disables the dumping visual parameters, static implementation is supposed
    */
-  virtual void setDumpPython(_PTR(Study) study, const std::string& theID = "") = 0;
+  virtual void setDumpPython(const std::string& theID = "") = 0;
 
   /*!
     Returns whether there is the dumping visual parameters, static implementation is supposed
    */
-  virtual bool isDumpPython(_PTR(Study) study, const std::string& theID = "") = 0;  
+  virtual bool isDumpPython(const std::string& theID = "") = 0;
 
   /*!
     Returns a default name of the component where the visula parameters are stored.
index 9aa5812b14a5bd91894f6f46d3b0c9f79af00ece..29840b7f39252b99b81270218b49c40f15cd13e2 100644 (file)
@@ -49,7 +49,6 @@ public:
   virtual bool FindAttribute(_PTR(GenericAttribute)& anAttribute, const std::string& aTypeOfAttribute) = 0;
   virtual bool ReferencedObject(_PTR(SObject)& theObject) = 0;
   virtual bool FindSubObject(int theTag, _PTR(SObject)& theObject) = 0;
-  virtual _PTR(Study) GetStudy() = 0;
   virtual std::string Name() = 0;
   virtual void  Name(const std::string& theName)  = 0;
   virtual std::vector<_PTR(GenericAttribute)> GetAllAttributes() = 0;
index d4ae8e61059075107c8e7e052465257b02c28fdf..8732b23d50c39a24acbf0857f5c3f7627c78aeb6 100644 (file)
@@ -55,7 +55,6 @@ public:
   virtual bool Open(const std::string& theStudyUrl) = 0;
 
   virtual std::string GetPersistentReference() = 0;
-  virtual std::string GetTransientReference() = 0;
   virtual bool IsEmpty() = 0;
   virtual _PTR(SComponent) FindComponent (const std::string& aComponentName) = 0;
   virtual _PTR(SComponent) FindComponentID(const std::string& aComponentID) = 0;
index f5c8ec76464fdf2898f38a0164eb7d744b78b6af..0b3a7564c1689c6c95cde4f176743e5f2f69b47c 100644 (file)
@@ -68,7 +68,7 @@ void SALOMEDSImpl_AttributeIOR::SetValue(const std::string& theValue)
   //remove IOR entry in study
   if(theValue != myString)
     {
-      SALOMEDSImpl_Study* study=SALOMEDSImpl_Study::GetStudy(Label());
+      SALOMEDSImpl_Study* study=SALOMEDSImpl_Study::GetStudyImpl(Label());
       study->RegisterGenObj(theValue, Label());
       study->UnRegisterGenObj(myString, Label());
       study->DeleteIORLabelMapItem(myString);
index 2813fbc9aba9ead50ccd844b436d8083b9310cf8..f74bb71b2e429b2c89ff2fab77d4e4955811791e 100644 (file)
@@ -63,7 +63,7 @@ void SALOMEDSImpl_GenericAttribute::CheckLocked()
   DF_Label aLabel = Label();
   if(aLabel.IsNull()) return;
 
-  SALOMEDSImpl_Study* aStudy = SALOMEDSImpl_Study::GetStudy(aLabel);
+  SALOMEDSImpl_Study* aStudy = SALOMEDSImpl_Study::GetStudyImpl(aLabel);
   if(!aStudy) return;
   if(aStudy->IsLocked()) {
     aStudy->_errorCode = "LockProtection";
@@ -88,7 +88,7 @@ void SALOMEDSImpl_GenericAttribute::SetModifyFlag(int reason)
    DF_Label aLabel = Label();
    if(aLabel.IsNull()) return; 
 
-  SALOMEDSImpl_Study* aStudy = SALOMEDSImpl_Study::GetStudy(aLabel);
+  SALOMEDSImpl_Study* aStudy = SALOMEDSImpl_Study::GetStudyImpl(aLabel);
   if(aStudy) aStudy->modifySO_Notification(GetSObject(), reason);
   if(aStudy) aStudy->Modify();
 }
index 38acf7d96e0605d7ed9624a35501d3f31e97db36..749c112bbc320f2fa44879d0771bf6630ec6a6cb 100644 (file)
@@ -40,8 +40,6 @@ SALOMEDSImpl_IParameters::SALOMEDSImpl_IParameters(SALOMEDSImpl_AttributeParamet
 {
   if(!ap) return;
   _ap = ap;
-  SALOMEDSImpl_SObject so = _ap->GetSObject();
-  _study = so.GetStudy();
 }
 
 SALOMEDSImpl_IParameters::~SALOMEDSImpl_IParameters()
@@ -222,14 +220,13 @@ std::vector<std::string> SALOMEDSImpl_IParameters::getProperties()
 
 std::string SALOMEDSImpl_IParameters::decodeEntry(const std::string& entry)
 {
-  if(!_study) return entry;
   int pos = entry.rfind("_");
   if(pos < 0 || pos >= entry.size()) return entry;
 
   std::string compName(entry, 0, pos), compID, tail(entry, pos+1, entry.length()-1);
   
   if(_compNames.find(compName) == _compNames.end()) {
-    SALOMEDSImpl_SObject so = _study->FindComponent(compName);
+    SALOMEDSImpl_SObject so = SALOMEDSImpl_Study::GetStudyImpl( _ap->GetSObject().GetLabel() )->FindComponent(compName);
     if(!so) return entry;
     compID = so.GetID();
     _compNames[compName] = compID;
index 2366071020bf5894a397edbb3ad3ce3664a61498..ac12499f36192092f8bc786bcff926552b6f979f 100644 (file)
@@ -160,7 +160,6 @@ public:
 
 private:
   SALOMEDSImpl_AttributeParameter* _ap;
-  SALOMEDSImpl_Study* _study;
   std::map<std::string, std::string> _compNames;
 };
 
index 050e3ab72c3ec88779114ca607319856bca7f6ba..7eb80ce8dbc49aab181504db669b57f9e20c0bba 100644 (file)
@@ -104,7 +104,7 @@ SALOMEDSImpl_SComponent SALOMEDSImpl_SObject::GetFatherComponent() const
 
   if(LF.IsRoot()) return sco;
 
-  return GetStudy()->GetSComponent(LF);
+  return SALOMEDSImpl_Study::SComponent(LF);
 }
 
 //============================================================================
@@ -114,7 +114,7 @@ SALOMEDSImpl_SComponent SALOMEDSImpl_SObject::GetFatherComponent() const
 //============================================================================
 SALOMEDSImpl_SObject SALOMEDSImpl_SObject::GetFather() const
 {
-  return GetStudy()->GetSObject(_lab.Father());
+  return SALOMEDSImpl_Study::SObject(_lab.Father());
 }
 
 //============================================================================
@@ -127,16 +127,6 @@ int SALOMEDSImpl_SObject::GetLastChildTag() const
   return _lab.LastChildTag();
 }
 
-//============================================================================
-/*! Function : GetStudy
- *  Purpose  :
- */
-//============================================================================
-SALOMEDSImpl_Study* SALOMEDSImpl_SObject::GetStudy() const
-{
-  return SALOMEDSImpl_Study::GetStudy(_lab);
-}
-
 //============================================================================
 /*! Function : FindAttribute
  *  Purpose  : Find attribute of given type on this SObject
@@ -182,7 +172,7 @@ bool SALOMEDSImpl_SObject::ReferencedObject(SALOMEDSImpl_SObject& theObject) con
   if (!(Ref=(SALOMEDSImpl_AttributeReference*)_lab.FindAttribute(SALOMEDSImpl_AttributeReference::GetID())))
     return false;
   
-  theObject =  GetStudy()->GetSObject(Ref->Get());
+  theObject =  SALOMEDSImpl_Study::SObject(Ref->Get());
   return true;
 }
 
@@ -196,7 +186,7 @@ bool SALOMEDSImpl_SObject::FindSubObject(int theTag, SALOMEDSImpl_SObject& theOb
   DF_Label L = _lab.FindChild(theTag, false);
   if (L.IsNull()) return false;
   
-  theObject = GetStudy()->GetSObject(L);
+  theObject = SALOMEDSImpl_Study::SObject(L);
   return true;
     
 }  
index eadad35021eac7f17af88b59a35256c8eb4b13af..0bce0b68212ec80b187a0543f13b5455df3ddf64 100644 (file)
@@ -60,7 +60,6 @@ public:
   virtual bool ReferencedObject(SALOMEDSImpl_SObject& theObject) const ;
   virtual bool FindSubObject(int theTag, SALOMEDSImpl_SObject& theObject);
 
-  virtual SALOMEDSImpl_Study*  GetStudy() const;
   virtual std::string Name() const { return _name; }
   virtual void Name(const std::string& theName) { _name = theName; }
   virtual std::vector<DF_Attribute*> GetAllAttributes() const; 
index 1f3fefc89b4fda04bc34278f762d48df66fd671f..09adc5d2c87eb6e6b4767ea5997c14496d30c4a3 100644 (file)
@@ -967,9 +967,6 @@ bool SALOMEDSImpl_Study::Copy(const SALOMEDSImpl_SObject& theObject,
   bool aStructureOnly; // copy only SObjects and attributes without component help
   aStructureOnly = !theObject.GetLabel().IsAttribute(SALOMEDSImpl_AttributeIOR::GetID());
 
-  // get component-engine
-  SALOMEDSImpl_Study* aStudy = theObject.GetStudy();
-
   if (!_doc) {
     _errorCode = "Document is null";
     return false;
@@ -1195,41 +1192,6 @@ std::string SALOMEDSImpl_Study::GetPersistentReference()
   _errorCode = "";
   return URL();
 }
-//============================================================================
-/*! Function : GetTransientReference
- *  Purpose  : Get IOR of the Study (registred in Document in doc->Root)
- */
-//============================================================================
-std::string SALOMEDSImpl_Study::GetTransientReference()
-{
-  _errorCode = "";
-  std::string IOR = "";
-
-  SALOMEDSImpl_AttributeIOR* Att;
-  DF_Label _lab = _doc->Root();
-  if ((Att=(SALOMEDSImpl_AttributeIOR*)_lab.FindAttribute(SALOMEDSImpl_AttributeIOR::GetID()))) {
-    IOR = Att->Value();
-  }
-  else {
-    _errorCode = "IOR is empty";
-  }
-
-  return IOR;
-}
-
-void SALOMEDSImpl_Study::SetTransientReference(const std::string& theIOR)
-{
-  _errorCode = "";
-
-  SALOMEDSImpl_AttributeStudyProperties* aProp = GetProperties();
-  int aLocked = aProp->IsLocked();
-  if (aLocked) aProp->SetLocked(false);
-
-  // Assign the value of the IOR in the study->root
-  SALOMEDSImpl_AttributeIOR::Set(_doc->Main().Root(), theIOR);
-
-  if (aLocked) aProp->SetLocked(true);
-}
 
 //============================================================================
 /*! Function : IsEmpty
@@ -1846,7 +1808,7 @@ void SALOMEDSImpl_Study::DeleteIORLabelMapItem(const std::string& anIOR)
     }
 }
 
-SALOMEDSImpl_Study* SALOMEDSImpl_Study::GetStudy(const DF_Label& theLabel)
+SALOMEDSImpl_Study* SALOMEDSImpl_Study::GetStudyImpl(const DF_Label& theLabel)
 {
   SALOMEDSImpl_StudyHandle* Att;
   if ((Att=(SALOMEDSImpl_StudyHandle*)theLabel.Root().FindAttribute(SALOMEDSImpl_StudyHandle::GetID()))) {
@@ -1857,19 +1819,19 @@ SALOMEDSImpl_Study* SALOMEDSImpl_Study::GetStudy(const DF_Label& theLabel)
 
 SALOMEDSImpl_SObject SALOMEDSImpl_Study::SObject(const DF_Label& theLabel)
 {
-  return GetStudy(theLabel)->GetSObject(theLabel);
+  return GetStudyImpl(theLabel)->GetSObject(theLabel);
 }
 
 SALOMEDSImpl_SComponent SALOMEDSImpl_Study::SComponent(const DF_Label& theLabel)
 {
-  return GetStudy(theLabel)->GetSComponent(theLabel);
+  return GetStudyImpl(theLabel)->GetSComponent(theLabel);
 }
 
 
 void SALOMEDSImpl_Study::IORUpdated(const SALOMEDSImpl_AttributeIOR* theAttribute)
 {
   std::string aString = theAttribute->Label().Entry();
-  GetStudy(theAttribute->Label())->UpdateIORLabelMap(theAttribute->Value(), aString);
+  GetStudyImpl(theAttribute->Label())->UpdateIORLabelMap(theAttribute->Value(), aString);
 }
 
 std::vector<SALOMEDSImpl_SObject> SALOMEDSImpl_Study::FindDependances(const SALOMEDSImpl_SObject& anObject)
index 81504d3019017753863b63e8ca34b40cc1a3112e..f1c1d23ba124cce9f562517b9222640dff297df7 100644 (file)
@@ -92,7 +92,7 @@ private:
 
 public:
 
-  static SALOMEDSImpl_Study* GetStudy(const DF_Label& theLabel);
+  static SALOMEDSImpl_Study* GetStudyImpl(const DF_Label& theLabel);
   static SALOMEDSImpl_SObject SObject(const DF_Label& theLabel);
   static SALOMEDSImpl_SComponent SComponent(const DF_Label& theLabel);
   static void IORUpdated(const SALOMEDSImpl_AttributeIOR* theAttribute);
@@ -150,11 +150,6 @@ public:
   //! method to Get persistent reference of study (idem URL())
   virtual std::string GetPersistentReference();
 
-  //! method to Get transient reference of study
-  virtual std::string GetTransientReference();
-
-  virtual void SetTransientReference(const std::string& theIOR);
-
   //! method to detect if a study is empty
   virtual bool IsEmpty();
 
index 893f9c64722807137db1dfef0ca176730973c053..e9b39a1ae954cf329c05eddc6c2f13a964e3abcd 100644 (file)
@@ -133,7 +133,7 @@ bool SALOMEDSImpl_UseCaseBuilder::Append(const SALOMEDSImpl_SObject& theObject)
   aCurrentNode->Append(aNode);
 
   // Mantis issue 0020136: Drag&Drop in OB
-  theObject.GetStudy()->addSO_Notification(theObject);
+  SALOMEDSImpl_Study::GetStudyImpl(theObject.GetLabel())->addSO_Notification(theObject);
 
   return true;
 }
@@ -208,7 +208,7 @@ bool SALOMEDSImpl_UseCaseBuilder::AppendTo(const SALOMEDSImpl_SObject& theFather
   bool ret = aFather->Append(aNode);
 
   // Mantis issue 0020136: Drag&Drop in OB
-  theObject.GetStudy()->addSO_Notification(theObject);
+  SALOMEDSImpl_Study::GetStudyImpl(theObject.GetLabel())->addSO_Notification(theObject);
 
   return ret;
 }
@@ -244,7 +244,7 @@ bool SALOMEDSImpl_UseCaseBuilder::InsertBefore(const SALOMEDSImpl_SObject& theFi
   bool ret = aNode->InsertBefore(aFirstNode);
 
   // Mantis issue 0020136: Drag&Drop in OB
-  theFirst.GetStudy()->addSO_Notification(theFirst);
+  SALOMEDSImpl_Study::GetStudyImpl(theFirst.GetLabel())->addSO_Notification(theFirst);
 
   return ret;
 }