| 167 | } |
| 168 | |
| 169 | bool FullMobileId::fmidMatch(const GSM::L3MobileIdentity&mobileId) const |
| 170 | { |
| 171 | switch (mobileId.type()) { |
| 172 | case GSM::IMSIType: return 0 == strcmp(mImsi.c_str(),mobileId.digits()); |
| 173 | case GSM::IMEIType: return 0 == strcmp(mImei.c_str(),mobileId.digits()); |
| 174 | case GSM::TMSIType: return mTmsi.valid() && mTmsi.value() == mobileId.TMSI(); |
| 175 | default: return false; // something wrong, but certainly no match |
| 176 | } |
| 177 | } |
| 178 | |
| 179 | std::ostream& operator<<(std::ostream& os, const FullMobileId&msid) |
| 180 | { |