Back to index

salome-kernel  6.5.0
Functions
SALOMEDS.cxx File Reference
#include "SALOMEDS.hxx"
#include "SALOMEDS_StudyManager.hxx"
#include "SALOMEDS_Study.hxx"
#include "SALOMEDS_StudyBuilder.hxx"
#include "SALOMEDS_SObject.hxx"
#include "SALOMEDS_SComponent.hxx"
#include "SALOMEDSClient.hxx"
#include "SALOMEDSClient_IParameters.hxx"
#include "SALOMEDS_IParameters.hxx"
#include "SALOMEDS_StudyManager_i.hxx"
#include "SALOMEDS_Defines.hxx"
#include <SALOMEconfig.h>
#include <SALOME_NamingService.hxx>

Go to the source code of this file.

Functions

SALOMEDS_EXPORT
SALOMEDSClient_StudyManager
StudyManagerFactory ()
 C factory, accessible with dlsym, after dlopen.
SALOMEDS_EXPORT
SALOMEDSClient_Study
StudyFactory (SALOMEDS::Study_ptr theStudy)
SALOMEDS_EXPORT
SALOMEDSClient_SObject
SObjectFactory (SALOMEDS::SObject_ptr theSObject)
SALOMEDS_EXPORT
SALOMEDSClient_SComponent
SComponentFactory (SALOMEDS::SComponent_ptr theSComponent)
SALOMEDS_EXPORT
SALOMEDSClient_StudyBuilder
BuilderFactory (SALOMEDS::StudyBuilder_ptr theBuilder)
SALOMEDS_EXPORT
SALOMEDSClient_StudyManager
CreateStudyManager (CORBA::ORB_ptr orb, PortableServer::POA_ptr root_poa)
SALOMEDS_EXPORT
SALOMEDSClient_IParameters
GetIParameters (const _PTR(AttributeParameter)&ap)
SALOMEDS_EXPORT
SALOMEDS::SObject_ptr 
ConvertSObject (const _PTR(SObject)&theSObject)
SALOMEDS_EXPORT SALOMEDS::Study_ptr ConvertStudy (const _PTR(Study)&theStudy)
SALOMEDS_EXPORT
SALOMEDS::StudyBuilder_ptr 
ConvertBuilder (const _PTR(StudyBuilder)&theBuilder)

Function Documentation

SALOMEDS_EXPORT SALOMEDSClient_StudyBuilder* BuilderFactory ( SALOMEDS::StudyBuilder_ptr  theBuilder)

Definition at line 108 of file SALOMEDS.cxx.

{
  if(CORBA::is_nil(theBuilder)) return NULL;
  return new SALOMEDS_StudyBuilder(theBuilder);
}
SALOMEDS_EXPORT SALOMEDS::StudyBuilder_ptr ConvertBuilder ( const _PTR(StudyBuilder)&  theBuilder)

Definition at line 155 of file SALOMEDS.cxx.

{
  SALOMEDS_StudyBuilder* builder = _CAST(StudyBuilder, theBuilder);
  if(!theBuilder || !builder) return SALOMEDS::StudyBuilder::_nil(); 
  return builder->GetBuilder();
}
SALOMEDS_EXPORT SALOMEDS::SObject_ptr ConvertSObject ( const _PTR(SObject)&  theSObject)

Definition at line 138 of file SALOMEDS.cxx.

{
  
  SALOMEDS_SObject* so = _CAST(SObject, theSObject);
  if(!theSObject || !so) return SALOMEDS::SObject::_nil();
  return so->GetSObject();
}
SALOMEDS_EXPORT SALOMEDS::Study_ptr ConvertStudy ( const _PTR(Study)&  theStudy)

Definition at line 147 of file SALOMEDS.cxx.

{
  SALOMEDS_Study* study = _CAST(Study, theStudy);
  if(!theStudy || !study) return SALOMEDS::Study::_nil();
  return study->GetStudy();
}
SALOMEDS_EXPORT SALOMEDSClient_StudyManager* CreateStudyManager ( CORBA::ORB_ptr  orb,
PortableServer::POA_ptr  root_poa 
)

Definition at line 115 of file SALOMEDS.cxx.

{
  SALOME_NamingService namingService(orb);
  CORBA::Object_var obj = namingService.Resolve( "/myStudyManager" );
  SALOMEDS::StudyManager_var theManager = SALOMEDS::StudyManager::_narrow( obj );
  if( CORBA::is_nil(theManager) ) {
    SALOMEDS_StudyManager_i * aStudyManager_i = new  SALOMEDS_StudyManager_i(orb, root_poa);
    // Activate the objects.  This tells the POA that the objects are ready to accept requests.
    PortableServer::ObjectId_var aStudyManager_iid =  root_poa->activate_object(aStudyManager_i);
    //give ownership to the poa : the object will be deleted by the poa
    aStudyManager_i->_remove_ref();
    aStudyManager_i->register_name((char*)"/myStudyManager");
  }
  return new SALOMEDS_StudyManager();
}
SALOMEDS_EXPORT SALOMEDSClient_IParameters* GetIParameters ( const _PTR(AttributeParameter)&  ap)

Definition at line 132 of file SALOMEDS.cxx.

{
  return new SALOMEDS_IParameters(ap);
}
SALOMEDS_EXPORT SALOMEDSClient_SComponent* SComponentFactory ( SALOMEDS::SComponent_ptr  theSComponent)

Definition at line 101 of file SALOMEDS.cxx.

{
  if(CORBA::is_nil(theSComponent)) return NULL;
  return new SALOMEDS_SComponent(theSComponent);
}
SALOMEDS_EXPORT SALOMEDSClient_SObject* SObjectFactory ( SALOMEDS::SObject_ptr  theSObject)

Definition at line 94 of file SALOMEDS.cxx.

{
  if(CORBA::is_nil(theSObject)) return NULL;
  return new SALOMEDS_SObject(theSObject);
}
SALOMEDS_EXPORT SALOMEDSClient_Study* StudyFactory ( SALOMEDS::Study_ptr  theStudy)

Definition at line 87 of file SALOMEDS.cxx.

{
  if(CORBA::is_nil(theStudy)) return NULL;
  return new SALOMEDS_Study(theStudy);
}

C factory, accessible with dlsym, after dlopen.

Definition at line 82 of file SALOMEDS.cxx.

{
  return new SALOMEDS_StudyManager();
}