parameters: (request, serializer, default_format='application/json')
return_statement: return default_format
docstring: This overrides the default tastyie determine_format.
      This is done because we want to default to "application/json"
      even though most browsers will send along "application/xml" in the
      Accept header if no "format" is provided.
  
      :param request: Django request object (Required)
      :type request: :class:`django.http.HttpRequest`
      :param serializer: The serializer being used.
      :type serializer: :class:`crits.core.api.CRITsSerializer`
      :param default_format: The format to respond in.
      :type default_format: str
      :returns: str
docstring_summary: This overrides the default tastyie determine_format.
      This is done because we want to default to "application/json"
      even though most browsers will send along "application/xml" in the
      Accept header if no "format" is provided.
docstring_tokens: This overrides the default tastyie determine_format . This is done because we want to default to application / json even though most browsers will send along application / xml in the Accept header if no format is provided .
function: def determine_format(request, serializer, default_format='application/json'):
      """
      This overrides the default tastyie determine_format.
      This is done because we want to default to "application/json"
      even though most browsers will send along "application/xml" in the
      Accept header if no "format" is provided.
  
      :param request: Django request object (Required)
      :type request: :class:`django.http.HttpRequest`
      :param serializer: The serializer being used.
      :type serializer: :class:`crits.core.api.CRITsSerializer`
      :param default_format: The format to respond in.
      :type default_format: str
      :returns: str
      """
  
      # First, check if they forced the format.
      if request.GET.get('format'):
          if request.GET['format'] in serializer.formats:
              return serializer.get_mime_for_format(request.GET['format'])
  
      if request.GET.get('file'):
          default_format = 'application/octet-stream'
  
      # No valid 'Accept' header/formats. Sane default.
      return default_format
function_tokens: def determine_format ( request , serializer , default_format = 'application/json' ) : # First, check if they forced the format. if request . GET . get ( 'format' ) : if request . GET [ 'format' ] in serializer . formats : return serializer . get_mime_for_format ( request . GET [ 'format' ] ) if request . GET . get ( 'file' ) : default_format = 'application/octet-stream' # No valid 'Accept' header/formats. Sane default. return default_format