def __init__(self, name=None, callback_dispatcher=None):
super(Library, self).__init__()<EOL>if not Library._lib:<EOL><INDENT>assert Library._refcount == <NUM_LIT:0><EOL>if name is None:<EOL><INDENT>name = LIBRARY_NAME<EOL><DEDENT>lib = DllLoader.LoadLibrary(name)<EOL>self._setup_functions(lib)<EOL>lib.tdInit()<EOL>Library._lib = lib<EOL><DEDENT>Library._refcount += <NUM_LIT:1><EOL>if callback_dispatcher is not None:<EOL><INDENT>self._callback_wrapper = Library.CallbackWrapper(<EOL>callback_dispatcher)<EOL><DEDENT>else:<EOL><INDENT>self._callback_wrapper = None<EOL><DEDENT>
Load and initialize the Telldus core library.

        The underlaying library is only initialized the first time this object
        is created. Subsequent instances uses the same underlaying library
        instance.

        :param str name: If None than the platform specific name of the
            Telldus library is used, but it can be e.g. an absolute path.

        :param callback_dispatcher: If callbacks are to be used, this parameter
            must refer to an instance of a class inheriting from
            :class:`BaseCallbackDispatcher`.