def __init__(O, options): O.options = options if (options.dynamic_parameter is None): O.dynamic_parameters = None else: from fable.cout import dynamic_parameter_props O.dynamic_parameters = [] for opt_dp in options.dynamic_parameter: flds = opt_dp.replace("=", " ").split() if (len(flds) != 3): sys.exit('Invalid --dynamic-parameter="%s"' % opt_dp) if (flds[1] in O.dynamic_parameters): sys.exit('Duplicate --dynamic-parameter="%s"' % opt_dp) O.dynamic_parameters.append( dynamic_parameter_props(name=flds[1], ctype=flds[0], default=flds[2])) O.n_calls = 0
def __init__(O, options): O.options = options if (options.dynamic_parameter is None): O.dynamic_parameters = None else: from fable.cout import dynamic_parameter_props from libtbx.utils import Sorry O.dynamic_parameters = [] for opt_dp in options.dynamic_parameter: flds = opt_dp.replace("=", " ").split() if (len(flds) != 3): raise Sorry('Invalid --dynamic-parameter="%s"' % opt_dp) if (flds[1] in O.dynamic_parameters): raise Sorry('Duplicate --dynamic-parameter="%s"' % opt_dp) O.dynamic_parameters.append(dynamic_parameter_props( name=flds[1], ctype=flds[0], default=flds[2])) O.n_calls = 0