Ejemplo n.º 1
0
PersistencyConfig ParsePersistency::parse(const XML::Node &node) const
{
  // this will be checked before this call happens anyway
  assert( node.getName()=="persistency" );

  const PersistencyConfig::TypeName type=node.getChild("type").getValuesString();
  PersistencyConfig::Options        options;

  // get all options to a single string
  const Node::TNodesList &children=node.getChildrenList();
  for(Node::TNodesList::const_iterator it=children.begin(); it!=children.end(); ++it)
    if( it->getName()!="type" )     // skip persistency type name
      options[ it->getName() ] = it->getValuesString();

  return PersistencyConfig(type, options);
}
Ejemplo n.º 2
0
ParseTriggers::ParseTriggers(const XML::Node &node):
  Generic::Parse<TriggerConfig, TriggersConfigCollection, true>(node)
{
  assert( node.getName()=="triggers" );
}