PLaSK library
|
Template of base of scaled provider. More...
#include <plask/provider/scaled_provider.hpp>
Public Types | |
typedef SrcProviderT | SourceType |
typedef DstProviderT | DestinationType |
typedef ScaleT | ScaleType |
Public Member Functions | |
ScaledProviderBase (ScaleT scale=1.) | |
Create the provider. | |
void | set (SrcProviderT *src, bool prv=false) |
Set source provider. | |
void | set (std::unique_ptr< SrcProviderT > &&src) |
Set source provider. | |
void | reset () |
Reset source provider. | |
SrcProviderT * | getSource () const |
Obtain source provider. | |
~ScaledProviderBase () | |
void | ensureHasProvider () const |
Throw exception if the providers set of this is empty. | |
Public Attributes | |
ScaleT | scale |
Scale for the provider value. | |
Protected Attributes | |
SrcProviderT * | source |
Source provider. | |
Template of base of scaled provider.
Definition at line 30 of file scaled_provider.hpp.
typedef DstProviderT plask::ScaledProviderBase< DstProviderT, SrcProviderT, ScaleT >::DestinationType |
Definition at line 33 of file scaled_provider.hpp.
typedef ScaleT plask::ScaledProviderBase< DstProviderT, SrcProviderT, ScaleT >::ScaleType |
Definition at line 34 of file scaled_provider.hpp.
typedef SrcProviderT plask::ScaledProviderBase< DstProviderT, SrcProviderT, ScaleT >::SourceType |
Definition at line 32 of file scaled_provider.hpp.
|
inline |
Create the provider.
scale | initial scale |
Definition at line 60 of file scaled_provider.hpp.
|
inline |
Definition at line 101 of file scaled_provider.hpp.
|
inline |
Throw exception if the providers set of this is empty.
Definition at line 108 of file scaled_provider.hpp.
|
inline |
|
inline |
Reset source provider.
Definition at line 86 of file scaled_provider.hpp.
|
inline |
Set source provider.
src | source provider |
prv | true only if src is private and should be deleted by destructor of this |
Definition at line 67 of file scaled_provider.hpp.
|
inline |
Set source provider.
src | source provider |
Definition at line 79 of file scaled_provider.hpp.
ScaleT plask::ScaledProviderBase< DstProviderT, SrcProviderT, ScaleT >::scale |
Scale for the provider value.
Definition at line 54 of file scaled_provider.hpp.
|
protected |
Source provider.
Definition at line 38 of file scaled_provider.hpp.