def __new__(cls, *_args, **kwargs):
if _args:<EOL><INDENT>if len(_args) == <NUM_LIT:1> and isinstance(_args[<NUM_LIT:0>], dict):<EOL><INDENT>if kwargs:<EOL><INDENT>raise TypeError('<STR_LIT>'<EOL>'<STR_LIT>'<EOL>'<STR_LIT>')<EOL><DEDENT>kwargs = _args[<NUM_LIT:0>]<EOL><DEDENT>else:<EOL><INDENT>if '<STR_LIT>' in kwargs:<EOL><INDENT>raise TypeError('<STR_LIT>'<EOL>'<STR_LIT>')<EOL><DEDENT>kwargs['<STR_LIT>'] = _args<EOL><DEDENT><DEDENT>self = super(Key, cls).__new__(cls)<EOL>if '<STR_LIT>' in kwargs or '<STR_LIT>' in kwargs or '<STR_LIT>' in kwargs:<EOL><INDENT>(self.__reference,<EOL>self.__pairs,<EOL>self.__app,<EOL>self.__namespace) = self._parse_from_ref(cls, **kwargs)<EOL><DEDENT>elif '<STR_LIT>' in kwargs or '<STR_LIT>' in kwargs:<EOL><INDENT>self.__reference = None<EOL>(self.__pairs,<EOL>self.__app,<EOL>self.__namespace) = self._parse_from_args(**kwargs)<EOL><DEDENT>else:<EOL><INDENT>raise TypeError('<STR_LIT>')<EOL><DEDENT>return self<EOL>
Constructor.  See the class docstring for arguments.