te::qt::widgets::SimplePropertyWidgetFactory Class Referenceabstract

A factory to build widget objects. More...

#include <SimplePropertyWidgetFactory.h>

Inheritance diagram for te::qt::widgets::SimplePropertyWidgetFactory:
te::common::AbstractFactory< te::qt::widgets::SimplePropertyWidget, int > te::qt::widgets::DateTimePropertyWidgetFactory te::qt::widgets::GeometryPropertyWidgetFactory te::qt::widgets::NumericPropertyWidgetFactory te::qt::widgets::StringPropertyWidgetFactory

Public Types

typedef FactoryDictionary< AbstractFactory< te::qt::widgets::SimplePropertyWidget, int, std::less< int > >, int, std::less< int > > dictionary_type
 
typedef AbstractFactory factory_type
 

Public Member Functions

const int & getKey () const
 It returns the factory key associated to the concreate factory. More...
 
virtual int getType () const =0
 It returns the type of component widget that the factory knows how to create. More...
 
virtual ~SimplePropertyWidgetFactory ()
 Virtual destructor. More...
 

Static Public Member Functions

static const factory_typefind (const int &factoryKey)
 
static dictionary_typegetDictionary ()
 It returns a reference to the internal dictionary of concrete factories. More...
 
static te::qt::widgets::SimplePropertyWidgetmake (const int &type)
 
static te::qt::widgets::SimplePropertyWidgetmake (const int &type, QWidget *parent=0)
 

Protected Member Functions

virtual te::qt::widgets::SimplePropertyWidgetbuild ()=0
 Concrete factories (derived from this one) must implement this method in order to create objects. More...
 
virtual te::qt::widgets::SimplePropertyWidgetcreate (QWidget *Parent=0)=0
 
 SimplePropertyWidgetFactory (const int &factoryKey)
 It creates the factory. More...
 

Protected Attributes

int m_factoryKey
 The key that identifies the concrete factory: it will be used for unregistering the factory during destruction. More...
 

Detailed Description

A factory to build widget objects.

Definition at line 49 of file SimplePropertyWidgetFactory.h.

Member Typedef Documentation

◆ dictionary_type

typedef FactoryDictionary<AbstractFactory<te::qt::widgets::SimplePropertyWidget , int , std::less<int > >, int , std::less<int > > te::common::AbstractFactory< te::qt::widgets::SimplePropertyWidget , int , std::less<int > >::dictionary_type
inherited

Definition at line 73 of file AbstractFactory.h.

◆ factory_type

Definition at line 77 of file AbstractFactory.h.

Constructor & Destructor Documentation

◆ ~SimplePropertyWidgetFactory()

virtual te::qt::widgets::SimplePropertyWidgetFactory::~SimplePropertyWidgetFactory ( )
virtual

Virtual destructor.

Note
It will automatically unregister the factory from the dictionary.

◆ SimplePropertyWidgetFactory()

te::qt::widgets::SimplePropertyWidgetFactory::SimplePropertyWidgetFactory ( const int &  factoryKey)
protected

It creates the factory.

The key of a ComponentWidgetFactory is a string.

Parameters
factoryKeyThe key that identifies the factory.

Member Function Documentation

◆ build()

virtual te::qt::widgets::SimplePropertyWidget * te::common::AbstractFactory< te::qt::widgets::SimplePropertyWidget , int , std::less<int > >::build ( )
protectedpure virtualinherited

Concrete factories (derived from this one) must implement this method in order to create objects.

Returns
It returns an object created by the concrete factory.

Implemented in te::qt::widgets::DateTimePropertyWidgetFactory, te::qt::widgets::GeometryPropertyWidgetFactory, te::qt::widgets::NumericPropertyWidgetFactory, and te::qt::widgets::StringPropertyWidgetFactory.

◆ create()

◆ find()

const AbstractFactory< te::qt::widgets::SimplePropertyWidget , int , std::less<int > >::factory_type * te::common::AbstractFactory< te::qt::widgets::SimplePropertyWidget , int , std::less<int > >::find ( const int &  factoryKey)
inlinestaticinherited

Definition at line 164 of file AbstractFactory.h.

◆ getDictionary()

AbstractFactory< te::qt::widgets::SimplePropertyWidget , int , std::less<int > >::dictionary_type & te::common::AbstractFactory< te::qt::widgets::SimplePropertyWidget , int , std::less<int > >::getDictionary ( )
inlinestaticinherited

It returns a reference to the internal dictionary of concrete factories.

The dictionary is a singleton.

Returns
A reference to the internal dictionary.

Definition at line 157 of file AbstractFactory.h.

◆ getKey()

const int & te::common::AbstractFactory< te::qt::widgets::SimplePropertyWidget , int , std::less<int > >::getKey ( ) const
inlineinherited

It returns the factory key associated to the concreate factory.

Returns
The factory key associated to the concreate factory.

Definition at line 140 of file AbstractFactory.h.

◆ getType()

virtual int te::qt::widgets::SimplePropertyWidgetFactory::getType ( ) const
pure virtual

It returns the type of component widget that the factory knows how to create.

Returns
The type of component widget that the factory knows how to create.

Implemented in te::qt::widgets::DateTimePropertyWidgetFactory, te::qt::widgets::GeometryPropertyWidgetFactory, te::qt::widgets::NumericPropertyWidgetFactory, and te::qt::widgets::StringPropertyWidgetFactory.

◆ make() [1/2]

static te::qt::widgets::SimplePropertyWidget* te::qt::widgets::SimplePropertyWidgetFactory::make ( const int &  type)
static

◆ make() [2/2]

static te::qt::widgets::SimplePropertyWidget* te::qt::widgets::SimplePropertyWidgetFactory::make ( const int &  type,
QWidget *  parent = 0 
)
static

Member Data Documentation

◆ m_factoryKey

int te::common::AbstractFactory< te::qt::widgets::SimplePropertyWidget , int , std::less<int > >::m_factoryKey
protectedinherited

The key that identifies the concrete factory: it will be used for unregistering the factory during destruction.

Definition at line 136 of file AbstractFactory.h.


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