| Home | Trees | Indices | Help |
|
|---|
|
|
1 # Copyright (c) The PyAMF Project.
2 # See LICENSE.txt for details.
3
4 """
5 C{django.utils.translation} adapter module.
6
7 @see: U{Django Project<http://www.djangoproject.com>}
8 @since: 0.4.2
9 """
10
11 from django.utils.translation import ugettext_lazy
12
13 import pyamf
14
15
17 if l.__class__._delegate_unicode:
18 return unicode(l)
19
20 if l.__class__._delegate_str:
21 return str(l)
22
23 raise ValueError('Don\'t know how to convert lazy value %s' % (repr(l),))
24
25
26 pyamf.add_type(type(ugettext_lazy('foo')), convert_lazy)
27
| Home | Trees | Indices | Help |
|
|---|
| Generated by Epydoc 3.0.1 on Mon Jul 18 11:44:04 2011 | http://epydoc.sourceforge.net |