Public Member Functions | Private Attributes
Poco::MetaSingleton< C, B > Class Template Reference

#include <MetaObject.h>

Inheritance diagram for Poco::MetaSingleton< C, B >:
Inheritance graph
[legend]

List of all members.

Public Member Functions

bool canCreate () const
B * create () const
B & instance () const
bool isAutoDelete (B *pObject) const
 MetaSingleton (const char *name)
 ~MetaSingleton ()

Private Attributes

SingletonHolder< C > _object

Detailed Description

template<class C, class B>
class Poco::MetaSingleton< C, B >

A SingletonMetaObject disables the create() method and instead offers an instance() method to access the single instance of its class.

Definition at line 181 of file MetaObject.h.


Constructor & Destructor Documentation

template<class C , class B >
Poco::MetaSingleton< C, B >::MetaSingleton ( const char *  name) [inline]

Definition at line 187 of file MetaObject.h.

template<class C , class B >
Poco::MetaSingleton< C, B >::~MetaSingleton ( ) [inline]

Definition at line 191 of file MetaObject.h.


Member Function Documentation

template<class C , class B >
bool Poco::MetaSingleton< C, B >::canCreate ( ) const [inline, virtual]

Returns a reference to the only instance of the class. Used for singletons only.

Implements Poco::AbstractMetaObject< B >.

Definition at line 200 of file MetaObject.h.

template<class C , class B >
B* Poco::MetaSingleton< C, B >::create ( ) const [inline, virtual]

Implements Poco::AbstractMetaObject< B >.

Definition at line 195 of file MetaObject.h.

template<class C , class B >
B& Poco::MetaSingleton< C, B >::instance ( ) const [inline, virtual]

Create a new instance of a class. Cannot be used for singletons.

Implements Poco::AbstractMetaObject< B >.

Definition at line 205 of file MetaObject.h.

template<class C , class B >
bool Poco::MetaSingleton< C, B >::isAutoDelete ( B *  pObject) const [inline, virtual]

Returns true if the object is owned by meta object.

Overloaded in MetaSingleton - returns true if the class is a singleton.

Reimplemented from Poco::AbstractMetaObject< B >.

Definition at line 210 of file MetaObject.h.


Member Data Documentation

template<class C , class B >
SingletonHolder<C> Poco::MetaSingleton< C, B >::_object [mutable, private]

Definition at line 216 of file MetaObject.h.


The documentation for this class was generated from the following file:


pluginlib
Author(s): Tully Foote and Eitan Marder-Eppstein
autogenerated on Sat Dec 28 2013 17:20:20