C++ (Qt)//! Функция возврата элемента.const ValueType &value(const char *key) const { size_t key_len = strlen(key); uint32_t key_hash = calcHash(key, key_len); if(!_p_units.isEmpty()) { int val = (key_hash & 0x000000ff); int index = val - _lvl_min[0]; //if(index >= 0/* && index < _p_units.size()*/) { const QVector<QVector<QVector<Unit*> > > &p_units1 = _p_units.at(index); val = (key_hash & 0x0000ff00) >> 8; index = val - _lvl_min[1]; //if(index >= 0/* && index < p_units1.size()*/) { const QVector<QVector<Unit*> > &p_units2 = p_units1.at(index); val = (key_hash & 0x0000ff00) >> 16; index = val - _lvl_min[2]; //if(index >= 0/* && index < p_units2.size()*/) { const QVector<Unit*> &p_units3 = p_units2.at(index); val = (key_hash & 0x0000ff00) >> 24; index = val - _lvl_min[3]; //if(index >= 0/* && index < p_units3.size()*/) { return p_units3.at(index)->value(); //} //} //} //} } return ValueType();}