Skip to content

Commit aed5138

Browse files
committed
[ModelicaSystem] rename variable / function
setCommandLineOptions() => set_command_line_options() commandLineOptions => command_line_option
1 parent 3e0afd2 commit aed5138

1 file changed

Lines changed: 4 additions & 4 deletions

File tree

OMPython/ModelicaSystem.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -375,7 +375,7 @@ def __init__(
375375
"--generateSymbolicLinearization",
376376
]
377377
for opt in command_line:
378-
self.setCommandLineOptions(commandLineOptions=opt)
378+
self.set_command_line_options(command_line_option=opt)
379379

380380
self._simulated = False # True if the model has already been simulated
381381
self._result_file: Optional[OMCPath] = None # for storing result file
@@ -476,11 +476,11 @@ def session(self) -> OMCSessionZMQ:
476476
"""
477477
return self._session
478478

479-
def setCommandLineOptions(self, commandLineOptions: str):
479+
def set_command_line_options(self, command_line_option: str):
480480
"""
481481
Set the provided command line option via OMC setCommandLineOptions().
482482
"""
483-
exp = f'setCommandLineOptions("{commandLineOptions}")'
483+
exp = f'setCommandLineOptions("{command_line_option}")'
484484
self.sendExpression(exp)
485485

486486
def _loadFile(self, fileName: OMCPath):
@@ -1711,7 +1711,7 @@ def optimize(self) -> dict[str, Any]:
17111711
"""
17121712
cName = self._model_name
17131713
properties = ','.join(f"{key}={val}" for key, val in self._optimization_options.items())
1714-
self.setCommandLineOptions("-g=Optimica")
1714+
self.set_command_line_options("-g=Optimica")
17151715
optimizeResult = self._requestApi(apiName='optimize', entity=cName, properties=properties)
17161716

17171717
return optimizeResult

0 commit comments

Comments
 (0)