title: Django CBV get list, get object
body: <p>I've got a simple CBV for all CRUD operations on my model (let's say Book). How should I implement getting object by id and getting a list of all objects? Seems there are many options like:</p>
  
  <ol>
  <li><p>Just create two separate classes Book and BookList.</p></li>
  <li><p>Write some kind of dispatcher inside get method.</p>
  
  <pre><code>class BookView(View):
      def get(self, request, *args, **kwargs):
          if 'id' in self.kwargs:
              self.get_object(request, *args, **kwargs)
          else:
              self.get_list(request, *args, **kwargs)
  </code></pre></li>
  <li><p>Override View.dispatch method so that it will call get_list() method if no id provided.</p></li>
  </ol>
  
  <p>etc...</p>
  
  <p>So what is best way?</p>