The function checks if the object satisfies the subscription and adds to changes. The actions could be: '+' - created '~' - changed '-' - deleted
988 {
989
990 bool any = (class_names.empty() && objects.empty());
991
992
993
994
995
996
997
998 OksConfiguration::SMap::const_iterator omi = objects.end();
999
1000 if(action != '+') {
1001 omi = objects.find(obj_class);
1002 if(omi != objects.end()) {
1003 std::set<std::string>::const_iterator i = omi->second.find(obj_id);
1004
1005 if(i != omi->second.end()) {
1007 }
1008 }
1009 }
1010
1011
1012
1013
1014 if(action == '+' || omi == objects.end()) {
1015 if(any || class_names.find(obj_class) != class_names.end()) {
1017 }
1018 }
1019
1020
1021
1022
1023 OksConfiguration::SMap::const_iterator it = inheritance.
data().find(obj_class);
1024 if(it != inheritance.
data().end()) {
1025 for(std::set<std::string>::const_iterator j = it->second.begin(); j != it->second.end(); ++j) {
1026 omi = (
action !=
'+' ? objects.find(*j) : objects.end());
1027
1028
1029
1030
1031
1032 if(
1033 any ||
1034 (
1035 omi == objects.end() &&
1036 class_names.find(*j) != class_names.end()
1037 ) ||
1038 (
1039 omi != objects.end() &&
1040 omi->second.find(obj_id) != omi->second.end()
1041 )
1042 ) {
1044 }
1045 }
1046 }
1047}
static void add(std::vector< ConfigurationChange * > &changes, const std::string &class_name, const std::string &obj_id, const char action)
Helper method to add object to the vector of existing changes.
const OksConfiguration::SMap & data() const