("release", MANDTAORY, xml::parseDefAssign( _release ) )
("arch", MANDTAORY, xml::parseDefAssign( _pdata._arch ) )
("shortsummary", OPTIONAL, xml::parseDefAssign( _pdata._shortName ) )
- ("summary", OPTIONAL, xml::parseDefAssign( _pdata._summary ) )
+ ("summary", MULTIPLE_OPTIONAL, xml::parseDefAssign( _ttext )( "lang", _tlocale )
+ >>bind( &ProductNode::doneLocalizedDefault, this, _1, boost::ref(_pdata._summary) ))
("productline", OPTIONAL, xml::parseDefAssign( _pdata._productline ) )
("register", OPTIONAL)
("updaterepokey", OPTIONAL, xml::parseDefAssign( _pdata._updaterepokey ) )
_pdata._upgrades.push_back( cdata );
_upgrade = ProductFileData::Upgrade::Impl();
}
+ /** collect localized data */
+ void doneLocalizedDefault( const xml::Node & _node, std::string & store_r )
+ {
+ // take 1st or default
+ if ( store_r.empty() || _tlocale.empty() )
+ store_r = _ttext;
+ }
/** finaly */
void done( const xml::Node & _node )
std::string _version;
std::string _release;
+ std::string _ttext;
+ std::string _tlocale;
+
ProductFileData::Upgrade::Impl _upgrade;
};