Main Page | Namespace List | Class Hierarchy | Alphabetical List | Class List | File List | Namespace Members | Class Members

cllite::classname_to_dllname Struct Reference

A basic classname-to-DLL-name transformer. More...

#include <cllite.h>

List of all members.

Public Types

typedef std::string key_type

Public Member Functions

 classname_to_dllname (const key_type &ns_xlate)
 ns_xlate sets the namespace separator (::) replacement which will happen when this functor is activated.

key_type operator() (const key_type &key) const
 General conventions:.


Detailed Description

A basic classname-to-DLL-name transformer.

Intended to be used to transform namespaced/templated names into filename-friendly names.

Definition at line 104 of file cllite.h.


Constructor & Destructor Documentation

cllite::classname_to_dllname::classname_to_dllname const key_type ns_xlate  )  [explicit]
 

ns_xlate sets the namespace separator (::) replacement which will happen when this functor is activated.

e.g., passing "/" will cause foo::bar::MyType to translate to foo/bar/MyType


Member Function Documentation

key_type cllite::classname_to_dllname::operator() const key_type key  )  const
 

General conventions:.

Should return a DLL-friendly name of the given key, minus any extension: a set of platform-specific extensions is sed by class_path(). See the classname_to_dllname class for a sample implementation.

This implementation transforms class names such that:

  • By default namespace separators (::) are replaced by, "_", but this can be changed via the ctor

  • Any template parameters are simply removed.

e.g.:

std::list<foo> = std_list

MyType = MyType

foo::bar::MyType = foo_bar_MyType


The documentation for this struct was generated from the following file:
Generated on Wed Jul 28 16:04:15 2004 for s11n by doxygen 1.3.7