WD
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
webdriver::ViewCreator Class Referenceabstract

#include <webdriver_view_factory.h>

Inheritance diagram for webdriver::ViewCreator:
Collaboration diagram for webdriver::ViewCreator:

Public Member Functions

 ViewCreator ()
 
virtual ~ViewCreator ()
 
template<class C >
void RegisterViewClass (const std::string &id)
 
virtual bool CreateViewByClassName (const Logger &logger, const std::string &className, const Point *position, const Size *size, ViewHandle **view) const =0
 
virtual bool CreateViewForUrl (const Logger &logger, const std::string &url, const Point *position, const Size *size, ViewHandle **view) const =0
 

Protected Types

typedef std::map< std::string,
CreateViewMethod
FactoryMap
 

Protected Attributes

FactoryMap factory
 

Detailed Description

base class for custom view's creators

Member Typedef Documentation

typedef std::map<std::string, CreateViewMethod> webdriver::ViewCreator::FactoryMap
protected

Constructor & Destructor Documentation

webdriver::ViewCreator::ViewCreator ( )
virtual webdriver::ViewCreator::~ViewCreator ( )
inlinevirtual

Member Function Documentation

virtual bool webdriver::ViewCreator::CreateViewByClassName ( const Logger logger,
const std::string &  className,
const Point position,
const Size size,
ViewHandle **  view 
) const
pure virtual

creates new view of specified class

Parameters
[in]logger
[in]classNamerequested class name
[in]position- desired position
[in]size- desired size
[out]viewcreated view.
Returns
true if handled

Implemented in webdriver::QWebViewCreator, webdriver::QQmlViewCreator, webdriver::Quick2ViewCreator, and webdriver::QWidgetViewCreator.

virtual bool webdriver::ViewCreator::CreateViewForUrl ( const Logger logger,
const std::string &  url,
const Point position,
const Size size,
ViewHandle **  view 
) const
pure virtual

creates new view that can handle specified url

Parameters
[in]logger
[in]urlurl to handle
[in]position- desired position
[in]size- desired size
[out]viewcreated view.
Returns
true if handled

Implemented in webdriver::QWebViewCreator, webdriver::QQmlViewCreator, webdriver::Quick2ViewCreator, and webdriver::QWidgetViewCreator.

template<class C >
void webdriver::ViewCreator::RegisterViewClass ( const std::string &  id)
inline

register class for specific class name

Template Parameters
<C>class for view
Parameters
idclass name

Member Data Documentation

FactoryMap webdriver::ViewCreator::factory
protected

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