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

Implementation of one value provider class which holds value inside (in value field) and operator() returns its held value. More...

#include <plask/provider/providerfor.hpp>

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

Public Types

typedef ValueType ProvidedType
 Type of provided value.
 
- Public Types inherited from plask::ProviderFor< PropertyT, SpaceT >
typedef PropertyT PropertyTag
 
typedef SpaceT SpaceType
 

Public Member Functions

template<typename ... Args>
 WithDefaultValue (Args &&... params)
 Delegate all constructors to value.
 
WithDefaultValue & operator= (const ValueType &v)
 Set new value.
 
ProvidedType operator() (_ExtraParams...) const override
 Get provided value.
 
- Public Member Functions inherited from plask::ProviderFor< PropertyT, SpaceT >
 ProviderFor (Args &&... params)
 Delegate all constructors to parent class.
 

Public Attributes

ProvidedType value
 Provided value.
 

Detailed Description

template<typename PropertyT, typename SpaceT, typename... _ExtraParams>
struct plask::ProviderImpl< PropertyT, SINGLE_VALUE_PROPERTY, SpaceT, VariadicTemplateTypesHolder< _ExtraParams... > >::WithDefaultValue

Implementation of one value provider class which holds value inside (in value field) and operator() returns its held value.

It always has a value.

It ignores extra parameters.

Definition at line 668 of file providerfor.hpp.

Member Typedef Documentation

◆ ProvidedType

template<typename PropertyT , typename SpaceT , typename... _ExtraParams>
typedef ValueType plask::ProviderImpl< PropertyT, SINGLE_VALUE_PROPERTY, SpaceT, VariadicTemplateTypesHolder< _ExtraParams... > >::WithDefaultValue::ProvidedType

Type of provided value.

Definition at line 671 of file providerfor.hpp.

Constructor & Destructor Documentation

◆ WithDefaultValue()

template<typename PropertyT , typename SpaceT , typename... _ExtraParams>
template<typename ... Args>
plask::ProviderImpl< PropertyT, SINGLE_VALUE_PROPERTY, SpaceT, VariadicTemplateTypesHolder< _ExtraParams... > >::WithDefaultValue::WithDefaultValue ( Args &&...  params)
inline

Delegate all constructors to value.

Definition at line 678 of file providerfor.hpp.

Member Function Documentation

◆ operator()()

template<typename PropertyT , typename SpaceT , typename... _ExtraParams>
ProvidedType plask::ProviderImpl< PropertyT, SINGLE_VALUE_PROPERTY, SpaceT, VariadicTemplateTypesHolder< _ExtraParams... > >::WithDefaultValue::operator() ( _ExtraParams...  ) const
inlineoverride

Get provided value.

Returns
provided value

Definition at line 694 of file providerfor.hpp.

◆ operator=()

template<typename PropertyT , typename SpaceT , typename... _ExtraParams>
WithDefaultValue & plask::ProviderImpl< PropertyT, SINGLE_VALUE_PROPERTY, SpaceT, VariadicTemplateTypesHolder< _ExtraParams... > >::WithDefaultValue::operator= ( const ValueType v)
inline

Set new value.

Parameters
vnew value
Returns
*this

Definition at line 685 of file providerfor.hpp.

Member Data Documentation

◆ value

template<typename PropertyT , typename SpaceT , typename... _ExtraParams>
ProvidedType plask::ProviderImpl< PropertyT, SINGLE_VALUE_PROPERTY, SpaceT, VariadicTemplateTypesHolder< _ExtraParams... > >::WithDefaultValue::value

Provided value.

Definition at line 674 of file providerfor.hpp.


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