SALOMEDS_StudyManager_i.hxx \
SALOMEDS_Driver_i.hxx \
SALOMEDS_StudyManager.hxx \
+ SALOMEDS_Study_i.hxx \
SALOMEDS_Study.hxx \
+ SALOMEDS_SObject_i.hxx \
SALOMEDS_SObject.hxx \
+ SALOMEDS_SComponent_i.hxx \
SALOMEDS_SComponent.hxx \
+ SALOMEDS_GenericAttribute_i.hxx \
SALOMEDS_GenericAttribute.hxx
# Libraries targets
{
_isLocal = false;
_local_impl = NULL;
- _corba_impl = SALOMEDS::ChildIterator::_duplicate(theIterator);
+ _corba_impl = theIterator;
}
void SALOMEDS_ChildIterator::Init()
}
else {
_local_impl = NULL;
- _corba_impl = SALOMEDS::GenericAttribute::_duplicate(theGA);
+ _corba_impl = theGA;
}
}
SALOMEDS_SComponentIterator::SALOMEDS_SComponentIterator(SALOMEDS::SComponentIterator_ptr theIterator)
{
_isLocal = false;
- _corba_impl = SALOMEDS::SComponentIterator::_duplicate(theIterator);
+ _corba_impl = theIterator;
}
SALOMEDS_SComponentIterator::~SALOMEDS_SComponentIterator()
}
else {
_local_impl = NULL;
- _corba_impl = SALOMEDS::SObject::_duplicate(theSObject);
+ _corba_impl = theSObject;
}
}
return new SALOMEDS_SObject(_corba_impl->GetFather());
}
-bool SALOMEDS_SObject::FindAttribute(SALOMEDSClient_GenericAttribute* anAttribute, const char* aTypeOfAttribute)
+bool SALOMEDS_SObject::FindAttribute(SALOMEDSClient_GenericAttribute*& anAttribute, const char* aTypeOfAttribute)
{
bool ret = false;
TCollection_AsciiString aType((char*)aTypeOfAttribute);
if(_isLocal) {
Handle(SALOMEDSImpl_GenericAttribute) anAttr;
ret = _local_impl->FindAttribute(anAttr, aType);
+ cout << "############## ret = " << ret << " type requested " << aType << endl;
+ if(!anAttr.IsNull()) cout << "############## recieved " << anAttr->Type() << endl;
if(ret) anAttribute = SALOMEDS_GenericAttribute::CreateAttribute(anAttr);
}
else {
return ret;
}
-bool SALOMEDS_SObject::ReferencedObject(SALOMEDSClient_SObject* theObject)
+bool SALOMEDS_SObject::ReferencedObject(SALOMEDSClient_SObject*& theObject)
{
bool ret = false;
if(_isLocal) {
}
-bool SALOMEDS_SObject::FindSubObject(int theTag, SALOMEDSClient_SObject* theObject)
+bool SALOMEDS_SObject::FindSubObject(int theTag, SALOMEDSClient_SObject*& theObject)
{
bool ret = false;
if(_isLocal) {
if(_isLocal) return _local_impl->Depth();
return _corba_impl->Depth();
}
+
+CORBA::Object_ptr SALOMEDS_SObject::GetObject()
+{
+ CORBA::Object_var obj;
+ if(_isLocal) {
+ TCollection_AsciiString anIOR = GetIOR();
+ SALOMEDS_Study* aStudy = dynamic_cast<SALOMEDS_Study*>(GetStudy());
+ obj = CORBA::Object::_duplicate(aStudy->ConvertIORToObject(anIOR.ToCString()));
+ delete aStudy;
+ }
+ else obj = CORBA::Object::_duplicate(_corba_impl->GetObject());
+ return obj._retn();
+}
virtual char* GetID();
virtual SALOMEDSClient_SComponent* GetFatherComponent();
virtual SALOMEDSClient_SObject* GetFather();
- virtual bool FindAttribute(SALOMEDSClient_GenericAttribute* anAttribute, const char* aTypeOfAttribute);
- virtual bool ReferencedObject(SALOMEDSClient_SObject* theObject);
- virtual bool FindSubObject(int theTag, SALOMEDSClient_SObject* theObject);
+ virtual bool FindAttribute(SALOMEDSClient_GenericAttribute*& anAttribute, const char* aTypeOfAttribute);
+ virtual bool ReferencedObject(SALOMEDSClient_SObject*& theObject);
+ virtual bool FindSubObject(int theTag, SALOMEDSClient_SObject*& theObject);
virtual SALOMEDSClient_Study* GetStudy();
virtual char* Name();
virtual void Name(const char* theName);
virtual int Tag();
virtual int Depth();
+ CORBA::Object_ptr GetObject();
SALOMEDS::SObject_ptr GetCORBAImpl() { return SALOMEDS::SObject::_duplicate(_corba_impl); }
Handle(SALOMEDSImpl_SObject) GetLocalImpl() { return _local_impl; }
};
}
else {
_local_impl = NULL;
- _corba_impl = SALOMEDS::Study::_duplicate(theStudy);
+ _corba_impl = theStudy;
}
init_orb();
{
_isLocal = false;
_local_impl = NULL;
- _corba_impl = SALOMEDS::StudyBuilder::_duplicate(theBuilder);
+ _corba_impl = theBuilder;
init_orb();
}
}
else {
_local_impl = NULL;
- _corba_impl = SALOMEDS::StudyManager::_duplicate(theManager);
+ _corba_impl = theManager;
}
}
{
_isLocal = false;
_local_impl = NULL;
- _corba_impl = SALOMEDS::UseCaseBuilder::_duplicate(theBuilder);
+ _corba_impl = theBuilder;
}
SALOMEDS_UseCaseBuilder::~SALOMEDS_UseCaseBuilder()
{
_isLocal = false;
_local_impl = NULL;
- _corba_impl = SALOMEDS::UseCaseIterator::_duplicate(theIterator);
+ _corba_impl = theIterator;
}
SALOMEDS_UseCaseIterator::~SALOMEDS_UseCaseIterator()