How the Phone app is able to handle from which city a call is coming ?

    Local database of phone prefixes I think.

    Hat

    🎶I've got hoes, I've got hoes, in different area codes, area codes. hoes, hoes, in different area codes, area codes🎶

    Hat
    The phone app does not "handle" where a call is coming in from. What do you mean by "handle"?

    As far as I understand, the phone app displays whatever information the "network" sends it.

    In my Phone app "Recents" section, for some recents calls I can see :

    The number
    The city or country, and date

    In that case, I don't know for sure but probably its just a simple area code look up.

    I don't see a reference to a local database of phone prefixes.
    I did some research. The Phone app seems to be named Dialer on AOSP :

    • The Android Telecom framework manages audio and video calls on an Android device.
    • Screen calls. The spam check need network verification.
      But too much information there.

    It look more interesting here in the spam section :

    void reportSpamFromCallHistory(
          String number,
          String countryIso,
          int callType,
          ReportingLocation.Type from,
          ContactSource.Type contactSourceType);

    An input to the discussion from someone more technical would be useful.

    People looking at the source code use something better than the search field "Go to file" on Github ?
    Don't know if it's a Google limitation but I can't use the search function in https://developer.android.com/