Salome HOME
bos #26460 Add SSL mode
[samples/atomsolv.git] / src / ATOMSOLV / ATOMSOLV.hxx
index ff7eb7b88728c314c10b6ba615f7ec84f60300f5..4d3214276a0ecf29b9f621a5651de53b4a24b467 100644 (file)
@@ -1,4 +1,4 @@
-// Copyright (C) 2007-2014  CEA/DEN, EDF R&D, OPEN CASCADE
+// Copyright (C) 2007-2021  CEA/DEN, EDF R&D, OPEN CASCADE
 //
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 #endif
 
 
-class ATOMSOLV_EXPORT ATOMSOLV:
+class ATOMSOLV_EXPORT ATOMSOLV_Abstract:
   public POA_ATOMSOLV_ORB::ATOMSOLV_Gen,
   public Engines_Component_i 
 {
 
 public:
-  ATOMSOLV(CORBA::ORB_ptr orb,
+  ATOMSOLV_Abstract(CORBA::ORB_ptr orb,
           PortableServer::POA_ptr poa,
           PortableServer::ObjectId * contId, 
           const char *instanceName, 
-          const char *interfaceName);
-  virtual ~ATOMSOLV();
+          const char *interfaceName,
+     bool withRegistry = true);
+  virtual ~ATOMSOLV_Abstract();
 
-  CORBA::Boolean setData( CORBA::Long studyID, const ATOMSOLV_ORB::TMoleculeList& theData );
-  CORBA::Boolean getData( CORBA::Long studyID, ATOMSOLV_ORB::TMoleculeList_out outData );
-  CORBA::Boolean processData( CORBA::Long studyID );
+  CORBA::Boolean setData( const ATOMSOLV_ORB::TMoleculeList& theData );
+  CORBA::Boolean getData( ATOMSOLV_ORB::TMoleculeList_out outData );
+  CORBA::Boolean processData();
   virtual char*  getVersion();
 
 private:
-  std::map<long, ATOMSOLV_ORB::TMoleculeList*> myData;
+  ATOMSOLV_ORB::TMoleculeList* myData;
+};
+
+class ATOMSOLV_EXPORT ATOMSOLV_Session : public ATOMSOLV_Abstract
+{
+public:
+  ATOMSOLV_Session( CORBA::ORB_ptr orb,
+        PortableServer::POA_ptr poa,
+        PortableServer::ObjectId* contId, 
+        const char* instanceName, 
+        const char* interfaceName):ATOMSOLV_Abstract(orb,poa,contId,instanceName,interfaceName,true) { }
+};
+
+class ATOMSOLV_EXPORT ATOMSOLV_No_Session : public ATOMSOLV_Abstract
+{
+public:
+  ATOMSOLV_No_Session( CORBA::ORB_ptr orb,
+        PortableServer::POA_ptr poa,
+        PortableServer::ObjectId* contId, 
+        const char* instanceName, 
+        const char* interfaceName):ATOMSOLV_Abstract(orb,poa,contId,instanceName,interfaceName,false) { }
 };
 
 extern "C"