ILibrary interface overview

File         : API\core\libs\ILibrary.h
Namespace    : core::libs
Included by  : zlibrary.h

Description

Interface that represents single add-on plugin module (Dynamically-Linked Library). This class has a default implementation which is wrapped into a set of macros declared in API\zlibrary.h file. You don't actually need to manually implement this interface in your plug-in, if you use set of macros properly. Consider an example in namepsace core::libs overview.

If you implement this interface manually, make sure to register it in repository in DWORD WINAPI DllMain(...) routine.

Interface methods

getDescription Provides short library description.
getCopyrightInfo Provides copyright information.
getClassesList Provides the set of classes information. This set can be used by ZModeler to map serives, tools, filters and other stuff, available in the library to according library holder.
createClass Creates a class instance specified by fully-qualified class name and provides it's controlling unknown.
getHandle Provides library's handle (HINSTANCE).
setHandle Sets library's handle (HINSTANCE).
requires Provides set of library requirements flags.
initialize Library initialization routine is called after loading and registering library but before ZModeler loads tools and other classes. Note, it's unsafe to access external services and classes in this routine. Consider using startup method instead. This routine is invoked if ZM_LIBREQUIRES_INIT bit was specified in library requirements.
startup Called after all libraries were loaded but before zmodeler switches to "started" state. This is where you can perform compatibility tests and perform any library-specific stuff. It is safe to access external services and tools in this routine. This routine is invoked if ZM_LIBREQUIRES_STARTUP bit was specified in library requirements.
unload Performs library unload routines (detaching from ZModeler, services, event handlers etc. Returns ZRESULT_OK if the library can be safely unloaded with AfxFreeLibrary. This routine is invoked if ZM_LIBREQUIRES_UNLOAD bit was specified in library requirements.
See Also:
overview of namespace core::libs
core::libs::ILibraryHolder interface
core::IRepository interface