ICU backend; uses Pyrex, based on zope.ucol.
[python-collate.git] / collate / icu / __init__.py
1 import collate.icu._ucol
2 import collate._abcollator
3
4 class Collator(collate._abcollator.Collator):
5 def __init__(self, locale):
6 self._collator = collate.icu._ucol.Collator(locale)
7
8 def key(self, string):
9 return self._collator.key(string)
10
11 def cmp(self, string1, string2):
12 return self._collator.cmp(string1, string2)