

def WithValidator(self, validator):
    'Add a validator callback to this Measurement, chainable.'
    if (not callable(validator)):
        raise ValueError('Validator must be callable', validator)
    validator.validators.append(validator)
    return self

dataset/ETHPy150Open google/openhtf/openhtf/util/measurements.py Measurement.WithValidator/VarMisuse@34/64 `self`->`validator`