24 #include <boost/functional/hash.hpp> 37 : child_data_(
std::make_shared<
ChildData>(
"EmptyAbstract",
"" ) )
59 boost::hash_combine(seed,
"Abstract");
61 boost::hash_combine(seed,
child_data_->description_);
63 boost::hash_combine(seed, param.first );
64 boost::hash_combine(seed, param.second );
136 if (!is_generic && child.is_root_of_generic_subtree())
THROW( ExcGenericWithoutInstance() << EI_Object(child.type_name()) );
137 child.add_parent(*
this);
145 }
catch (ExcWrongDefault & e) {
146 e << EI_Desc(
"Default value for TYPE key do not match any descendant of Abstract.")
149 }
catch (ExcWrongDefaultJSON & e) {
150 e << EI_DefaultStr(
child_data_->selection_default_.value() ) << EI_TypeName(this->
type_name());
186 if ( !
child_data_->selection_default_.is_obligatory() ) {
187 if (
child_data_->selection_default_.has_value_at_declaration() ) {
202 abstract.child_data_->closed_ =
true;
206 abstract.add_child( static_cast<Record &>( *(inst.first) ) );
208 parameter_map.insert(other_map.begin(), other_map.end());
211 abstract.child_data_->closed_ =
false;
214 abstract.parameter_map_ = parameter_map;
218 return std::make_pair( std::make_shared<Abstract>(
abstract.
close()), parameter_map );
224 abstract.child_data_ = std::make_shared<Abstract::ChildData>(*this->
child_data_);
225 abstract.child_data_->closed_ =
false;
226 abstract.child_data_->finished_ =
false;
227 abstract.child_data_->list_of_childs.clear();
228 abstract.child_data_->selection_of_childs = std::make_shared<Selection>(this->
type_name() +
"_TYPE_selection");
270 :
Abstract(
"Derived AdHocAbstract",
"This description doesn't have print out."),
315 boost::hash_combine(seed,
"AdHocAbstract");
317 boost::hash_combine(seed,
child_data_->description_);
#define ASSERT(expr)
Allow use shorter versions of macro names if these names is not used with external library...
#define THROW(whole_exception_expr)
Wrapper for throw. Saves the throwing point.