FBB::TypeTrait

FBB::TypeTrait

libbobcat1-dev_2.02.03-x.tar.gz

2005-2009


FBB::TypeTrait(3bobcat)

FBB::TypeTrait(3bobcat)

libbobcat1-dev_2.02.03-x.tar.gz Error handler

2005-2009

NAME

FBB::TypeTrait - shortdesc

SYNOPSIS

#include <bobcat/typetrait>

DESCRIPTION

FBB::TypeTrait is a traits class. It does not define any member functions or data members, but only types. It can be used to determine the basic type and other characteristics of (const) plain, (const) pointer or (const) reference types. It is used, e.g., by the FBB::FnWrap* family of template classes and was designed after Alexandrescu's (2001) TypeTraits template class.

NAMESPACE

FBB
All constructors, members, operators and manipulators, mentioned in this man-page, are defined in the namespace FBB.

INHERITS FROM

-

TYPE

BOOL VALUES

EXAMPLE

The following example shows a fragment of the code used in the FBB::FnWrap1 class determining the basic type of its Type template parameter:


    #include <bobcat/typetrait>
    ...
    template <typename Type, typename ReturnType = void>
    class FnWrap1
    {
        ...
        public:
            typedef typename TypeTrait<Type>::Plain  argument_type;
        ...
    };
        
The above code could have used TypeTrait<Type>::isPointer to determine whether Type actually represents a pointer type.

FILES

bobcat/typetrait - defines the class interface

SEE ALSO

bobcat(7)
Alexandrescu A. (2001) Modern C++ Design, Addison-Wesley, Boston.

BUGS

None Reported.

DISTRIBUTION FILES

BOBCAT

Bobcat is an acronym of `Brokken's Own Base Classes And Templates'.

COPYRIGHT

This is free software, distributed under the terms of the GNU General Public License (GPL).

AUTHOR

Frank B. Brokken (f.b.brokken@rug.nl).