Changeset 4463

Timestamp:
Jun 6, 2007, 1:00:39 AM (15 years ago)
Author:
mconsoni
Message:

This is the new example that specifically shows the use of Info class with a base class
and concrete implementations. I've added a new directory under info, because it's an
example of Info class, but with its own subdirectory (im).

The example is about Instant Messengers... We have a protocol interface and then some
plugins that implements the generic protocol with the specific operations for each
concrete network (MSN, Jabber). The Info class is used for network parameters. There
is a base_class that define the available parameters for a generic protocol, and
then there are the different concrete implementations for the plugin. In short,
there is for example an http_method that it's only available for MSN.. then in main
we could check that parameter.

Of course all is just a test.. there are no real implementations..! :)

  • Jamfile.v2: added the new library and sources.
  • info/im: main subdirectory for the example

. protocol.hpp: generic protocol interface (send, receive, login).
. plugins.cpp: concrete implementations of the interface for MSN

and Jabber protocol, and factory map.

. network_parameters.hpp : base class and concrete implementations for

the network parameters, for each protocol.

. im_main.cpp: main function, it loads the library and make some operations

with the protocol.

(No files)

Note: See TracChangeset for help on using the changeset viewer.