This page last changed on Sep 26, 2007 by gsim@redhat.com.

C++ public API guidelines.

These guidelines are for the public client API to be released in qpid 1.0. The "plugin" API exposed for bdbstore should eventually follow these guidelines but it can be deferred.

Public header files

Public headers under: qpid/cpp/src/include 

Non-unit client tests  should be built with -I include and without -I . so that missing public headers can be quickly identified.

 Only src/include headers are installed with package qpidc-devel. Package qpidd-devel should only install src/include headers, but for 1.0 it may still install private headers.

PIMPL idiom

Value classes needed by the user (e.g. framing data types, message content) are exposed as normal classes in public headers.

Service classes (e.g. Session, Connection etc) use the pimpl idiom for  compatibility isolation. See http://en.wikipedia.org/wiki/Pimpl.

Thread safety

I believe making the session thread safe will make it simpler to use in various circumstances (some of which may be unforeseen). I don't think it necessarily adds significant overhead (though this is something we can verify).

= Namespaces in Client Applications =

Currently, a client application needs the following namespaces:

using namespace qpid::client;
using namespace qpid::framing;

Why should someone writing a client application need to know about the framing namespace? And is 'framing' really the best name to describe this namespace?

Posted by jonathan.robie@redhat.com at Sep 20, 2007 06:58
Document generated by Confluence on Apr 22, 2008 02:47