qcodes/instrument/delegate/delegate_instrument.py
def _create_and_add_parameters(
        self,
        station: Station,
        parameters: Union[Mapping[str, Sequence[str]], Mapping[str, str]],
        setters: Mapping[str, MutableMapping[str, Any]],
        units: Mapping[str, str],
    ) -> None:
        """Add parameters to delegate instrument based on specified aliases,
        endpoints and setter methods"""
        for param_name, paths in parameters.items():
            if isinstance(paths, str):
                path_list: Sequence[str] = [paths]

            elif isinstance(paths, abc.Sequence):
                path_list = paths
            else:
                raise ValueError(
                    "Parameter paths should be either a string or Sequence of \
                        strings."
                )

            self._create_and_add_parameter(
                group_name=param_name,
                station=station,
                paths=path_list,
                setter=setters.get(param_name),
                unit=units.get(param_name),
            )
Add parameters to delegate instrument based on specified aliases,
        endpoints and setter methods
Add parameters to delegate instrument based on specified aliases,
endpoints and setter methods
Add parameters to delegate instrument based on specified aliases endpoints and setter methods
def _create_and_add_parameters(
        self,
        station: Station,
        parameters: Union[Mapping[str, Sequence[str]], Mapping[str, str]],
        setters: Mapping[str, MutableMapping[str, Any]],
        units: Mapping[str, str],
    ) -> None:
        for param_name, paths in parameters.items():
            if isinstance(paths, str):
                path_list: Sequence[str] = [paths]
            elif isinstance(paths, abc.Sequence):
                path_list = paths
            else:
                raise ValueError(
                    "Parameter paths should be either a string or Sequence of \
                        strings."
                )
            self._create_and_add_parameter(
                group_name=param_name,
                station=station,
                paths=path_list,
                setter=setters.get(param_name),
                unit=units.get(param_name),
            )
def _create_and_add_parameters ( self , station : Station , parameters : Union [ Mapping [ str , Sequence [ str ] ] , Mapping [ str , str ] ] , setters : Mapping [ str , MutableMapping [ str , Any ] ] , units : Mapping [ str , str ] , ) -> None : for param_name , paths in parameters . items ( ) : if isinstance ( paths , str ) : path_list : Sequence [ str ] = [ paths ] elif isinstance ( paths , abc . Sequence ) : path_list = paths else : raise ValueError ( "Parameter paths should be either a string or Sequence of \
                        strings." ) self . _create_and_add_parameter ( group_name = param_name , station = station , paths = path_list , setter = setters . get ( param_name ) , unit = units . get ( param_name ) , )
Add parameters to delegate instrument based on specified aliases,
endpoints and setter methods
Add parameters to delegate instrument based on specified aliases endpoints and setter methods
"""Add parameters to delegate instrument based on specified aliases,
        endpoints and setter methods"""
self
station
Station
parameters
Union[Mapping[str, Sequence[str]], Mapping[str, str]]
setters
Mapping[str, MutableMapping[str, Any]]
units
Mapping[str, str]