Home | Trees | Indices | Help |
|
---|
|
This file is part of the web2py Web Framework Copyrighted by Massimo Di Pierro <mdipierro@cs.depaul.edu> License: LGPLv3 (http://www.gnu.org/licenses/lgpl.html) Created by Vladyslav Kozlovskyy (Ukraine) <dbdevelop©gmail.com> for Web2py project Utilities and class for UTF8 strings managing ===========================================
|
|||
Utf8 Class for utf8 string storing and manipulations |
|
|||
|
|||
|
|||
|
|||
|
|||
|
|
|||
repr_escape_tab =
|
|||
repr_escape_tab2 =
|
|||
__package__ =
|
|||
i = 31
|
|
Unicode Collation Algorithm (UCA) (http://www.unicode.org/reports/tr10/) is used for utf-8 and unicode strings sorting and for utf-8 strings comparison NOTE: pyuca is a very memory cost module! It loads the whole "allkey.txt" file (~2mb!) into the memory. But this functionality is needed only when sort_key() is called as a part of sort() function or when Utf8 strings are compared. So, it is a lazy "sort_key" function which (ONLY ONCE, ON ITS FIRST CALL) imports pyuca and replaces itself with a real sort_key() function |
returns unicode id for utf8 or unicode *char* character SUPPOSE that *char* is an utf-8 or unicode character only |
return length of utf-8 string in bytes NOTE! The length of correspondent utf-8 string is returned for unicode string |
returns string of length < *length* or truncate string with adding *dots* suffix to the string's end args: length (int): max length of string dots (str or unicode): string suffix, when string is cutted returns: (utf8-str): original or cutted string |
|
repr_escape_tab
|
repr_escape_tab2
|
Home | Trees | Indices | Help |
|
---|
Generated by Epydoc 3.0.1 on Sun Mar 16 02:36:11 2014 | http://epydoc.sourceforge.net |