from typing import List
from ......Internal.Core import Core
from ......Internal.CommandsGroup import CommandsGroup
from ......Internal import Conversions
from ......Internal.Utilities import trim_str_response
# noinspection PyPep8Naming,PyAttributeOutsideInit,SpellCheckingInspection
class PconfigurationCls:
"""
| Commands in total: 2
| Subgroups: 0
| Direct child commands: 2
"""
def __init__(self, core: Core, parent):
self._core = core
self._cmd_group = CommandsGroup("pconfiguration", core, parent)
[docs]
def get_catalog(self) -> List[str]:
"""
``[SOURce<HW>]:BB:V5G:SETTing:PCONfiguration:CATalog`` \n
Snippet: ``value: List[str] = driver.source.bb.v5G.setting.pconfiguration.get_catalog()`` \n
Queries the available configuration files in the default directory. Only predefined files are listed.
"""
response = self._core.io.query_str('SOURce<HwInstance>:BB:V5G:SETTing:PCONfiguration:CATalog?')
return Conversions.str_to_str_list(response)
[docs]
def get_value(self) -> str:
"""
``[SOURce<HW>]:BB:V5G:SETTing:PCONfiguration`` \n
Snippet: ``value: str = driver.source.bb.v5G.setting.pconfiguration.get_value()`` \n
Selects a predefined configuration.
:return: test_scenario: string Filename as returned by the query method ``RsSmw.source.bb.v5G.setting.pconfiguration.catalog()`` . File extension is omitted.
"""
response = self._core.io.query_str('SOURce<HwInstance>:BB:V5G:SETTing:PCONfiguration?')
return trim_str_response(response)
[docs]
def set_value(self, test_scenario: str) -> None:
"""
``[SOURce<HW>]:BB:V5G:SETTing:PCONfiguration`` \n
Snippet: ``driver.source.bb.v5G.setting.pconfiguration.set_value(test_scenario = 'abc')`` \n
Selects a predefined configuration.
:param test_scenario: string Filename as returned by the query method ``RsSmw.source.bb.v5G.setting.pconfiguration.catalog()`` . File extension is omitted.
"""
param = Conversions.value_to_quoted_str(test_scenario)
self._core.io.write(f'SOURce<HwInstance>:BB:V5G:SETTing:PCONfiguration {param}')