Version: 9.15.0
SALOME_NamingService_Wrapper.hxx
Go to the documentation of this file.
1 // Copyright (C) 2021-2025 CEA, EDF
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_Abstract.hxx"
24 
25 #include <memory>
26 
33 {
34 public:
36  SALOME_NamingService_Wrapper(CORBA::ORB_ptr orb);
37  std::vector< std::string > repr() override { return _effective_ns->repr(); }
38  void init_orb(CORBA::ORB_ptr orb=0) override { _effective_ns->init_orb(orb); }
39  bool IsTrueNS() const override { return _effective_ns->IsTrueNS(); }
40  void Register(CORBA::Object_ptr ObjRef, const char* Path) override { _effective_ns->Register(ObjRef,Path); }
41  CORBA::Object_ptr Resolve(const char* Path) override { return _effective_ns->Resolve(Path); }
42  CORBA::Object_ptr ResolveFirst(const char* Path) override { return _effective_ns->ResolveFirst(Path); }
43  void Destroy_Name(const char* Path) override { _effective_ns->Destroy_Name(Path); }
44  void Destroy_Directory(const char* Path) override { _effective_ns->Destroy_Directory(Path); }
45  void Destroy_FullDirectory(const char* Path) override { _effective_ns->Destroy_FullDirectory(Path); }
46  bool Change_Directory(const char* Path) override { return _effective_ns->Change_Directory(Path); }
47  std::vector<std::string> list_subdirs() override { return _effective_ns->list_directory(); }
48  std::vector<std::string> list_directory() override { return _effective_ns->list_directory(); }
49  std::vector<std::string> list_directory_recurs() override { return _effective_ns->list_directory_recurs(); }
51  CORBA::Object_ptr ResolveComponent(const char* hostname, const char* containerName, const char* componentName, const int nbproc=0) override { return _effective_ns->ResolveComponent(hostname,containerName,componentName,nbproc); }
52 private:
54  void initializeEffectiveNS();
55 private:
56  std::unique_ptr<SALOME_NamingService_Abstract> _effective_ns;
57 };
#define YACSRUNTIMESALOME_EXPORT
std::vector< std::string > list_directory_recurs() override
void init_orb(CORBA::ORB_ptr orb=0) override
std::vector< std::string > list_directory() override
std::vector< std::string > list_subdirs() override
CORBA::Object_ptr ResolveComponent(const char *hostname, const char *containerName, const char *componentName, const int nbproc=0) override
std::unique_ptr< SALOME_NamingService_Abstract > _effective_ns
std::vector< std::string > repr() override
void Register(CORBA::Object_ptr ObjRef, const char *Path) override
SALOME_NamingService_Abstract * clone() override
void Destroy_Name(const char *Path) override
bool Change_Directory(const char *Path) override
void Destroy_Directory(const char *Path) override
CORBA::Object_ptr Resolve(const char *Path) override
CORBA::Object_ptr ResolveFirst(const char *Path) override
void Destroy_FullDirectory(const char *Path) override
CORBA::ORB_ptr orb
Definition: yacsSrv.cxx:39