PLaSK library
Loading...
Searching...
No Matches
plask::ProviderImpl< PropertyT, MULTI_VALUE_PROPERTY, SpaceT, VariadicTemplateTypesHolder< _ExtraParams... > >::Delegate Struct Reference

Implementation of one value provider class which delegates all operator() calls to external functor. More...

#include <plask/provider/providerfor.hpp>

Inheritance diagram for plask::ProviderImpl< PropertyT, MULTI_VALUE_PROPERTY, SpaceT, VariadicTemplateTypesHolder< _ExtraParams... > >::Delegate:
[legend]
Collaboration diagram for plask::ProviderImpl< PropertyT, MULTI_VALUE_PROPERTY, SpaceT, VariadicTemplateTypesHolder< _ExtraParams... > >::Delegate:
[legend]

Public Types

typedef PolymorphicDelegateProvider< ProviderFor< PropertyT, SpaceT >, ProvidedType(EnumType, _ExtraParams...)> Base
 

Public Member Functions

template<typename Functor , typename Sizer >
 Delegate (Functor functor, Sizer sizer)
 Create delegate provider.
 
template<typename ClassType , typename MemberType >
 Delegate (ClassType *object, MemberType member, size_t(ClassType::*sizer)() const)
 Create delegate provider.
 
template<typename ClassType , typename MemberType >
 Delegate (ClassType *object, MemberType member, size_t(ClassType::*sizer)())
 Create delegate provider.
 
template<typename Functor >
 Delegate (Functor functor)
 Create delegate provider.
 
template<typename ClassType , typename MemberType >
 Delegate (ClassType *object, MemberType member)
 Create delegate provider.
 
size_t size () const override
 

Public Attributes

std::function< size_t()> sizeGetter
 

Detailed Description

template<typename PropertyT, typename SpaceT, typename... _ExtraParams>
struct plask::ProviderImpl< PropertyT, MULTI_VALUE_PROPERTY, SpaceT, VariadicTemplateTypesHolder< _ExtraParams... > >::Delegate

Implementation of one value provider class which delegates all operator() calls to external functor.

Definition at line 956 of file providerfor.hpp.

Member Typedef Documentation

◆ Base

template<typename PropertyT , typename SpaceT , typename... _ExtraParams>
typedef PolymorphicDelegateProvider<ProviderFor<PropertyT, SpaceT>, ProvidedType(EnumType, _ExtraParams...)> plask::ProviderImpl< PropertyT, MULTI_VALUE_PROPERTY, SpaceT, VariadicTemplateTypesHolder< _ExtraParams... > >::Delegate::Base

Definition at line 958 of file providerfor.hpp.

Constructor & Destructor Documentation

◆ Delegate() [1/5]

template<typename PropertyT , typename SpaceT , typename... _ExtraParams>
template<typename Functor , typename Sizer >
plask::ProviderImpl< PropertyT, MULTI_VALUE_PROPERTY, SpaceT, VariadicTemplateTypesHolder< _ExtraParams... > >::Delegate::Delegate ( Functor  functor,
Sizer  sizer 
)
inline

Create delegate provider.

Parameters
functordelegate functor

Definition at line 967 of file providerfor.hpp.

◆ Delegate() [2/5]

template<typename PropertyT , typename SpaceT , typename... _ExtraParams>
template<typename ClassType , typename MemberType >
plask::ProviderImpl< PropertyT, MULTI_VALUE_PROPERTY, SpaceT, VariadicTemplateTypesHolder< _ExtraParams... > >::Delegate::Delegate ( ClassType *  object,
MemberType  member,
size_t(ClassType::*)() const  sizer 
)
inline

Create delegate provider.

Parameters
objectobject of class with delegate method
memberdelegate member method
sizerclass member returning number of the elements

Definition at line 976 of file providerfor.hpp.

◆ Delegate() [3/5]

template<typename PropertyT , typename SpaceT , typename... _ExtraParams>
template<typename ClassType , typename MemberType >
plask::ProviderImpl< PropertyT, MULTI_VALUE_PROPERTY, SpaceT, VariadicTemplateTypesHolder< _ExtraParams... > >::Delegate::Delegate ( ClassType *  object,
MemberType  member,
size_t(ClassType::*)()  sizer 
)
inline

Create delegate provider.

Parameters
objectobject of class with delegate method
memberdelegate member method
sizerclass member returning number of the elements

Definition at line 986 of file providerfor.hpp.

◆ Delegate() [4/5]

template<typename PropertyT , typename SpaceT , typename... _ExtraParams>
template<typename Functor >
plask::ProviderImpl< PropertyT, MULTI_VALUE_PROPERTY, SpaceT, VariadicTemplateTypesHolder< _ExtraParams... > >::Delegate::Delegate ( Functor  functor)
inline

Create delegate provider.

Parameters
functordelegate functor

Definition at line 994 of file providerfor.hpp.

◆ Delegate() [5/5]

template<typename PropertyT , typename SpaceT , typename... _ExtraParams>
template<typename ClassType , typename MemberType >
plask::ProviderImpl< PropertyT, MULTI_VALUE_PROPERTY, SpaceT, VariadicTemplateTypesHolder< _ExtraParams... > >::Delegate::Delegate ( ClassType *  object,
MemberType  member 
)
inline

Create delegate provider.

Parameters
objectobject of class with delegate method
memberdelegate member method
sizerclass member returning number of the elements

Definition at line 1003 of file providerfor.hpp.

Member Function Documentation

◆ size()

template<typename PropertyT , typename SpaceT , typename... _ExtraParams>
size_t plask::ProviderImpl< PropertyT, MULTI_VALUE_PROPERTY, SpaceT, VariadicTemplateTypesHolder< _ExtraParams... > >::Delegate::size ( ) const
inlineoverride

Definition at line 1005 of file providerfor.hpp.

Member Data Documentation

◆ sizeGetter

template<typename PropertyT , typename SpaceT , typename... _ExtraParams>
std::function<size_t()> plask::ProviderImpl< PropertyT, MULTI_VALUE_PROPERTY, SpaceT, VariadicTemplateTypesHolder< _ExtraParams... > >::Delegate::sizeGetter

Definition at line 960 of file providerfor.hpp.


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