atef.config.PreparedPVConfiguration

class atef.config.PreparedPVConfiguration(cache: 'DataCache', parent: 'Optional[PreparedGroup]' = None, comparisons: 'List[PreparedSignalComparison]' = <factory>, prepare_failures: 'List[PreparedComparisonException]' = <factory>, combined_result: 'Result' = <factory>, config: 'PVConfiguration' = <factory>)[source]
Attributes:
parent
result

Re-compute the combined result and return it

Methods

compare()

Run all comparisons and return a combined result.

from_config(config[, parent, cache])

Prepare a PVConfiguration for running.

from_pvs(by_pv[, shared, parent, cache])

Ready a set of PV checks without requiring an existing PVConfiguration.

walk_comparisons()

Walk through the prepared comparisons.

Methods

__init__(cache: ~atef.cache.DataCache, parent: ~atef.config.PreparedGroup | None = None, comparisons: ~typing.List[~atef.config.PreparedSignalComparison] = <factory>, prepare_failures: ~typing.List[~atef.exceptions.PreparedComparisonException] = <factory>, combined_result: ~atef.result.Result = <factory>, config: ~atef.config.PVConfiguration = <factory>) None
async compare() Result

Run all comparisons and return a combined result.

classmethod from_config(config: PVConfiguration, parent: PreparedGroup | None = None, cache: DataCache | None = None) PreparedPVConfiguration[source]

Prepare a PVConfiguration for running.

Parameters:
configPVConfiguration

The configuration settings.

parentPreparedGroup, optional

The parent group.

cacheDataCache, optional

The data cache instance, if available. If unspecified, a new data cache will be instantiated.

Returns:
PreparedPVConfiguration
classmethod from_pvs(by_pv: Dict[str, List[Comparison]], shared: List[Comparison] | None = None, parent: PreparedGroup | None = None, cache: DataCache | None = None) PreparedPVConfiguration[source]

Ready a set of PV checks without requiring an existing PVConfiguration.

Parameters:
by_pvDict[str, List[Comparison]]

PV name to comparison list.

sharedlist of Comparison, optional

Comparisons to be run on all PVs in the by_pv dictionary.

parentPreparedGroup, optional

The parent group.

cacheDataCache, optional

The data cache instance, if available. If unspecified, a new data cache will be instantiated.

Returns:
PreparedPVConfiguration
walk_comparisons() Generator[PreparedComparison, None, None]

Walk through the prepared comparisons.

Attributes

parent: PreparedGroup | None = None

The hierarchical parent of this step.

result

Re-compute the combined result and return it

config: PVConfiguration

The configuration settings.

comparisons: List[PreparedSignalComparison]

The comparisons to be run on the given devices.

prepare_failures: List[PreparedComparisonException]

The comparisons to be run on the given devices.

cache: DataCache

The data cache to use for the preparation step.

combined_result: Result

The result of all comparisons.