In my application I am keeping a copy of all contacts in a HashMap (key = phone-number formatted by Google phone lib, value = name) to look-up a person's contact name by phone number quickly.
I want to update my HashMap when a new contact is added to the phone; how can I capture this event in my application and update my contacts list HashMap?
Any useful article or a piece of code would be really helpful.