multi_tools/cpp/class_extension.py
def HeaderFunc(func):
    """
    If the owner class is decorated with @HeaderClass , decorated function will be replaced by
    the corresponding function of the dll that was specified to the class
    decorator. If the owner class is not correctly decorated, TypeError is raised.

    -> return type: '_ctypes.FuncPtr'

    -> possible raised errors: ReferenceError, TypeError

    The right dll function is chosen depending on the header
    function's name. Please note that static methods are not compatible with this system.
    If you plan to use static methods coming from .dlls, consider
    using the @system.DllImport decorator instead.

    - If the function is a classic function, the decorator will look in the dll
        for a function named after "Py_<name>", where 'name' is the name of the
        header function; and replace it.

    - If the function is a special function like __init__ or __bool__, on the other
        hand, the decorator would look for a function named "PySpecial_<name>" with
        'name' being the header function's name without the '_' characters.

    For example, if you were to make a header function called "foo", a function
    called "Py_foo" would be searched inside the .dll library.

    If you were to make your "__init__" function a header, a function called
    "PySpecial_init" would be searched inside the .dll library.

    If the function happens to not be exported by the .dll, python wouldn't find it
    and a ReferenceError will be raised.


    Note:

    When the decorator replaces the header function, it keeps it's name, dotted name,
    documentation, annotations (signature), and parent module reference, and copies
    them into the new function object that comes from the dll.

    For this reason, you should make sure to have the function's accurate signature
    given to the header function, otherwise, at runtime, it won't be stored anywhere.


    Other note:

    Multiple classes can inheritate from the same .dll library.
    """
    _h = _Header(func)
    return _h.func

    If the owner class is decorated with @HeaderClass , decorated function will be replaced by
    the corresponding function of the dll that was specified to the class
    decorator. If the owner class is not correctly decorated, TypeError is raised.

    -> return type: '_ctypes.FuncPtr'

    -> possible raised errors: ReferenceError, TypeError

    The right dll function is chosen depending on the header
    function's name. Please note that static methods are not compatible with this system.
    If you plan to use static methods coming from .dlls, consider
    using the @system.DllImport decorator instead.

    - If the function is a classic function, the decorator will look in the dll
        for a function named after "Py_<name>", where 'name' is the name of the
        header function; and replace it.

    - If the function is a special function like __init__ or __bool__, on the other
        hand, the decorator would look for a function named "PySpecial_<name>" with
        'name' being the header function's name without the '_' characters.

    For example, if you were to make a header function called "foo", a function
    called "Py_foo" would be searched inside the .dll library.

    If you were to make your "__init__" function a header, a function called
    "PySpecial_init" would be searched inside the .dll library.

    If the function happens to not be exported by the .dll, python wouldn't find it
    and a ReferenceError will be raised.


    Note:

    When the decorator replaces the header function, it keeps it's name, dotted name,
    documentation, annotations (signature), and parent module reference, and copies
    them into the new function object that comes from the dll.

    For this reason, you should make sure to have the function's accurate signature
    given to the header function, otherwise, at runtime, it won't be stored anywhere.


    Other note:

    Multiple classes can inheritate from the same .dll library.
    
If the owner class is decorated with @HeaderClass , decorated function will be replaced by
the corresponding function of the dll that was specified to the class
decorator. If the owner class is not correctly decorated, TypeError is raised.





The right dll function is chosen depending on the header
function's name. Please note that static methods are not compatible with this system.
If you plan to use static methods coming from .dlls, consider
using the @system.DllImport decorator instead.

If the function is a classic function, the decorator will look in the dll
for a function named after "Py_", where 'name' is the name of the
header function; and replace it.



For example, if you were to make a header function called "foo", a function
called "Py_foo" would be searched inside the .dll library.

If you were to make your "__init__" function a header, a function called
"PySpecial_init" would be searched inside the .dll library.

If the function happens to not be exported by the .dll, python wouldn't find it
and a ReferenceError will be raised.



When the decorator replaces the header function, it keeps it's name, dotted name,
documentation, annotations (signature), and parent module reference, and copies
them into the new function object that comes from the dll.

For this reason, you should make sure to have the function's accurate signature
given to the header function, otherwise, at runtime, it won't be stored anywhere.

Other note.

Multiple classes can inheritate from the same .dll library.
If the owner class is decorated with @HeaderClass decorated function will be replaced by the corresponding function of the dll that was specified to the class decorator . If the owner class is not correctly decorated TypeError is raised . The right dll function is chosen depending on the header function ' s name . Please note that static methods are not compatible with this system . If you plan to use static methods coming from . dlls consider using the @system . DllImport decorator instead . If the function is a classic function the decorator will look in the dll for a function named after " Py_ " where ' name ' is the name of the header function ; and replace it . For example if you were to make a header function called " foo " a function called " Py_foo " would be searched inside the . dll library . If you were to make your " __init__ " function a header a function called " PySpecial_init " would be searched inside the . dll library . If the function happens to not be exported by the . dll python wouldn ' t find it and a ReferenceError will be raised . When the decorator replaces the header function it keeps it ' s name dotted name documentation annotations ( signature ) and parent module reference and copies them into the new function object that comes from the dll . For this reason you should make sure to have the function ' s accurate signature given to the header function otherwise at runtime it won ' t be stored anywhere . Other note . Multiple classes can inheritate from the same . dll library .
def HeaderFunc(func):
    _h = _Header(func)
    return _h.func
def HeaderFunc ( func ) : _h = _Header ( func ) return _h . func
If the owner class is decorated with @HeaderClass , decorated function will be replaced by
the corresponding function of the dll that was specified to the class
decorator.
If the owner class is decorated with @HeaderClass decorated function will be replaced by the corresponding function of the dll that was specified to the class decorator .
"""
    If the owner class is decorated with @HeaderClass , decorated function will be replaced by
    the corresponding function of the dll that was specified to the class
    decorator. If the owner class is not correctly decorated, TypeError is raised.

    -> return type: '_ctypes.FuncPtr'

    -> possible raised errors: ReferenceError, TypeError

    The right dll function is chosen depending on the header
    function's name. Please note that static methods are not compatible with this system.
    If you plan to use static methods coming from .dlls, consider
    using the @system.DllImport decorator instead.

    - If the function is a classic function, the decorator will look in the dll
        for a function named after "Py_<name>", where 'name' is the name of the
        header function; and replace it.

    - If the function is a special function like __init__ or __bool__, on the other
        hand, the decorator would look for a function named "PySpecial_<name>" with
        'name' being the header function's name without the '_' characters.

    For example, if you were to make a header function called "foo", a function
    called "Py_foo" would be searched inside the .dll library.

    If you were to make your "__init__" function a header, a function called
    "PySpecial_init" would be searched inside the .dll library.

    If the function happens to not be exported by the .dll, python wouldn't find it
    and a ReferenceError will be raised.


    Note:

    When the decorator replaces the header function, it keeps it's name, dotted name,
    documentation, annotations (signature), and parent module reference, and copies
    them into the new function object that comes from the dll.

    For this reason, you should make sure to have the function's accurate signature
    given to the header function, otherwise, at runtime, it won't be stored anywhere.


    Other note:

    Multiple classes can inheritate from the same .dll library.
    """
func