Example #1
0
void Membership::assign(const types::Variant::List& list) {
    brokers.clear();
    for (types::Variant::List::const_iterator i = list.begin(); i != list.end(); ++i) {
        BrokerInfo b(i->asMap());
        brokers[b.getSystemId()] = b;
    }
}
Example #2
0
void Membership::assign(const types::Variant::List& list) {
    Mutex::ScopedLock l(lock);
    clear();
    for (types::Variant::List::const_iterator i = list.begin(); i != list.end(); ++i) {
        BrokerInfo b(i->asMap());
        brokers[b.getSystemId()] = b;
    }
    update(true, l);
}