@@ -293,7 +293,7 @@ class OMCPathReal(pathlib.PurePosixPath):
293293 errors as well as usage on a Windows system due to slightly different definitions (PureWindowsPath).
294294 """
295295
296- def __init__ (self , * path , session : OMCProcess ) -> None :
296+ def __init__ (self , * path , session : OMCSession ) -> None :
297297 super ().__init__ (* path )
298298 self ._session = session
299299
@@ -322,7 +322,7 @@ def is_absolute(self):
322322 Check if the path is an absolute path considering the possibility that we are running locally on Windows. This
323323 case needs special handling as the definition of is_absolute() differs.
324324 """
325- if isinstance (self ._session , OMCProcessLocal ) and platform .system () == 'Windows' :
325+ if isinstance (self ._session , OMCSessionLocal ) and platform .system () == 'Windows' :
326326 return pathlib .PureWindowsPath (self .as_posix ()).is_absolute ()
327327 return super ().is_absolute ()
328328
@@ -546,7 +546,7 @@ def __init__(
546546 self ,
547547 timeout : float = 10.00 ,
548548 omhome : Optional [str ] = None ,
549- omc_process : Optional [OMCProcess ] = None ,
549+ omc_process : Optional [OMCSession ] = None ,
550550 ) -> None :
551551 """
552552 Initialisation for OMCSessionZMQ
@@ -557,8 +557,8 @@ def __init__(
557557 stacklevel = 2 )
558558
559559 if omc_process is None :
560- omc_process = OMCProcessLocal (omhome = omhome , timeout = timeout )
561- elif not isinstance (omc_process , OMCProcess ):
560+ omc_process = OMCSessionLocal (omhome = omhome , timeout = timeout )
561+ elif not isinstance (omc_process , OMCSession ):
562562 raise OMCSessionException ("Invalid definition of the OMC process!" )
563563 self .omc_process = omc_process
564564
@@ -570,7 +570,7 @@ def escape_str(value: str) -> str:
570570 """
571571 Escape a string such that it can be used as string within OMC expressions, i.e. escape all double quotes.
572572 """
573- return OMCProcess .escape_str (value = value )
573+ return OMCSession .escape_str (value = value )
574574
575575 def omcpath (self , * path ) -> OMCPath :
576576 """
@@ -599,7 +599,7 @@ def run_model_executable(cmd_run_data: OMCSessionRunData) -> int:
599599 Run the command defined in cmd_run_data. This class is defined as static method such that there is no need to
600600 keep instances of over classes around.
601601 """
602- return OMCProcess .run_model_executable (cmd_run_data = cmd_run_data )
602+ return OMCSession .run_model_executable (cmd_run_data = cmd_run_data )
603603
604604 def execute (self , command : str ):
605605 return self .omc_process .execute (command = command )
@@ -641,7 +641,7 @@ def __call__(cls, *args, **kwargs):
641641 return obj
642642
643643
644- class OMCProcessMeta (abc .ABCMeta , PostInitCaller ):
644+ class OMCSessionMeta (abc .ABCMeta , PostInitCaller ):
645645 """
646646 Helper class to get a combined metaclass of ABCMeta and PostInitCaller.
647647
@@ -650,7 +650,7 @@ class OMCProcessMeta(abc.ABCMeta, PostInitCaller):
650650 """
651651
652652
653- class OMCProcess (metaclass = OMCProcessMeta ):
653+ class OMCSession (metaclass = OMCSessionMeta ):
654654 """
655655 Base class for an OMC session. This class contains common functionality for all OMC sessions.
656656
@@ -771,7 +771,7 @@ def omcpath(self, *path) -> OMCPath:
771771
772772 # fallback solution for Python < 3.12; a modified pathlib.Path object is used as OMCPath replacement
773773 if sys .version_info < (3 , 12 ):
774- if isinstance (self , OMCProcessLocal ):
774+ if isinstance (self , OMCSessionLocal ):
775775 # noinspection PyArgumentList
776776 return OMCPath (* path )
777777 raise OMCSessionException ("OMCPath is supported for Python < 3.12 only if OMCProcessLocal is used!" )
@@ -1040,7 +1040,7 @@ def omc_run_data_update(self, omc_run_data: OMCSessionRunData) -> OMCSessionRunD
10401040 raise NotImplementedError ("This method must be implemented in subclasses!" )
10411041
10421042
1043- class OMCProcessPort ( OMCProcess ):
1043+ class OMCSessionPort ( OMCSession ):
10441044 """
10451045 OMCProcess implementation which uses a port to connect to an already running OMC server.
10461046 """
@@ -1059,7 +1059,7 @@ def omc_run_data_update(self, omc_run_data: OMCSessionRunData) -> OMCSessionRunD
10591059 raise OMCSessionException ("OMCProcessPort does not support omc_run_data_update()!" )
10601060
10611061
1062- class OMCProcessLocal ( OMCProcess ):
1062+ class OMCSessionLocal ( OMCSession ):
10631063 """
10641064 OMCProcess implementation which runs the OMC server locally on the machine (Linux / Windows).
10651065 """
@@ -1185,7 +1185,7 @@ def omc_run_data_update(self, omc_run_data: OMCSessionRunData) -> OMCSessionRunD
11851185 return omc_run_data_copy
11861186
11871187
1188- class OMCProcessDockerHelper ( OMCProcess ):
1188+ class OMCSessionDockerHelper ( OMCSession ):
11891189 """
11901190 Base class for OMCProcess implementations which run the OMC server in a Docker container.
11911191 """
@@ -1322,7 +1322,7 @@ def omc_run_data_update(self, omc_run_data: OMCSessionRunData) -> OMCSessionRunD
13221322 return omc_run_data_copy
13231323
13241324
1325- class OMCProcessDocker ( OMCProcessDockerHelper ):
1325+ class OMCSessionDocker ( OMCSessionDockerHelper ):
13261326 """
13271327 OMC process running in a Docker container.
13281328 """
@@ -1465,7 +1465,7 @@ def _docker_omc_start(self) -> Tuple[subprocess.Popen, DockerPopen, str]:
14651465 return omc_process , docker_process , docker_cid
14661466
14671467
1468- class OMCProcessDockerContainer ( OMCProcessDockerHelper ):
1468+ class OMCSessionDockerContainer ( OMCSessionDockerHelper ):
14691469 """
14701470 OMC process running in a Docker container (by container ID).
14711471 """
@@ -1558,7 +1558,7 @@ def _docker_omc_start(self) -> Tuple[subprocess.Popen, DockerPopen]:
15581558 return omc_process , docker_process
15591559
15601560
1561- class OMCProcessWSL ( OMCProcess ):
1561+ class OMCSessionWSL ( OMCSession ):
15621562 """
15631563 OMC process running in Windows Subsystem for Linux (WSL).
15641564 """
0 commit comments