def _extract(self, item):
if not item:<EOL><INDENT>raise ValueError('<STR_LIT>')<EOL><DEDENT>handler = None<EOL>memoize = False<EOL>timeout = <NUM_LIT:0><EOL>if not isinstance(item, (list, tuple, dict)):<EOL><INDENT>handler = item<EOL><DEDENT>elif isinstance(item, (list, tuple)):<EOL><INDENT>if len(item) == <NUM_LIT:3>:<EOL><INDENT>handler, memoize, timeout = item<EOL><DEDENT>elif len(item) == <NUM_LIT:2>:<EOL><INDENT>handler, memoize = item<EOL><DEDENT>elif len(item) == <NUM_LIT:1>:<EOL><INDENT>handler = item<EOL><DEDENT><DEDENT>elif isinstance(item, dict):<EOL><INDENT>handler = item.get('<STR_LIT>')<EOL>memoize = item.get('<STR_LIT>', False)<EOL>timeout = item.get('<STR_LIT>', <NUM_LIT:0>)<EOL><DEDENT>return handler, bool(memoize), float(timeout)<EOL>
Extracts a handler and handler's arguments that can be provided 
        as list or dictionary. If arguments are provided as list, they are 
        considered to have this sequence: (handler, memoize, timeout)                
        Examples:
            event += handler
            event += (handler, True, 1.5)
            event += {'handler':handler, 'memoize':True, 'timeout':1.5}