From b745752172ed3fb01f14b6ffbd82cba332bf6751 Mon Sep 17 00:00:00 2001 From: vsr Date: Thu, 13 Dec 2012 12:33:12 +0000 Subject: [PATCH] Merge from V6_main 13/12/2012 --- src/AddComponent/AddComponent_Impl.cxx | 10 +++++++++ src/AddComponent/AddComponent_Impl.hxx | 2 ++ src/AddComponent/Adder_Impl.cxx | 10 +++++++++ src/AddComponent/Adder_Impl.hxx | 2 ++ src/AddComponent/Makefile.am | 4 +++- .../AdditionComponent_Impl.cxx | 10 +++++++++ .../AdditionComponent_Impl.hxx | 2 ++ src/AdditionComponent/Addition_Adder_Impl.cxx | 10 +++++++++ src/AdditionComponent/Addition_Adder_Impl.hxx | 2 ++ src/AdditionComponent/Makefile.am | 3 ++- src/CalculatorComponent/CalculatorEngine.cxx | 10 +++++++++ src/CalculatorComponent/CalculatorEngine.hxx | 1 + src/CalculatorComponent/Makefile.am | 3 ++- .../DataStreamComponent_Impl.cxx | 19 +++++++++++++++++ .../DataStreamComponent_Impl.hxx | 4 ++++ src/DataStreamComponent/Makefile.am | 3 ++- src/DivComponent/DivComponent.cxx | 10 +++++++++ src/DivComponent/DivComponent.hxx | 2 ++ src/DivComponent/Makefile.am | 3 ++- src/FactorialComponent/FactorialComponent.py | 4 ++++ src/MulComponent/Makefile.am | 3 ++- src/MulComponent/MulComponent.cxx | 10 +++++++++ src/MulComponent/MulComponent.hxx | 2 ++ src/SIGNALSComponent/Makefile.am | 3 ++- .../SIGNALSComponent_Impl.cxx | 10 +++++++++ .../SIGNALSComponent_Impl.hxx | 2 ++ src/SubComponent/Makefile.am | 3 ++- src/SubComponent/SubComponent.cxx | 11 +++++++++- src/SubComponent/SubComponent.hxx | 3 ++- src/SyrComponent/Makefile.am | 4 +++- src/SyrComponent/SyrComponent_Impl.cxx | 21 +++++++++++++++++-- src/SyrComponent/SyrComponent_Impl.hxx | 4 ++++ .../SyrControlComponent.py | 4 ++++ src/TypesCheck/Makefile.am | 4 +++- src/TypesCheck/TypesCheck_Impl.cxx | 10 +++++++++ src/TypesCheck/TypesCheck_Impl.hxx | 2 ++ src/UndefinedSymbolComponent/Makefile.am | 3 ++- .../UndefinedSymbolComponent.cxx | 10 +++++++++ .../UndefinedSymbolComponent.hxx | 2 ++ 39 files changed, 210 insertions(+), 15 deletions(-) diff --git a/src/AddComponent/AddComponent_Impl.cxx b/src/AddComponent/AddComponent_Impl.cxx index ce61ff5..e289041 100644 --- a/src/AddComponent/AddComponent_Impl.cxx +++ b/src/AddComponent/AddComponent_Impl.cxx @@ -39,6 +39,7 @@ #include "AddComponent_Impl.hxx" #include "Adder_Impl.hxx" +#include "COMPONENT_version.h" using namespace std; @@ -63,6 +64,15 @@ AddComponent_Impl::AddComponent_Impl() { AddComponent_Impl::~AddComponent_Impl() { } +char* AddComponent_Impl::getVersion() +{ +#if COMPONENT_DEVELOPMENT + return CORBA::string_dup(COMPONENT_VERSION_STR"dev"); +#else + return CORBA::string_dup(COMPONENT_VERSION_STR); +#endif +} + CORBA::Double AddComponent_Impl::Add( CORBA::Double x , CORBA::Double y , CORBA::Double & z ) { beginService( " AddComponent_Impl::Add" ); z = x + y ; diff --git a/src/AddComponent/AddComponent_Impl.hxx b/src/AddComponent/AddComponent_Impl.hxx index ea0baa9..517a8f3 100644 --- a/src/AddComponent/AddComponent_Impl.hxx +++ b/src/AddComponent/AddComponent_Impl.hxx @@ -47,6 +47,8 @@ public: virtual ~AddComponent_Impl(); + virtual char* getVersion(); + virtual CORBA::Double Add( CORBA::Double x , CORBA::Double y , CORBA::Double & z ) ; virtual CORBA::Double AddWithoutSleep( CORBA::Double x , CORBA::Double y , CORBA::Double & z ) ; diff --git a/src/AddComponent/Adder_Impl.cxx b/src/AddComponent/Adder_Impl.cxx index 84dbc86..5d53e04 100644 --- a/src/AddComponent/Adder_Impl.cxx +++ b/src/AddComponent/Adder_Impl.cxx @@ -38,6 +38,7 @@ #include "SALOME_LifeCycleCORBA.hxx" #include "Adder_Impl.hxx" +#include "COMPONENT_version.h" using namespace std; @@ -70,6 +71,15 @@ Adder_Impl::~Adder_Impl() { endService( "Adder_Impl::~Adder_Impl" ); } +char* Adder_Impl::getVersion() +{ +#if COMPONENT_DEVELOPMENT + return CORBA::string_dup(COMPONENT_VERSION_STR"dev"); +#else + return CORBA::string_dup(COMPONENT_VERSION_STR); +#endif +} + void Adder_Impl::destroy() { _poa->deactivate_object(*_id) ; CORBA::release(_poa) ; diff --git a/src/AddComponent/Adder_Impl.hxx b/src/AddComponent/Adder_Impl.hxx index ffc4e6c..8450838 100644 --- a/src/AddComponent/Adder_Impl.hxx +++ b/src/AddComponent/Adder_Impl.hxx @@ -49,6 +49,8 @@ class Adder_Impl : public POA_SuperVisionTest::Adder , virtual ~Adder_Impl(); + virtual char* getVersion(); + virtual void destroy() ; virtual CORBA::Double Add( CORBA::Double x , CORBA::Double y , CORBA::Double & z ) ; diff --git a/src/AddComponent/Makefile.am b/src/AddComponent/Makefile.am index 7e40093..f1518c8 100755 --- a/src/AddComponent/Makefile.am +++ b/src/AddComponent/Makefile.am @@ -49,7 +49,9 @@ libAddComponentEngine_la_CPPFLAGS = \ $(CORBA_CXXFLAGS) \ $(CORBA_INCLUDES) \ $(KERNEL_CXXFLAGS) \ - -I$(top_builddir)/idl + -I$(top_builddir)/idl \ + -I$(top_builddir) + libAddComponentEngine_la_LDFLAGS = \ ../../idl/libSalomeIDLCOMPONENT.la \ $(KERNEL_LDFLAGS) \ diff --git a/src/AdditionComponent/AdditionComponent_Impl.cxx b/src/AdditionComponent/AdditionComponent_Impl.cxx index b4f2184..23096d5 100644 --- a/src/AdditionComponent/AdditionComponent_Impl.cxx +++ b/src/AdditionComponent/AdditionComponent_Impl.cxx @@ -39,6 +39,7 @@ #include "AdditionComponent_Impl.hxx" #include "Adder_Impl.hxx" +#include "COMPONENT_version.h" using namespace std; @@ -63,6 +64,15 @@ AdditionInterface_Impl::AdditionInterface_Impl() { AdditionInterface_Impl::~AdditionInterface_Impl() { } +char* AdditionInterface_Impl::getVersion() +{ +#if COMPONENT_DEVELOPMENT + return CORBA::string_dup(COMPONENT_VERSION_STR"dev"); +#else + return CORBA::string_dup(COMPONENT_VERSION_STR); +#endif +} + CORBA::Double AdditionInterface_Impl::Add( CORBA::Double x , CORBA::Double y , CORBA::Double & z ) { beginService( " AdditionInterface_Impl::Add" ); z = x + y ; diff --git a/src/AdditionComponent/AdditionComponent_Impl.hxx b/src/AdditionComponent/AdditionComponent_Impl.hxx index a59e92d..69791d1 100644 --- a/src/AdditionComponent/AdditionComponent_Impl.hxx +++ b/src/AdditionComponent/AdditionComponent_Impl.hxx @@ -47,6 +47,8 @@ public: virtual ~AdditionInterface_Impl(); + virtual char* getVersion(); + virtual CORBA::Double Add( CORBA::Double x , CORBA::Double y , CORBA::Double & z ) ; virtual CORBA::Double AddWithoutSleep( CORBA::Double x , CORBA::Double y , CORBA::Double & z ) ; diff --git a/src/AdditionComponent/Addition_Adder_Impl.cxx b/src/AdditionComponent/Addition_Adder_Impl.cxx index 052ab48..4c89ede 100644 --- a/src/AdditionComponent/Addition_Adder_Impl.cxx +++ b/src/AdditionComponent/Addition_Adder_Impl.cxx @@ -38,6 +38,7 @@ #include "SALOME_LifeCycleCORBA.hxx" #include "Addition_Adder_Impl.hxx" +#include "COMPONENT_version.h" using namespace std; @@ -65,6 +66,15 @@ Adder_Impl::Adder_Impl() { LastAddition = 0 ; } +char* Adder_Impl::getVersion() +{ +#if COMPONENT_DEVELOPMENT + return CORBA::string_dup(COMPONENT_VERSION_STR"dev"); +#else + return CORBA::string_dup(COMPONENT_VERSION_STR); +#endif +} + Adder_Impl::~Adder_Impl() { beginService( "Adder_Impl::~Adder_Impl" ); endService( "Adder_Impl::~Adder_Impl" ); diff --git a/src/AdditionComponent/Addition_Adder_Impl.hxx b/src/AdditionComponent/Addition_Adder_Impl.hxx index 87e0c51..78ec32f 100644 --- a/src/AdditionComponent/Addition_Adder_Impl.hxx +++ b/src/AdditionComponent/Addition_Adder_Impl.hxx @@ -49,6 +49,8 @@ class Adder_Impl : public POA_AdditionComponent::Adder , virtual ~Adder_Impl(); + virtual char* getVersion(); + virtual void destroy() ; virtual CORBA::Double Add( CORBA::Double x , CORBA::Double y , CORBA::Double & z ) ; diff --git a/src/AdditionComponent/Makefile.am b/src/AdditionComponent/Makefile.am index 28c22fd..94aa08c 100755 --- a/src/AdditionComponent/Makefile.am +++ b/src/AdditionComponent/Makefile.am @@ -49,7 +49,8 @@ libAdditionComponentEngine_la_CPPFLAGS = \ $(CORBA_INCLUDES) \ $(KERNEL_CXXFLAGS) \ -I$(srcdir)/../AddComponent \ - -I$(top_builddir)/idl + -I$(top_builddir)/idl \ + -I$(top_builddir) libAdditionComponentEngine_la_LDFLAGS = \ ../../idl/libSalomeIDLCOMPONENT.la \ diff --git a/src/CalculatorComponent/CalculatorEngine.cxx b/src/CalculatorComponent/CalculatorEngine.cxx index c472ca8..44ffd9f 100644 --- a/src/CalculatorComponent/CalculatorEngine.cxx +++ b/src/CalculatorComponent/CalculatorEngine.cxx @@ -30,6 +30,7 @@ #include #include +#include "COMPONENT_version.h" #include "CalculatorEngine.hxx" #include "MEDMEM_Support_i.hxx" #include "SUPPORTClient.hxx" @@ -108,6 +109,15 @@ CalculatorEngine::~CalculatorEngine() delete _NS; } +char* CalculatorEngine::getVersion() +{ +#if COMPONENT_DEVELOPMENT + return CORBA::string_dup(COMPONENT_VERSION_STR"dev"); +#else + return CORBA::string_dup(COMPONENT_VERSION_STR); +#endif +} + static omni_mutex aPutToStudyMutex; SALOME_MED::FIELDDOUBLE_ptr CalculatorEngine::PutToStudy(SALOME_MED::FIELDDOUBLE_ptr theField1, CORBA::Long theStudyId) { diff --git a/src/CalculatorComponent/CalculatorEngine.hxx b/src/CalculatorComponent/CalculatorEngine.hxx index 1ce4f1e..d1b1792 100644 --- a/src/CalculatorComponent/CalculatorEngine.hxx +++ b/src/CalculatorComponent/CalculatorEngine.hxx @@ -55,6 +55,7 @@ public: virtual ~CalculatorEngine(); + virtual char* getVersion(); SALOME_MED::FIELDDOUBLE_ptr PutToStudy(SALOME_MED::FIELDDOUBLE_ptr theField, CORBA::Long theStudyId); diff --git a/src/CalculatorComponent/Makefile.am b/src/CalculatorComponent/Makefile.am index 093cf13..3e162c8 100755 --- a/src/CalculatorComponent/Makefile.am +++ b/src/CalculatorComponent/Makefile.am @@ -41,7 +41,8 @@ libCalculatorEngine_la_CPPFLAGS = \ $(CORBA_INCLUDES) \ $(KERNEL_CXXFLAGS) \ $(MED_CXXFLAGS) \ - -I$(top_builddir)/idl + -I$(top_builddir)/idl \ + -I$(top_builddir) libCalculatorEngine_la_LDFLAGS = \ ../../idl/libSalomeIDLCOMPONENT.la \ diff --git a/src/DataStreamComponent/DataStreamComponent_Impl.cxx b/src/DataStreamComponent/DataStreamComponent_Impl.cxx index 2c08ea4..412fabb 100644 --- a/src/DataStreamComponent/DataStreamComponent_Impl.cxx +++ b/src/DataStreamComponent/DataStreamComponent_Impl.cxx @@ -31,6 +31,7 @@ #include #include +#include "COMPONENT_version.h" #include "DataStreamComponent_Impl.hxx" using namespace std; @@ -54,6 +55,15 @@ DataStreamFactory_Impl::DataStreamFactory_Impl() { DataStreamFactory_Impl::~DataStreamFactory_Impl() { } +char* DataStreamFactory_Impl::getVersion() +{ +#if COMPONENT_DEVELOPMENT + return CORBA::string_dup(COMPONENT_VERSION_STR"dev"); +#else + return CORBA::string_dup(COMPONENT_VERSION_STR); +#endif +} + void DataStreamFactory_Impl::Setxy( CORBA::Long x , CORBA::Long y ) { _x = x ; _y = y ; @@ -136,6 +146,15 @@ DataStream_Impl::~DataStream_Impl() { endService( "DataStream_Impl::~DataStream_Impl" ); } +char* DataStream_Impl::getVersion() +{ +#if COMPONENT_DEVELOPMENT + return CORBA::string_dup(COMPONENT_VERSION_STR"dev"); +#else + return CORBA::string_dup(COMPONENT_VERSION_STR); +#endif +} + void DataStream_Impl::StreamSetxy( CORBA::Long x , CORBA::Long y ) { _x = x ; _y = y ; diff --git a/src/DataStreamComponent/DataStreamComponent_Impl.hxx b/src/DataStreamComponent/DataStreamComponent_Impl.hxx index 44c3ba8..e1f5341 100644 --- a/src/DataStreamComponent/DataStreamComponent_Impl.hxx +++ b/src/DataStreamComponent/DataStreamComponent_Impl.hxx @@ -46,6 +46,8 @@ public: virtual ~DataStreamFactory_Impl(); + virtual char* getVersion(); + virtual void Setxy( CORBA::Long x , CORBA::Long y ) ; virtual void Getxy( CORBA::Long & x , CORBA::Long & y ) ; @@ -87,6 +89,8 @@ public: virtual ~DataStream_Impl(); + virtual char* getVersion(); + virtual void StreamSetxy( CORBA::Long x , CORBA::Long y ) ; virtual void StreamGetxy( CORBA::Long & x , CORBA::Long & y ) ; diff --git a/src/DataStreamComponent/Makefile.am b/src/DataStreamComponent/Makefile.am index b7dccfb..95dd183 100644 --- a/src/DataStreamComponent/Makefile.am +++ b/src/DataStreamComponent/Makefile.am @@ -49,7 +49,8 @@ libDataStreamFactoryEngine_la_CPPFLAGS = \ $(CORBA_INCLUDES) \ $(KERNEL_CXXFLAGS) \ -I$(srcdir)/../AddComponent \ - -I$(top_builddir)/idl + -I$(top_builddir)/idl \ + -I$(top_builddir) libDataStreamFactoryEngine_la_LDFLAGS = \ ../../idl/libSalomeIDLCOMPONENT.la \ diff --git a/src/DivComponent/DivComponent.cxx b/src/DivComponent/DivComponent.cxx index e4e5f70..c49a63f 100644 --- a/src/DivComponent/DivComponent.cxx +++ b/src/DivComponent/DivComponent.cxx @@ -33,6 +33,7 @@ //#include "utilities.h" #include "DivComponent.hxx" +#include "COMPONENT_version.h" using namespace std; @@ -58,6 +59,15 @@ DivComponentEngine::~DivComponentEngine() { } +char* DivComponentEngine::getVersion() +{ +#if COMPONENT_DEVELOPMENT + return CORBA::string_dup(COMPONENT_VERSION_STR"dev"); +#else + return CORBA::string_dup(COMPONENT_VERSION_STR); +#endif +} + void DivComponentEngine::Div( double x , double y , double & z ) { beginService( " DivComponentEngine::Div" ); z = x / y ; diff --git a/src/DivComponent/DivComponent.hxx b/src/DivComponent/DivComponent.hxx index eb022ed..f7422a9 100644 --- a/src/DivComponent/DivComponent.hxx +++ b/src/DivComponent/DivComponent.hxx @@ -47,6 +47,8 @@ public: virtual ~DivComponentEngine(); + virtual char* getVersion(); + void Div( double x , double y , double & z ) ; private: diff --git a/src/DivComponent/Makefile.am b/src/DivComponent/Makefile.am index 27140e8..d85e889 100755 --- a/src/DivComponent/Makefile.am +++ b/src/DivComponent/Makefile.am @@ -40,7 +40,8 @@ libDivComponentEngine_la_CPPFLAGS = \ $(CORBA_CXXFLAGS) \ $(CORBA_INCLUDES) \ $(KERNEL_CXXFLAGS) \ - -I$(top_builddir)/idl + -I$(top_builddir)/idl \ + -I$(top_builddir) libDivComponentEngine_la_LDFLAGS = \ ../../idl/libSalomeIDLCOMPONENT.la \ diff --git a/src/FactorialComponent/FactorialComponent.py b/src/FactorialComponent/FactorialComponent.py index c54daea..acd1c41 100644 --- a/src/FactorialComponent/FactorialComponent.py +++ b/src/FactorialComponent/FactorialComponent.py @@ -71,6 +71,10 @@ class FactorialComponent( SuperVisionTest__POA.FactorialComponent, SALOME_Compon self.endService( 'FactorialComponent sigma' ) return s + def getVersion( self ): + import salome_version + return salome_version.getVersion("COMPONENT", True) + def __init__(self, orb, poa, this, containerName, instanceName, interfaceName): SALOME_ComponentPy_i.__init__(self, orb, poa, this, containerName, instanceName, interfaceName, 0) diff --git a/src/MulComponent/Makefile.am b/src/MulComponent/Makefile.am index 69315fd..d53131d 100755 --- a/src/MulComponent/Makefile.am +++ b/src/MulComponent/Makefile.am @@ -39,7 +39,8 @@ libMulComponentEngine_la_CPPFLAGS = \ $(CORBA_CXXFLAGS) \ $(CORBA_INCLUDES) \ $(KERNEL_CXXFLAGS) \ - -I$(top_builddir)/idl + -I$(top_builddir)/idl \ + -I$(top_builddir) libMulComponentEngine_la_LDFLAGS = \ ../../idl/libSalomeIDLCOMPONENT.la \ diff --git a/src/MulComponent/MulComponent.cxx b/src/MulComponent/MulComponent.cxx index 1f7da80..f7d7a85 100644 --- a/src/MulComponent/MulComponent.cxx +++ b/src/MulComponent/MulComponent.cxx @@ -33,6 +33,7 @@ //#include "utilities.h" #include "MulComponent.hxx" +#include "COMPONENT_version.h" using namespace std; @@ -58,6 +59,15 @@ MulComponentEngine::~MulComponentEngine() { } +char* MulComponentEngine::getVersion() +{ +#if COMPONENT_DEVELOPMENT + return CORBA::string_dup(COMPONENT_VERSION_STR"dev"); +#else + return CORBA::string_dup(COMPONENT_VERSION_STR); +#endif +} + void MulComponentEngine::Mul( double x , double y , double & z ) { beginService( " MulComponentEngine::Mul" ); z = x * y ; diff --git a/src/MulComponent/MulComponent.hxx b/src/MulComponent/MulComponent.hxx index 9ad5d9e..a3c12e0 100644 --- a/src/MulComponent/MulComponent.hxx +++ b/src/MulComponent/MulComponent.hxx @@ -47,6 +47,8 @@ public: virtual ~MulComponentEngine(); + virtual char* getVersion(); + void Mul( double x , double y , double & z ) ; private: diff --git a/src/SIGNALSComponent/Makefile.am b/src/SIGNALSComponent/Makefile.am index 469ff54..8fcd69d 100755 --- a/src/SIGNALSComponent/Makefile.am +++ b/src/SIGNALSComponent/Makefile.am @@ -47,7 +47,8 @@ libSIGNALSComponentEngine_la_CPPFLAGS = \ $(CORBA_CXXFLAGS) \ $(CORBA_INCLUDES) \ $(KERNEL_CXXFLAGS) \ - -I$(top_builddir)/idl + -I$(top_builddir)/idl \ + -I$(top_builddir) libSIGNALSComponentEngine_la_LDFLAGS = \ ../../idl/libSalomeIDLCOMPONENT.la \ diff --git a/src/SIGNALSComponent/SIGNALSComponent_Impl.cxx b/src/SIGNALSComponent/SIGNALSComponent_Impl.cxx index 099293e..1caa05a 100755 --- a/src/SIGNALSComponent/SIGNALSComponent_Impl.cxx +++ b/src/SIGNALSComponent/SIGNALSComponent_Impl.cxx @@ -33,6 +33,7 @@ //#include "utilities.h" #include "SIGNALSComponent_Impl.hxx" +#include "COMPONENT_version.h" using namespace std; @@ -60,6 +61,15 @@ SIGNALSComponent_Impl::~SIGNALSComponent_Impl() { } +char* SIGNALSComponent_Impl::getVersion() +{ +#if COMPONENT_DEVELOPMENT + return CORBA::string_dup(COMPONENT_VERSION_STR"dev"); +#else + return CORBA::string_dup(COMPONENT_VERSION_STR); +#endif +} + CORBA::Long SIGNALSComponent_Impl::SIGSEGVfunc() { beginService( " SIGNALSComponent_Impl::SIGSEGVfunc" ); cout << pthread_self() << "SIGNALSComponent_Impl::SIGSEGVfunc" << endl ; diff --git a/src/SIGNALSComponent/SIGNALSComponent_Impl.hxx b/src/SIGNALSComponent/SIGNALSComponent_Impl.hxx index d7c4f94..9f31612 100755 --- a/src/SIGNALSComponent/SIGNALSComponent_Impl.hxx +++ b/src/SIGNALSComponent/SIGNALSComponent_Impl.hxx @@ -47,6 +47,8 @@ public: virtual ~SIGNALSComponent_Impl(); + virtual char* getVersion(); + CORBA::Long SIGSEGVfunc() ; CORBA::Long SIGFPEfunc( CORBA::Long a , CORBA::Long b ) ; void MethodToKill() ; diff --git a/src/SubComponent/Makefile.am b/src/SubComponent/Makefile.am index 3ed7e78..87cf3b3 100755 --- a/src/SubComponent/Makefile.am +++ b/src/SubComponent/Makefile.am @@ -40,7 +40,8 @@ libSubComponentEngine_la_CPPFLAGS = \ $(CORBA_CXXFLAGS) \ $(CORBA_INCLUDES) \ $(KERNEL_CXXFLAGS) \ - -I$(top_builddir)/idl + -I$(top_builddir)/idl \ + -I$(top_builddir) libSubComponentEngine_la_LDFLAGS = \ ../../idl/libSalomeIDLCOMPONENT.la \ diff --git a/src/SubComponent/SubComponent.cxx b/src/SubComponent/SubComponent.cxx index ee41149..7d34775 100644 --- a/src/SubComponent/SubComponent.cxx +++ b/src/SubComponent/SubComponent.cxx @@ -31,7 +31,7 @@ #include #include -//#include "utilities.h" +#include "COMPONENT_version.h" #include "SubComponent.hxx" using namespace std; @@ -58,6 +58,15 @@ SubComponentEngine::~SubComponentEngine() { } +char* SubComponentEngine::getVersion() +{ +#if COMPONENT_DEVELOPMENT + return CORBA::string_dup(COMPONENT_VERSION_STR"dev"); +#else + return CORBA::string_dup(COMPONENT_VERSION_STR); +#endif +} + void SubComponentEngine::Sub( double x , double y , double & z ) { beginService( " SubComponentEngine::Sub" ); z = x - y ; diff --git a/src/SubComponent/SubComponent.hxx b/src/SubComponent/SubComponent.hxx index 8c2d719..20513c2 100644 --- a/src/SubComponent/SubComponent.hxx +++ b/src/SubComponent/SubComponent.hxx @@ -29,7 +29,6 @@ #ifndef _SUBCOMPONENTENGINE_HXX_ #define _SUBCOMPONENTENGINE_HXX_ -//#include #include #include CORBA_SERVER_HEADER(SubComponent) #include CORBA_SERVER_HEADER(SALOME_Component) @@ -47,6 +46,8 @@ public: virtual ~SubComponentEngine(); + virtual char* getVersion(); + void Sub( double x , double y , double & z ) ; private: diff --git a/src/SyrComponent/Makefile.am b/src/SyrComponent/Makefile.am index 0e02d99..09eb305 100755 --- a/src/SyrComponent/Makefile.am +++ b/src/SyrComponent/Makefile.am @@ -47,7 +47,9 @@ libSyrComponentEngine_la_CPPFLAGS = \ $(CORBA_INCLUDES) \ $(KERNEL_CXXFLAGS) \ -I$(srcdir)/../AddComponent \ - -I$(top_builddir)/idl + -I$(top_builddir)/idl \ + -I$(top_builddir) + libSyrComponentEngine_la_LDFLAGS = \ ../../idl/libSalomeIDLCOMPONENT.la \ $(KERNEL_LDFLAGS) \ diff --git a/src/SyrComponent/SyrComponent_Impl.cxx b/src/SyrComponent/SyrComponent_Impl.cxx index 12f36e4..47461c2 100755 --- a/src/SyrComponent/SyrComponent_Impl.cxx +++ b/src/SyrComponent/SyrComponent_Impl.cxx @@ -31,8 +31,7 @@ #include #include -//#include "utilities.h" - +#include "COMPONENT_version.h" #include "SyrComponent_Impl.hxx" #include "Adder_Impl.hxx" @@ -60,6 +59,15 @@ SyrComponent_Impl::SyrComponent_Impl() { SyrComponent_Impl::~SyrComponent_Impl() { } +char* SyrComponent_Impl::getVersion() +{ +#if COMPONENT_DEVELOPMENT + return CORBA::string_dup(COMPONENT_VERSION_STR"dev"); +#else + return CORBA::string_dup(COMPONENT_VERSION_STR); +#endif +} + CORBA::Long SyrComponent_Impl::C_ISEVEN( CORBA::Long anInteger ) { bool RetVal ; beginService( " SyrComponent_Impl::C_ISEVEN" ); @@ -307,6 +315,15 @@ ListOfSyr_Impl::~ListOfSyr_Impl() { endService( "ListOfSyr_Impl::~ListOfSyr_Impl" ); } +char* ListOfSyr_Impl::getVersion() +{ +#if COMPONENT_DEVELOPMENT + return CORBA::string_dup(COMPONENT_VERSION_STR"dev"); +#else + return CORBA::string_dup(COMPONENT_VERSION_STR); +#endif +} + SuperVisionTest::SeqOfSyr * ListOfSyr_Impl::GetSeqOfSyr() { SuperVisionTest::SeqOfSyr_var aSeqOfSyr = new SuperVisionTest::SeqOfSyr( _SeqOfSyr ) ; return ( aSeqOfSyr._retn() ) ; diff --git a/src/SyrComponent/SyrComponent_Impl.hxx b/src/SyrComponent/SyrComponent_Impl.hxx index 2196e53..274a4fa 100755 --- a/src/SyrComponent/SyrComponent_Impl.hxx +++ b/src/SyrComponent/SyrComponent_Impl.hxx @@ -48,6 +48,8 @@ public: virtual ~SyrComponent_Impl(); + virtual char* getVersion(); + virtual CORBA::Long C_ISEVEN( CORBA::Long anInteger ) ; virtual CORBA::Long C_ISONE( CORBA::Long anOddInteger ) ; @@ -96,6 +98,8 @@ public: ListOfSyr_Impl() ; virtual ~ListOfSyr_Impl(); + virtual char* getVersion(); + virtual SuperVisionTest::SeqOfSyr * GetSeqOfSyr() ; virtual void SetSeqOfSyr( const SuperVisionTest::SeqOfSyr & ) ; diff --git a/src/SyrControlComponent/SyrControlComponent.py b/src/SyrControlComponent/SyrControlComponent.py index c2b8362..9d57c7c 100644 --- a/src/SyrControlComponent/SyrControlComponent.py +++ b/src/SyrControlComponent/SyrControlComponent.py @@ -141,3 +141,7 @@ class SyrControlComponent( SuperVisionTest__POA.SyrControlComponent, SALOME_Comp self.Syr = lcc.FindOrLoadComponent( 'FactoryServer' , 'SyrComponent' ) print "SyrControlComponent::__init__",dir(self.Syr) + def getVersion( self ): + import salome_version + return salome_version.getVersion("COMPONENT", True) + diff --git a/src/TypesCheck/Makefile.am b/src/TypesCheck/Makefile.am index a0524be..f05d161 100755 --- a/src/TypesCheck/Makefile.am +++ b/src/TypesCheck/Makefile.am @@ -46,7 +46,9 @@ libTypesCheckEngine_la_CPPFLAGS = \ $(CORBA_INCLUDES) \ $(KERNEL_CXXFLAGS) \ -I$(srcdir)/../AddComponent \ - -I$(top_builddir)/idl + -I$(top_builddir)/idl \ + -I$(top_builddir) + libTypesCheckEngine_la_LDFLAGS = \ ../../idl/libSalomeIDLCOMPONENT.la \ $(KERNEL_LDFLAGS) \ diff --git a/src/TypesCheck/TypesCheck_Impl.cxx b/src/TypesCheck/TypesCheck_Impl.cxx index daf7394..68c068c 100644 --- a/src/TypesCheck/TypesCheck_Impl.cxx +++ b/src/TypesCheck/TypesCheck_Impl.cxx @@ -32,6 +32,7 @@ #include #include "TypesCheck_Impl.hxx" +#include "COMPONENT_version.h" using namespace std; @@ -61,6 +62,15 @@ TypesCheck_Impl::~TypesCheck_Impl() { endService( "TypesCheck_Impl::~TypesCheck_Impl" ); } +char* TypesCheck_Impl::getVersion() +{ +#if COMPONENT_DEVELOPMENT + return CORBA::string_dup(COMPONENT_VERSION_STR"dev"); +#else + return CORBA::string_dup(COMPONENT_VERSION_STR); +#endif +} + void TypesCheck_Impl::StringCheck( const char * InString , _CORBA_String_out OutString ) { beginService( "TypesCheck_Impl::StringCheck" ); OutString = CORBA::string_dup( InString ) ; diff --git a/src/TypesCheck/TypesCheck_Impl.hxx b/src/TypesCheck/TypesCheck_Impl.hxx index 7fc11fc..c18a202 100644 --- a/src/TypesCheck/TypesCheck_Impl.hxx +++ b/src/TypesCheck/TypesCheck_Impl.hxx @@ -50,6 +50,8 @@ class TypesCheck_Impl : public POA_SuperVisionTest::TypesCheck , virtual ~TypesCheck_Impl(); + virtual char* getVersion(); + virtual void StringCheck( const char * InString , _CORBA_String_out OutString ) ; virtual void BoolCheck( CORBA::Boolean InBool , CORBA::Boolean & OutBool ) ; diff --git a/src/UndefinedSymbolComponent/Makefile.am b/src/UndefinedSymbolComponent/Makefile.am index 1302229..4fff18c 100755 --- a/src/UndefinedSymbolComponent/Makefile.am +++ b/src/UndefinedSymbolComponent/Makefile.am @@ -40,7 +40,8 @@ libUndefinedSymbolComponentEngine_la_CPPFLAGS = \ $(CORBA_CXXFLAGS) \ $(CORBA_INCLUDES) \ $(KERNEL_CXXFLAGS) \ - -I$(top_builddir)/idl + -I$(top_builddir)/idl \ + -I$(top_builddir) libUndefinedSymbolComponentEngine_la_LDFLAGS = \ ../../idl/libSalomeIDLCOMPONENT.la \ diff --git a/src/UndefinedSymbolComponent/UndefinedSymbolComponent.cxx b/src/UndefinedSymbolComponent/UndefinedSymbolComponent.cxx index 6a28580..99f96c6 100755 --- a/src/UndefinedSymbolComponent/UndefinedSymbolComponent.cxx +++ b/src/UndefinedSymbolComponent/UndefinedSymbolComponent.cxx @@ -33,6 +33,7 @@ //#include "utilities.h" #include "UndefinedSymbolComponent.hxx" +#include "COMPONENT_version.h" using namespace std; @@ -58,6 +59,15 @@ UndefinedSymbolComponentEngine::~UndefinedSymbolComponentEngine() { } +char* UndefinedSymbolComponentEngine::getVersion() +{ +#if COMPONENT_DEVELOPMENT + return CORBA::string_dup(COMPONENT_VERSION_STR"dev"); +#else + return CORBA::string_dup(COMPONENT_VERSION_STR); +#endif +} + extern "C" { long CallUndefined() ; } ; CORBA::Long UndefinedSymbolComponentEngine::UndefinedSymbol() { diff --git a/src/UndefinedSymbolComponent/UndefinedSymbolComponent.hxx b/src/UndefinedSymbolComponent/UndefinedSymbolComponent.hxx index 2717dc5..9e61bac 100755 --- a/src/UndefinedSymbolComponent/UndefinedSymbolComponent.hxx +++ b/src/UndefinedSymbolComponent/UndefinedSymbolComponent.hxx @@ -47,6 +47,8 @@ public: virtual ~UndefinedSymbolComponentEngine(); + virtual char* getVersion(); + CORBA::Long UndefinedSymbol() ; private: -- 2.39.2