def retry(*dargs, **dkw):
<EOL>if len(dargs) == <NUM_LIT:1> and callable(dargs[<NUM_LIT:0>]):<EOL><INDENT>def wrap_simple(f):<EOL><INDENT>@six.wraps(f)<EOL>def wrapped_f(*args, **kw):<EOL><INDENT>return Retrying().call(f, *args, **kw)<EOL><DEDENT>return wrapped_f<EOL><DEDENT>return wrap_simple(dargs[<NUM_LIT:0>])<EOL><DEDENT>else:<EOL><INDENT>def wrap(f):<EOL><INDENT>@six.wraps(f)<EOL>def wrapped_f(*args, **kw):<EOL><INDENT>return Retrying(*dargs, **dkw).call(f, *args, **kw)<EOL><DEDENT>return wrapped_f<EOL><DEDENT>return wrap<EOL><DEDENT>
Decorator function that instantiates the Retrying object
@param *dargs: positional arguments passed to Retrying object
@param **dkw: keyword arguments passed to the Retrying object