diff options
| author | Tom Christie | 2011-05-24 13:29:30 +0100 |
|---|---|---|
| committer | Tom Christie | 2011-05-24 13:29:30 +0100 |
| commit | ce6e5fdc01b6d820f317bc1d8edc4ede4a946516 (patch) | |
| tree | 9d3b9dbd2f263ba1d5f99cd3fdce40ae9f54f511 /djangorestframework/utils/__init__.py | |
| parent | eafda8550800a98aa37571df0cef78e32521a89b (diff) | |
| download | django-rest-framework-ce6e5fdc01b6d820f317bc1d8edc4ede4a946516.tar.bz2 | |
Renderers can now cope with parameterised args. ResponseMixin gets cleaned up & added Renderer.can_handle_response(), mirroring Parsers.can_handle_request()
Diffstat (limited to 'djangorestframework/utils/__init__.py')
| -rw-r--r-- | djangorestframework/utils/__init__.py | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/djangorestframework/utils/__init__.py b/djangorestframework/utils/__init__.py index 67870001..99f9724c 100644 --- a/djangorestframework/utils/__init__.py +++ b/djangorestframework/utils/__init__.py @@ -13,6 +13,9 @@ import xml.etree.ElementTree as ET # """Adds the ADMIN_MEDIA_PREFIX to the request context.""" # return {'ADMIN_MEDIA_PREFIX': settings.ADMIN_MEDIA_PREFIX} +from mediatypes import media_type_matches, is_form_media_type +from mediatypes import add_media_type_param, get_media_type_params, order_by_precedence + MSIE_USER_AGENT_REGEX = re.compile(r'^Mozilla/[0-9]+\.[0-9]+ \([^)]*; MSIE [0-9]+\.[0-9]+[a-z]?;[^)]*\)(?!.* Opera )') def as_tuple(obj): |
