COID framework server manages C++ classes whose declaration was
decorated in minimally obtrusive way by special keywords, that make it
possible to perform lookup, versioning and remote object access
services atop the ordinary C++ classes. The coidgen
tool generates client class and server side dispatch .cpp file required
for the versioning and remote access. The framework server uses
information registered in the dispatch file to feed the lookup and
versioning handlers. The server automatically estabilishes optimal
connection mode for client. If the client comes from the same process
where the required service runs or is to be created, the COID server
creates vtable that is used by the client to call methods in the same
way as it would call virtual methods in a ordinary C++ class. If the
client is remote, the client class is hooked through netstream
specialization of abstract binstream
class to the server-side dispatcher of the class, that was generated
automatically by the coidgen tool.
COID framework server is implemented in dynamically loaded library libcoidserver. After reading its
configuration file dev.conf it loads
.dev libraries found in subdirectories of ./device directory.
The .dev files are normal dynamically linked libraries that export
specific method used to get list of COID-extended classes, called services, that the device (the .dev
file) implements, and that will be served by the COID framework server.
The device may contain several different services, usually chunked
together into the device because they tightly cooperate.
In addition to these external services, the libcoidserver library
looks for services contained in itself, and for services contained in
the current process. This means that you can link the libcoidserver
library with your executable and have served your COID-extended classes
automatically.
The libcoidserver library itself contains several core services used
internally throughout the framework, some of them can be connected
remotely or are used by other external services, such as the remote
console service. These services are used in direct mode within the
server, what means that there's just as much overhead in calling their
methods as it's in calling virtual C++ methods. These services are: