pyxmpp.xmppstringprep

Package pyxmpp :: Module xmppstringprep |
[show private | hide private]
[frames | no frames]

## Module pyxmpp.xmppstringprep

Nodeprep and resourceprep stringprep profiles.

Normative reference:
  - RFC 3920

Classes
`LookupFunction` | Class for looking up RFC 3454 tables using function.
`LookupTable` | Class for looking up RFC 3454 tables using a dictionary and/or list of ranges.
`Profile` | Base class for stringprep profiles.

Exceptions
`StringprepError` | Exception raised when string preparation results in error.

Function Summary
| ``b1_mapping`(uc)` Do RFC 3454 B.1 table mapping.
| ``nfkc`(data)` Do NFKC normalization of Unicode data.
| ``set_stringprep_cache_size`(size)` Modify stringprep cache size.

Variable Summary
`str` | `__revision__` = `'$Id: xmppstringprep.py,v 1.16 2004/10/07...`
`LookupFunction` | `A_1` = `<pyxmpp.xmppstringprep.LookupFunction instance at ...`
`LookupFunction` | `B_1` = `<pyxmpp.xmppstringprep.LookupFunction instance at ...`
`LookupFunction` | `B_2` = `<pyxmpp.xmppstringprep.LookupFunction instance at ...`
`LookupFunction` | `B_3` = `<pyxmpp.xmppstringprep.LookupFunction instance at ...`
`LookupFunction` | `C_1_1` = `<pyxmpp.xmppstringprep.LookupFunction instance a...`
`LookupFunction` | `C_1_2` = `<pyxmpp.xmppstringprep.LookupFunction instance a...`
`LookupFunction` | `C_2_1` = `<pyxmpp.xmppstringprep.LookupFunction instance a...`
`LookupFunction` | `C_2_2` = `<pyxmpp.xmppstringprep.LookupFunction instance a...`
`LookupFunction` | `C_3` = `<pyxmpp.xmppstringprep.LookupFunction instance at ...`
`LookupFunction` | `C_4` = `<pyxmpp.xmppstringprep.LookupFunction instance at ...`
`LookupFunction` | `C_5` = `<pyxmpp.xmppstringprep.LookupFunction instance at ...`
`LookupFunction` | `C_6` = `<pyxmpp.xmppstringprep.LookupFunction instance at ...`
`LookupFunction` | `C_7` = `<pyxmpp.xmppstringprep.LookupFunction instance at ...`
`LookupFunction` | `C_8` = `<pyxmpp.xmppstringprep.LookupFunction instance at ...`
`LookupFunction` | `C_9` = `<pyxmpp.xmppstringprep.LookupFunction instance at ...`
`LookupFunction` | `D_1` = `<pyxmpp.xmppstringprep.LookupFunction instance at ...`
`LookupFunction` | `D_2` = `<pyxmpp.xmppstringprep.LookupFunction instance at ...`
`Profile` | `nodeprep` = `<pyxmpp.xmppstringprep.Profile instance at 0x...`
`Profile` | `resourceprep` = `<pyxmpp.xmppstringprep.Profile instance a...`
`int` | `stringprep_cache_size` = 1000

Imported modules:
  `stringprep`, `unicodedata`

Function Details

### b1_mapping(uc) Do RFC 3454 B.1 table mapping. Parameters: `uc` - Unicode character to map. Returns: u"" if there is `uc` code in the table, `None` otherwise.

### nfkc(data) Do NFKC normalization of Unicode data. Parameters: `data` - list of Unicode characters or Unicode string. Returns: normalized Unicode string.

### set_stringprep_cache_size(size) Modify stringprep cache size. Parameters: `size` - new cache size

Variable Details

    ### __revision__ Type: `str` Value:
        '$Id: xmppstringprep.py,v 1.16 2004/10/07 22:28:04 jajcus Exp $'

    ### A_1 Type: `LookupFunction` Value:
        <pyxmpp.xmppstringprep.LookupFunction instance at 0x407cb10c>

    ### B_1 Type: `LookupFunction` Value:
        <pyxmpp.xmppstringprep.LookupFunction instance at 0x407cb14c>

    ### B_2 Type: `LookupFunction` Value:
        <pyxmpp.xmppstringprep.LookupFunction instance at 0x407cb16c>

    ### B_3 Type: `LookupFunction` Value:
        <pyxmpp.xmppstringprep.LookupFunction instance at 0x407cb18c>

    ### C_1_1 Type: `LookupFunction` Value:
        <pyxmpp.xmppstringprep.LookupFunction instance at 0x407cb1ac>

    ### C_1_2 Type: `LookupFunction` Value:
        <pyxmpp.xmppstringprep.LookupFunction instance at 0x407cb1cc>

    ### C_2_1 Type: `LookupFunction` Value:
        <pyxmpp.xmppstringprep.LookupFunction instance at 0x407cb1ec>

    ### C_2_2 Type: `LookupFunction` Value:
        <pyxmpp.xmppstringprep.LookupFunction instance at 0x407cb20c>

    ### C_3 Type: `LookupFunction` Value:
        <pyxmpp.xmppstringprep.LookupFunction instance at 0x407cb22c>

    ### C_4 Type: `LookupFunction` Value:
        <pyxmpp.xmppstringprep.LookupFunction instance at 0x407cb24c>

    ### C_5 Type: `LookupFunction` Value:
        <pyxmpp.xmppstringprep.LookupFunction instance at 0x407cb26c>

    ### C_6 Type: `LookupFunction` Value:
        <pyxmpp.xmppstringprep.LookupFunction instance at 0x407cb28c>

    ### C_7 Type: `LookupFunction` Value:
        <pyxmpp.xmppstringprep.LookupFunction instance at 0x407cb2ac>

    ### C_8 Type: `LookupFunction` Value:
        <pyxmpp.xmppstringprep.LookupFunction instance at 0x407cb2cc>

    ### C_9 Type: `LookupFunction` Value:
        <pyxmpp.xmppstringprep.LookupFunction instance at 0x407cb2ec>

    ### D_1 Type: `LookupFunction` Value:
        <pyxmpp.xmppstringprep.LookupFunction instance at 0x407cb30c>

    ### D_2 Type: `LookupFunction` Value:
        <pyxmpp.xmppstringprep.LookupFunction instance at 0x407cb32c>

    ### nodeprep Type: `Profile` Value:
        <pyxmpp.xmppstringprep.Profile instance at 0x407cb3cc>

    ### resourceprep Type: `Profile` Value:
        <pyxmpp.xmppstringprep.Profile instance at 0x407cb42c>

    ### stringprep_cache_size Type: `int` Value:
        1000