Wrapper class providing the various date and number formatting functions
bound to a specific locale and time-zone.
|
__init__(self,
locale,
tzinfo={ ' territory_zones ' : { ' 001 ' : [ ' Etc/GMT ' , ' Etc/GMT-1 ' , ' Etc/GMT- ... )
Initialize the formatter. |
|
|
|
date(self,
date={ ' territory_zones ' : { ' 001 ' : [ ' Etc/GMT ' , ' Etc/GMT-1 ' , ' Etc/GMT- ... ,
format=' medium ' )
Return a date formatted according to the given pattern. |
|
|
|
datetime(self,
datetime={ ' territory_zones ' : { ' 001 ' : [ ' Etc/GMT ' , ' Etc/GMT-1 ' , ' Etc/GMT- ... ,
format=' medium ' )
Return a date and time formatted according to the given pattern. |
|
|
|
time(self,
time={ ' territory_zones ' : { ' 001 ' : [ ' Etc/GMT ' , ' Etc/GMT-1 ' , ' Etc/GMT- ... ,
format=' medium ' )
Return a time formatted according to the given pattern. |
|
|
|
number(self,
number)
Return an integer number formatted for the locale. |
|
|
|
decimal(self,
number,
format={ ' territory_zones ' : { ' 001 ' : [ ' Etc/GMT ' , ' Etc/GMT-1 ' , ' Etc/GMT- ... )
Return a decimal number formatted for the locale. |
|
|
|
currency(self,
number,
currency)
Return a number in the given currency formatted for the locale. |
|
|
|
percent(self,
number,
format={ ' territory_zones ' : { ' 001 ' : [ ' Etc/GMT ' , ' Etc/GMT-1 ' , ' Etc/GMT- ... )
Return a number formatted as percentage for the locale. |
|
|
|
scientific(self,
number)
Return a number formatted using scientific notation for the locale. |
|
|
Inherited from object :
__delattr__ ,
__getattribute__ ,
__hash__ ,
__new__ ,
__reduce__ ,
__reduce_ex__ ,
__repr__ ,
__setattr__ ,
__str__
|