pytilities.mangle'

Package pytilities :: Module mangle' |
[hide private]
[frames] | no frames]

# Module mangle'

source code

Functions | [hide private]
mangle(obj, attribute) Get the mangled name of an attribute | source code

Variables | [hide private]
| __package__ = `None`

Function Details | [hide private]

### mangle(obj, attribute) | source code
    Get the mangled name of an attribute

    Overloaded parameters:

    :a:

        `instance`
            the instance to which the attribute belongs to. It's class name
            will be used for mangling.

        `attribute` :: string
            the attribute name to mangle

    :b:
        `cls_name` :: string
            the name of the class to which the attribute belongs

    Returns mangled attribute, if it starts with '__' and doesn't end with
    '__'. Otherwise, `attribute` is returned :: string