_ResManager->Shutdown();
PortableServer::ObjectId_var oid = _poa->servant_to_id(this);
_poa->deactivate_object(oid);
- _remove_ref();
+ //_remove_ref();
if(!CORBA::is_nil(_orb))
_orb->shutdown(0);
}
+//=============================================================================
+/*! CORBA Method:
+ * Returns the PID of the process
+ */
+//=============================================================================
+CORBA::Long SALOME_Launcher::getPID()
+{
+ return (CORBA::Long)getpid();
+}
+
//=============================================================================
/*! CORBA Method:
* Submit a batch job on a cluster and returns the JobId
/*!
* Standard constructor, parse resource file.
* - if ${APPLI} exists in environment,
- * look for ${HOME}/*{APPLI}/CatalogResources.xml
+ * look for ${HOME}/${APPLI}/CatalogResources.xml
* - else look for default:
* ${KERNEL_ROOT_DIR}/share/salome/resources/kernel/CatalogResources.xml
* - parse XML resource file.
_NS->Destroy_Name(_ResourcesManagerNameInNS);
PortableServer::ObjectId_var oid = _poa->servant_to_id(this);
_poa->deactivate_object(oid);
- _remove_ref();
+ //_remove_ref();
}
//=============================================================================
SALOMEDSImpl_StudyBuilder::SALOMEDSImpl_StudyBuilder(const SALOMEDSImpl_Study* theOwner)
{
_errorCode = "";
+ _callbackOnAdd=NULL;
+ _callbackOnRemove = NULL;
_study = (SALOMEDSImpl_Study*)theOwner;
_doc = _study->GetDocument();
}
//Always create component under main label.
DF_Label L = _doc->Main();
- int imax = 0;
- for (DF_ChildIterator it(L); it.More(); it.Next()) {
- if (it.Value().Tag() > imax)
- imax = it.Value().Tag();
- }
- imax++;
- DF_Label NL = L.FindChild(imax);
+ DF_Label NL = L.NewChild();
SALOMEDSImpl_AttributeComment::Set(NL, DataType);
//============================================================================
SALOMEDSImpl_SObject SALOMEDSImpl_StudyBuilder::NewObject(const SALOMEDSImpl_SObject& theFatherObject)
{
- _errorCode = "";
+ _errorCode = "";
CheckLocked();
//Find label of father
DF_Label Lab = theFatherObject.GetLabel();
//Create a new label
- int imax = 0;
- for (DF_ChildIterator it(Lab); it.More(); it.Next()) {
- if (it.Value().Tag() > imax)
- imax = it.Value().Tag();
- }
- imax++;
- DF_Label NewLab = Lab.FindChild(imax);
+ DF_Label NewLab = Lab.NewChild();
SALOMEDSImpl_SObject so = _study->GetSObject(NewLab);
if(_callbackOnAdd) _callbackOnAdd->OnAddSObject(so);