diff options
Diffstat (limited to 'qtip/base')
-rw-r--r-- | qtip/base/constant.py | 6 | ||||
-rw-r--r-- | qtip/base/error.py | 13 |
2 files changed, 16 insertions, 3 deletions
diff --git a/qtip/base/constant.py b/qtip/base/constant.py index 187f0706..76481b47 100644 --- a/qtip/base/constant.py +++ b/qtip/base/constant.py @@ -8,8 +8,8 @@ ############################################################################## -class AlgoName(object): - """algorithm names""" +class FormulaName(object): + """formula names""" ARITHMETIC_MEAN = 'arithmetic mean' WEIGHTED_ARITHMETIC_MEAN = 'weighted arithmetic mean' GEOMETRIC_MEAN = 'geometric mean' @@ -37,7 +37,7 @@ class PropName(object): # spec SECTIONS = 'sections' WEIGHT = 'weight' - ALGORITHM = 'algorithm' + FORMULA = 'formula' METRICS = 'metrics' WORKLOADS = 'workloads' # plan diff --git a/qtip/base/error.py b/qtip/base/error.py index d364c532..01a7f7a6 100644 --- a/qtip/base/error.py +++ b/qtip/base/error.py @@ -21,3 +21,16 @@ class NotFound(QtipError): def __init__(self, module, package='qtip'): self.package = package self.module = module + + +class ToBeDoneError(QtipError): + """something still to be done""" + def __init__(self, method, module): + self.method = method + self.module = module + + +def make_tbd(method, module='qtip'): + def tbd(): + raise ToBeDoneError(method, module) + return tbd |