Module Expr Str ImportFrom alias alias alias Import alias ImportFrom alias ImportFrom alias alias alias alias ImportFrom alias alias alias alias alias alias ImportFrom alias alias Assign NameStore ListLoad Str Str Str Assign NameStore Str ClassDef bases NameLoad body Expr Str FunctionDef arguments args NameParam NameParam NameParam defaults NameLoad body Expr Str Assign AttributeStore NameLoad attr Call AttributeLoad NameLoad attr NameLoad Assign AttributeStore NameLoad attr NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam defaults NameLoad Str body Expr Str Return Call NameLoad NameLoad NameLoad keyword AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam NameParam NameParam defaults NameLoad Str body Expr Str Return Call NameLoad NameLoad NameLoad keyword AttributeLoad NameLoad attr keyword AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam NameParam NameParam defaults NameLoad Str body Expr Str Return Call NameLoad NameLoad NameLoad keyword AttributeLoad NameLoad attr keyword AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam NameParam defaults body Expr Str Return Call NameLoad NameLoad keyword AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam NameParam NameParam defaults NameLoad body Expr Str Return Call NameLoad NameLoad NameLoad keyword AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam NameParam NameParam defaults body Expr Str Return Call NameLoad NameLoad NameLoad keyword AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam NameParam NameParam defaults NameLoad body Expr Str Return Call NameLoad NameLoad NameLoad keyword AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam NameParam defaults body Expr Str Return Call NameLoad NameLoad keyword AttributeLoad NameLoad attr decorator_list decorator_list ClassDef bases NameLoad body Expr Str Assign NameStore ListLoad Str Str Str Str FunctionDef arguments args NameParam NameParam defaults vararg kwarg body Expr Call AttributeLoad NameLoad attr NameLoad Str NameLoad Expr Call AttributeLoad NameLoad attr NameLoad Str NameLoad Expr Call AttributeLoad NameLoad attr NameLoad Str NameLoad Expr Call AttributeLoad NameLoad attr NameLoad Str NameLoad decorator_list FunctionDef arguments args NameParam defaults body If CompareIs AttributeLoad NameLoad attr NameLoad body Assign NameStore Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr NameLoad Str NameLoad Return AttributeLoad NameLoad attr decorator_list Assign NameStore Call NameLoad NameLoad FunctionDef arguments args NameParam NameParam defaults body Return CompareIn NameLoad AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam defaults body Return Call NameLoad AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam defaults body Return Call NameLoad AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam defaults body Return Call NameLoad AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam defaults body Return Call NameLoad AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam defaults body Return Call NameLoad AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam defaults body Return Call NameLoad AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam NameParam defaults body Return BinOpAdd AttributeLoad NameLoad attr NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults body Return BinOpAdd NameLoad AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam NameParam defaults body Return BinOpMod AttributeLoad NameLoad attr NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults body Return BinOpMod NameLoad AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam NameParam defaults body Return BinOpMult AttributeLoad NameLoad attr NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults body Return BinOpMult NameLoad AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam defaults vararg kwarg body Return Call AttributeLoad NameLoad attr NameLoad NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults body Return CompareLt AttributeLoad NameLoad attr NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults body Return CompareLtE AttributeLoad NameLoad attr NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults body Return CompareEq AttributeLoad NameLoad attr NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults body Return CompareNotEq AttributeLoad NameLoad attr NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults body Return CompareGt AttributeLoad NameLoad attr NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults body Return CompareGtE AttributeLoad NameLoad attr NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults body Expr Call NameLoad AttributeLoad NameLoad attr NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults body Return Call NameLoad AttributeLoad NameLoad attr NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam defaults body Expr Call NameLoad AttributeLoad NameLoad attr NameLoad NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults body Delete SubscriptDel AttributeLoad NameLoad attr Index NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults body Return SubscriptLoad AttributeLoad NameLoad attr Index NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam defaults body Assign SubscriptStore AttributeLoad NameLoad attr Index NameLoad NameLoad decorator_list decorator_list ClassDef bases AttributeLoad NameLoad attr NameLoad body Expr Str Assign NameStore Str FunctionDef arguments args NameParam NameParam NameParam defaults NameLoad NameLoad body Expr Str Expr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad keyword NameLoad Assign AttributeStore NameLoad attr Call NameLoad NameLoad ListLoad Call NameLoad NameLoad Str NameLoad Assign AttributeStore NameLoad attr NameLoad Assign AttributeStore NameLoad attr Dict decorator_list FunctionDef arguments args NameParam NameParam NameParam NameParam defaults NameLoad NameLoad NameLoad body Expr Str If CompareIsNot NameLoad NameLoad body If UnaryOpNot Call NameLoad NameLoad TupleLoad NameLoad NameLoad body Assign NameStore ListLoad NameLoad Assign NameStore ListComp Call NameLoad NameLoad comprehension NameStore NameLoad If UnaryOpNot NameLoad body Assign NameStore AttributeLoad NameLoad attr Assign NameStore Call AttributeLoad NameLoad attr NameLoad NameLoad NameLoad If UnaryOpNot NameLoad body Return Call AttributeLoad NameLoad attr Return Call NameLoad keyword Call NameLoad NameLoad Str keyword NameLoad decorator_list Assign NameStore Call NameLoad NameLoad FunctionDef arguments args NameParam defaults body Return BinOpMod Str TupleLoad AttributeLoad Call NameLoad NameLoad attr Call AttributeLoad AttributeLoad NameLoad attr attr Str decorator_list FunctionDef arguments args NameParam NameParam NameParam defaults NameLoad body Expr Str Assign NameStore Call NameLoad NameLoad Str AttributeLoad NameLoad attr If BoolOpAnd NameLoad CompareEq NameLoad AttributeLoad NameLoad attr body Return Call AttributeLoad NameLoad attr NameLoad Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad If BoolOpAnd NameLoad CompareIsNot NameLoad NameLoad body Expr Call AttributeLoad NameLoad attr NameLoad orelse Expr Call AttributeLoad NameLoad attr NameLoad Assign SubscriptStore AttributeLoad NameLoad attr Index NameLoad NameLoad Return NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults body Expr Str If Call NameLoad NameLoad AttributeLoad NameLoad attr body Expr Call AttributeLoad AttributeLoad NameLoad attr attr AttributeLoad NameLoad attr If Call NameLoad NameLoad NameLoad body Expr Call AttributeLoad AttributeLoad NameLoad attr attr AttributeLoad NameLoad attr Return NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam defaults body Expr Str Return Call AttributeLoad Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad NameLoad attr NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam defaults body Expr Str Return Call AttributeLoad Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad NameLoad attr NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam defaults body Expr Str Return Call AttributeLoad Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad NameLoad attr NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam NameParam NameParam defaults body Expr Str Return Call AttributeLoad Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad NameLoad attr NameLoad NameLoad NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam NameParam NameParam defaults body Expr Str Return Call AttributeLoad Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad NameLoad attr NameLoad NameLoad NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam NameParam NameParam defaults body Expr Str Return Call AttributeLoad Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad NameLoad attr NameLoad NameLoad NameLoad decorator_list decorator_list
N/A N/A Several classes and functions that help with integrating and using Babel
in applications.

.. note: the code in this module is not used by Babel itself
 datetime date datetime time N/A gettext babel.core Locale babel.dates format_date format_datetime format_time LC_TIME babel.numbers format_number format_decimal format_currency format_percent format_scientific LC_NUMERIC babel.util set UTC N/A __all__ N/A Format LazyProxy Translations N/A __docformat__ restructuredtext en Format N/A object N/A N/A Wrapper class providing the various date and number formatting functions
    bound to a specific locale and time-zone.
    
    >>> fmt = Format('en_US', UTC)
    >>> fmt.date(date(2007, 4, 1))
    u'Apr 1, 2007'
    >>> fmt.decimal(1.2345)
    u'1.234'
     __init__ N/A N/A self locale tzinfo N/A None N/A N/A Initialize the formatter.
        
        :param locale: the locale identifier or `Locale` instance
        :param tzinfo: the time-zone info (a `tzinfo` instance or `None`)
         N/A N/A self locale N/A N/A Locale parse locale N/A N/A self tzinfo tzinfo N/A date N/A N/A self date format N/A None medium N/A N/A Return a date formatted according to the given pattern.
        
        >>> fmt = Format('en_US')
        >>> fmt.date(date(2007, 4, 1))
        u'Apr 1, 2007'
        
        :see: `babel.dates.format_date`
         N/A N/A format_date date format locale N/A self locale N/A datetime N/A N/A self datetime format N/A None medium N/A N/A Return a date and time formatted according to the given pattern.
        
        >>> from pytz import timezone
        >>> fmt = Format('en_US', tzinfo=timezone('US/Eastern'))
        >>> fmt.datetime(datetime(2007, 4, 1, 15, 30))
        u'Apr 1, 2007 11:30:00 AM'
        
        :see: `babel.dates.format_datetime`
         N/A N/A format_datetime datetime format tzinfo N/A self tzinfo locale N/A self locale N/A time N/A N/A self time format N/A None medium N/A N/A Return a time formatted according to the given pattern.
        
        >>> from pytz import timezone
        >>> fmt = Format('en_US', tzinfo=timezone('US/Eastern'))
        >>> fmt.time(datetime(2007, 4, 1, 15, 30))
        u'11:30:00 AM'
        
        :see: `babel.dates.format_time`
         N/A N/A format_time time format tzinfo N/A self tzinfo locale N/A self locale N/A number N/A N/A self number N/A N/A N/A Return an integer number formatted for the locale.
        
        >>> fmt = Format('en_US')
        >>> fmt.number(1099)
        u'1,099'
        
        :see: `babel.numbers.format_number`
         N/A N/A format_number number locale N/A self locale N/A decimal N/A N/A self number format N/A None N/A N/A Return a decimal number formatted for the locale.
        
        >>> fmt = Format('en_US')
        >>> fmt.decimal(1.2345)
        u'1.234'
        
        :see: `babel.numbers.format_decimal`
         N/A N/A format_decimal number format locale N/A self locale N/A currency N/A N/A self number currency N/A N/A N/A Return a number in the given currency formatted for the locale.
        
        :see: `babel.numbers.format_currency`
         N/A N/A format_currency number currency locale N/A self locale N/A percent N/A N/A self number format N/A None N/A N/A Return a number formatted as percentage for the locale.
        
        >>> fmt = Format('en_US')
        >>> fmt.percent(0.34)
        u'34%'
        
        :see: `babel.numbers.format_percent`
         N/A N/A format_percent number format locale N/A self locale N/A scientific N/A N/A self number N/A N/A N/A Return a number formatted using scientific notation for the locale.
        
        :see: `babel.numbers.format_scientific`
         N/A N/A format_scientific number locale N/A self locale N/A N/A LazyProxy N/A object N/A N/A Class for proxy objects that delegate to a specified function to evaluate
    the actual object.
    
    >>> def greeting(name='world'):
    ...     return 'Hello, %s!' % name
    >>> lazy_greeting = LazyProxy(greeting, name='Joe')
    >>> print lazy_greeting
    Hello, Joe!
    >>> u'  ' + lazy_greeting
    u'  Hello, Joe!'
    >>> u'(%s)' % lazy_greeting
    u'(Hello, Joe!)'
    
    This can be used, for example, to implement lazy translation functions that
    delay the actual translation until the string is actually used. The
    rationale for such behavior is that the locale of the user may not always
    be available. In web applications, you only know the locale when processing
    a request.
    
    The proxy implementation attempts to be as complete as possible, so that
    the lazy objects should mostly work as expected, for example for sorting:
    
    >>> greetings = [
    ...     LazyProxy(greeting, 'world'),
    ...     LazyProxy(greeting, 'Joe'),
    ...     LazyProxy(greeting, 'universe'),
    ... ]
    >>> greetings.sort()
    >>> for greeting in greetings:
    ...     print greeting
    Hello, Joe!
    Hello, universe!
    Hello, world!
     N/A __slots__ N/A _func _args _kwargs _value __init__ N/A N/A self func N/A args kwargs N/A N/A N/A N/A object __setattr__ self _func func N/A N/A N/A object __setattr__ self _args args N/A N/A N/A object __setattr__ self _kwargs kwargs N/A N/A N/A object __setattr__ self _value None N/A value N/A N/A self N/A N/A N/A N/A N/A self _value None N/A N/A value N/A N/A self _func N/A self _args N/A self _kwargs N/A N/A N/A object __setattr__ self _value value N/A N/A self _value N/A N/A value N/A property value __contains__ N/A N/A self key N/A N/A N/A N/A key N/A self value N/A __nonzero__ N/A N/A self N/A N/A N/A N/A bool N/A self value N/A __dir__ N/A N/A self N/A N/A N/A N/A dir N/A self value N/A __iter__ N/A N/A self N/A N/A N/A N/A iter N/A self value N/A __len__ N/A N/A self N/A N/A N/A N/A len N/A self value N/A __str__ N/A N/A self N/A N/A N/A N/A str N/A self value N/A __unicode__ N/A N/A self N/A N/A N/A N/A unicode N/A self value N/A __add__ N/A N/A self other N/A N/A N/A N/A N/A self value other N/A __radd__ N/A N/A self other N/A N/A N/A N/A other N/A self value N/A __mod__ N/A N/A self other N/A N/A N/A N/A N/A self value other N/A __rmod__ N/A N/A self other N/A N/A N/A N/A other N/A self value N/A __mul__ N/A N/A self other N/A N/A N/A N/A N/A self value other N/A __rmul__ N/A N/A self other N/A N/A N/A N/A other N/A self value N/A __call__ N/A N/A self N/A args kwargs N/A N/A N/A N/A self value args kwargs N/A __lt__ N/A N/A self other N/A N/A N/A N/A N/A self value other N/A __le__ N/A N/A self other N/A N/A N/A N/A N/A self value other N/A __eq__ N/A N/A self other N/A N/A N/A N/A N/A self value other N/A __ne__ N/A N/A self other N/A N/A N/A N/A N/A self value other N/A __gt__ N/A N/A self other N/A N/A N/A N/A N/A self value other N/A __ge__ N/A N/A self other N/A N/A N/A N/A N/A self value other N/A __delattr__ N/A N/A self name N/A N/A N/A N/A delattr N/A self value name N/A __getattr__ N/A N/A self name N/A N/A N/A N/A getattr N/A self value name N/A __setattr__ N/A N/A self name value N/A N/A N/A N/A setattr N/A self value name value N/A __delitem__ N/A N/A self key N/A N/A N/A N/A N/A self value N/A key N/A __getitem__ N/A N/A self key N/A N/A N/A N/A N/A self value N/A key N/A __setitem__ N/A N/A self key value N/A N/A N/A N/A N/A self value N/A key value N/A N/A Translations N/A N/A gettext GNUTranslations object N/A N/A An extended translation catalog class. N/A DEFAULT_DOMAIN messages __init__ N/A N/A self fileobj domain N/A None DEFAULT_DOMAIN N/A N/A Initialize the translations catalog.

        :param fileobj: the file-like object the translation should be read
                        from
         N/A N/A N/A N/A gettext GNUTranslations __init__ self fp fileobj N/A N/A self files N/A filter None N/A N/A getattr fileobj name None N/A N/A self domain domain N/A N/A self _domains N/A N/A load N/A N/A cls dirname locales domain N/A None None DEFAULT_DOMAIN N/A N/A Load translations from the given directory.

        :param dirname: the directory containing the ``MO`` files
        :param locales: the list of locales in order of preference (items in
                        this list can be either `Locale` objects or locale
                        strings)
        :param domain: the message domain
        :return: the loaded catalog, or a ``NullTranslations`` instance if no
                 matching translations were found
        :rtype: `Translations`
         N/A N/A locales None N/A N/A N/A N/A isinstance locales N/A list tuple N/A N/A locales N/A locales N/A locales N/A N/A str locale N/A locale locales N/A N/A domain N/A N/A domain N/A cls DEFAULT_DOMAIN N/A filename N/A N/A gettext find domain dirname locales N/A N/A filename N/A N/A N/A N/A gettext NullTranslations N/A N/A cls fileobj N/A open filename rb domain domain N/A N/A load N/A classmethod load __repr__ N/A N/A self N/A N/A N/A N/A <%s: "%s"> N/A N/A N/A type self __name__ N/A N/A N/A self _info get project-id-version N/A add N/A N/A self translations merge N/A True N/A N/A Add the given translations to the catalog.

        If the domain of the translations is different than that of the
        current catalog, they are added as a catalog that is only accessible
        by the various ``d*gettext`` functions.

        :param translations: the `Translations` instance with the messages to
                             add
        :param merge: whether translations for message domains that have
                      already been added should be merged with the existing
                      translations
        :return: the `Translations` instance (``self``) so that `merge` calls
                 can be easily chained
        :rtype: `Translations`
         N/A domain N/A getattr translations domain N/A self DEFAULT_DOMAIN N/A N/A merge N/A domain N/A self domain N/A N/A N/A N/A self merge translations N/A existing N/A N/A N/A self _domains get domain N/A N/A merge N/A existing None N/A N/A N/A N/A existing merge translations N/A N/A N/A N/A translations add_fallback self N/A N/A N/A self _domains N/A domain translations N/A self N/A merge N/A N/A self translations N/A N/A N/A Merge the given translations into the catalog.

        Message translations in the specified catalog override any messages
        with the same identifier in the existing catalog.

        :param translations: the `Translations` instance with the messages to
                             merge
        :return: the `Translations` instance (``self``) so that `merge` calls
                 can be easily chained
        :rtype: `Translations`
         N/A N/A isinstance translations N/A gettext GNUTranslations N/A N/A N/A N/A N/A self _catalog update N/A translations _catalog N/A N/A isinstance translations Translations N/A N/A N/A N/A N/A self files extend N/A translations files N/A self N/A dgettext N/A N/A self domain message N/A N/A N/A Like ``gettext()``, but look the message up in the specified
        domain.
         N/A N/A N/A N/A N/A N/A self _domains get domain self gettext message N/A ldgettext N/A N/A self domain message N/A N/A N/A Like ``lgettext()``, but look the message up in the specified 
        domain.
         N/A N/A N/A N/A N/A N/A self _domains get domain self lgettext message N/A dugettext N/A N/A self domain message N/A N/A N/A Like ``ugettext()``, but look the message up in the specified
        domain.
         N/A N/A N/A N/A N/A N/A self _domains get domain self ugettext message N/A dngettext N/A N/A self domain singular plural num N/A N/A N/A Like ``ngettext()``, but look the message up in the specified
        domain.
         N/A N/A N/A N/A N/A N/A self _domains get domain self ngettext singular plural num N/A ldngettext N/A N/A self domain singular plural num N/A N/A N/A Like ``lngettext()``, but look the message up in the specified
        domain.
         N/A N/A N/A N/A N/A N/A self _domains get domain self lngettext singular plural num N/A dungettext N/A N/A self domain singular plural num N/A N/A N/A Like ``ungettext()`` but look the message up in the specified
        domain.
         N/A N/A N/A N/A N/A N/A self _domains get domain self ungettext singular plural num N/A N/A