Module Expr Str ImportFrom alias ImportFrom alias ImportFrom alias alias ClassDef bases AttributeLoad NameLoad attr body Assign NameStore Call AttributeLoad NameLoad attr keyword Num FunctionDef arguments args NameParam defaults body Return AttributeLoad NameLoad attr decorator_list decorator_list ClassDef bases AttributeLoad NameLoad attr body FunctionDef arguments args NameParam defaults body Return Call AttributeLoad Call AttributeLoad Call NameLoad NameLoad NameLoad attr attr keyword Str decorator_list decorator_list ClassDef bases AttributeLoad NameLoad attr body Assign NameStore Call AttributeLoad NameLoad attr NameLoad Assign NameStore Call AttributeLoad NameLoad attr keyword Num Assign NameStore Call AttributeLoad NameLoad attr Assign NameStore Call NameLoad FunctionDef arguments args NameParam defaults body Return AttributeLoad NameLoad attr decorator_list decorator_list
N/A N/A 
35. DB-API Shortcuts

``get_object_or_404()`` is a shortcut function to be used in view functions for
performing a ``get()`` lookup and raising a ``Http404`` exception if a
``DoesNotExist`` exception was raised during the ``get()`` call.

``get_list_or_404()`` is a shortcut function to be used in view functions for
performing a ``filter()`` lookup and raising a ``Http404`` exception if a
``DoesNotExist`` exception was raised during the ``filter()`` call.
 django.db models django.http Http404 django.shortcuts get_object_or_404 get_list_or_404 Author N/A N/A models Model N/A N/A name N/A N/A models CharField max_length 50 __unicode__ N/A N/A self N/A N/A N/A N/A self name N/A N/A ArticleManager N/A N/A models Manager N/A get_query_set N/A N/A self N/A N/A N/A N/A N/A N/A N/A N/A super ArticleManager self get_query_set filter authors__name__icontains sir N/A N/A Article N/A N/A models Model N/A N/A authors N/A N/A models ManyToManyField Author N/A title N/A N/A models CharField max_length 50 N/A objects N/A N/A models Manager N/A by_a_sir N/A ArticleManager __unicode__ N/A N/A self N/A N/A N/A N/A self title N/A N/A