27 lines
574 B
C++
27 lines
574 B
C++
|
|
/*
|
|||
|
|
* SetValue.cpp
|
|||
|
|
*
|
|||
|
|
* Created on: 4 авг. 2020 г.
|
|||
|
|
* Author: LeonidTitov
|
|||
|
|
*/
|
|||
|
|
|
|||
|
|
#include "SetValue.hh"
|
|||
|
|
|
|||
|
|
bool application::schematic::SetValue::input( Environment & env ) {
|
|||
|
|
|
|||
|
|
return grab( value, env.rholder.getShared<Value>( links.value ) );
|
|||
|
|
|
|||
|
|
}
|
|||
|
|
|
|||
|
|
void application::schematic::SetValue::build(Environment &env) {
|
|||
|
|
|
|||
|
|
typedef ::schematic::functor::SetValue<float> SetVal;
|
|||
|
|
|
|||
|
|
SetVal * set = memories::instance_object<SetVal>( env.static_object_ma, *value );
|
|||
|
|
|
|||
|
|
typedef systemic::IFunctor<void, float> Apply;
|
|||
|
|
|
|||
|
|
env.rholder.share<Apply>( *set, links.set );
|
|||
|
|
|
|||
|
|
}
|