]> SALOME platform Git repositories - modules/kernel.git/blob - src/NamingService/SALOME_NamingService_Abstract.hxx
Salome HOME
Kernel evolution for salome gui without neither NS nor other servers.
[modules/kernel.git] / src / NamingService / SALOME_NamingService_Abstract.hxx
1 // Copyright (C) 2021  CEA/DEN, EDF R&D, OPEN CASCADE
2 //
3 // This library is free software; you can redistribute it and/or
4 // modify it under the terms of the GNU Lesser General Public
5 // License as published by the Free Software Foundation; either
6 // version 2.1 of the License, or (at your option) any later version.
7 //
8 // This library is distributed in the hope that it will be useful,
9 // but WITHOUT ANY WARRANTY; without even the implied warranty of
10 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
11 // Lesser General Public License for more details.
12 //
13 // You should have received a copy of the GNU Lesser General Public
14 // License along with this library; if not, write to the Free Software
15 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
16 //
17 // See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
18 //
19
20 #pragma once
21
22 #include "SALOME_NamingService_defs.hxx"
23
24 #include "omniORB4/CORBA.h"
25
26 #include <vector>
27 #include <string>
28
29 class NAMINGSERVICE_EXPORT SALOME_NamingService_Abstract
30 {
31 public:
32   virtual void init_orb(CORBA::ORB_ptr orb=0) = 0;
33   virtual void Register(CORBA::Object_ptr ObjRef, const char* Path) = 0;
34   virtual CORBA::Object_ptr Resolve(const char* Path) = 0;
35   virtual CORBA::Object_ptr ResolveFirst(const char* Path) = 0; 
36   virtual void Destroy_Name(const char* Path) = 0;
37   virtual void Destroy_Directory(const char* Path) = 0;
38   virtual void Destroy_FullDirectory(const char* Path) = 0;
39   virtual bool Change_Directory(const char* Path) = 0;
40   virtual std::vector<std::string> list_subdirs() = 0;
41   virtual std::vector<std::string> list_directory() = 0;
42   virtual SALOME_NamingService_Abstract *clone() = 0;
43   virtual CORBA::Object_ptr ResolveComponent(const char* hostname, const char* containerName, const char* componentName, const int nbproc=0) = 0;
44   virtual ~SALOME_NamingService_Abstract() { }
45   static std::string ContainerName(const char *ContainerName);
46   static std::string BuildContainerNameForNS(const char *ContainerName, const char *hostname);
47 };