Salome HOME
[EDF30062] : Forward of current directory mecanism
[modules/kernel.git] / src / Basics / KernelBasis.hxx
index 710106ff3266a95ba35a383226bc0d4f269e6703..de5c1e092422700d04b6443ac9b00c7ac7a54ff0 100644 (file)
@@ -1,4 +1,4 @@
-// Copyright (C) 2021  CEA/DEN, EDF R&D
+// Copyright (C) 2021-2024  CEA, EDF
 //
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 #include "SALOME_Basics.hxx"
 
 #include <string>
+#include <vector>
 
 bool BASICS_EXPORT getSSLMode();
 void BASICS_EXPORT setSSLMode(bool sslMode);
+bool BASICS_EXPORT getGUIMode();
+void BASICS_EXPORT setGUIMode(bool guiMode);
 
 std::string BASICS_EXPORT getIOROfEmbeddedNS();
 void BASICS_EXPORT setIOROfEmbeddedNS(const std::string& ior);
+
+void BASICS_EXPORT WriteInStdout(const std::string& msg);
+void BASICS_EXPORT WriteInStderr(const std::string& msg);
+
+namespace SALOME
+{
+  constexpr char SHARED_FILE_SYSTEM_PROTOCOL = 0;
+  constexpr char SSD_COPY_FILE_SYSTEM_PROTOCOL = 1;
+  const char SHARED_FILE_SYSTEM_PROTOCOL_STR[] = "SharedFileSystem";
+  const char SSD_COPY_FILE_SYSTEM_PROTOCOL_STR[] = "SSDCopyFileSystem";
+
+  enum class PyExecutionMode { NotSet, InProcess, OutOfProcessNoReplay, OutOfProcessWithReplay, OutOfProcessNoReplayFT, OutOfProcessWithReplayFT };
+
+  enum class BigObjTransferProtocol : char
+  { SharedFileSystem = SHARED_FILE_SYSTEM_PROTOCOL, SSDCopyFileSystem = SSD_COPY_FILE_SYSTEM_PROTOCOL };
+
+  void BASICS_EXPORT SetPyExecutionMode(PyExecutionMode mode);
+  void BASICS_EXPORT SetPyExecutionModeStr(const std::string& mode);
+  std::vector<std::string> BASICS_EXPORT GetAllPyExecutionModes();
+  std::string BASICS_EXPORT GetPyExecutionModeStr();
+  PyExecutionMode BASICS_EXPORT GetPyExecutionMode();
+  std::string BASICS_EXPORT GetDirectoryForReplayFiles();
+  void BASICS_EXPORT SetDirectoryForReplayFiles(const std::string& directory);
+  int BASICS_EXPORT GetBigObjOnDiskThreshold();
+  void BASICS_EXPORT SetBigObjOnDiskThreshold(int newThresholdInByte);
+  std::string BASICS_EXPORT BigObjOnDiskProtocolToStr(BigObjTransferProtocol protocol);
+  BigObjTransferProtocol BASICS_EXPORT BigObjOnDiskProtocolFromStr(const std::string& protocol);
+  BigObjTransferProtocol BASICS_EXPORT FromIntToBigObjOnDiskProtocol(char protocol);
+  BigObjTransferProtocol BASICS_EXPORT GetBigObjOnDiskProtocolAndDirectory(std::string& directory);
+  std::string BASICS_EXPORT GetBigObjOnDiskDirectoryCoarse();
+  void BASICS_EXPORT SetBigObjOnDiskDirectory(const std::string& directory);
+  bool BASICS_EXPORT BigObjOnDiskDirectoryDefined();
+  void BASICS_EXPORT SetNumberOfRetry(int nbRetry);
+  int BASICS_EXPORT GetNumberOfRetry();
+  bool BASICS_EXPORT GetForwardCurrentDirectoryStatus();
+  void BASICS_EXPORT SetForwardCurrentDirectoryStatus(bool newStatus);
+  std::string BASICS_EXPORT GetCurrentWorkingDirectory();
+}