Trees | Indices | Help |
|
---|
|
Convert a text string into a Date object. If the date cannot be converted, the text string is assigned.
Instance Methods | |||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
Class Variables | |
month_to_int =
|
|
modifier_to_int =
|
|
modifier_after_to_int =
|
|
hebrew_to_int =
|
|
french_to_int =
|
|
islamic_to_int =
|
|
persian_to_int =
|
|
bce =
|
|
calendar_to_int =
|
|
quality_to_int =
|
Method Details |
returns a string for a RE group which contains the given keys sorted so that longest keys match first. Any '.' characters are quoted. |
This method compiles regular expression strings for matching dates. Most of the re's in most languages can stay as is. span and range most likely will need to change. Whatever change is done, this method may be called first as DateParser.init_strings(self) so that the invariant expresions don't need to be repeteadly coded. All differences can be coded after DateParser.init_strings(self) call, that way they override stuff from this method. See DateParserRU() as an example. |
Try parsing calendar. Return calendar index and the text with calendar removed. |
Try matching quality. Return quality index and the text with quality removed. |
Try matching span date. On success, set the date and return 1. On failure return 0. |
Try matching range date. On success, set the date and return 1. On failure return 0. |
Try matching BCE qualifier. Return BCE (True/False) and the text with matched part removed. |
Try matching date with modifier. On success, set the date and return 1. On failure return 0. |
Class Variable Details |
month_to_int
|
modifier_to_int
|
hebrew_to_int
|
french_to_int
|
islamic_to_int
|
persian_to_int
|
calendar_to_int
|
quality_to_int
|
Trees | Indices | Help |
|
---|
Generated by Epydoc 3.0.1 on Sun Mar 9 21:52:16 2008 | http://epydoc.sourceforge.net |