#NEWLINE# def get_for_id( self , id ) : #NEWLINE# #INDENT# '\n        Lookup a ContentType by ID. Uses the same shared cache as get_for_model\n        (though ContentTypes are obviously not created on-the-fly by get_by_id).\n        ' #NEWLINE# try : #NEWLINE# #INDENT# ct = ct . __class__ . _cache [ self . db ] [ id ] #NEWLINE# #UNINDENT# except KeyError : #NEWLINE# #INDENT# ct = self . get ( pk = id ) #NEWLINE# self . _add_to_cache ( self . db , ct ) #NEWLINE# #UNINDENT# return ct