Locations can be obtained using different methods:
- Global Positioning System aka GPS is based on satellites. See: gps
- network based location includes GSM localization (using phone tower IDs and their known positions) and the known locations of WiFi routers
- mock-location can be a "fake location" (random or fixed), but as well some external device (e.g. Bluetooth GPS mouse) providing real data.
- Location Based Services - Wikipedia (en)