How to Determine if Android Device has Network-based Geolocation

public static final String FEATURE_LOCATION_NETWORK was added in API level 8
Feature for getSystemAvailableFeatures() and hasSystemFeature(String).
The device can report location with coarse accuracy using a network-based geolocation system.
Constant Value: ""

1. Get a PackageManager Instance and save to myPackageManager.

2. Create a Boolean Variable named bolNBSupported

3. Set the Minimum and Target SDK version  to or greater. 

4. In the onCreate method, add the below code. This will return the network-based geolocation ability to a boolean named bolGPSSupported. It will then display a toast displaying the network-based geolocation ability on the device to the user.

bolNBSupported = myPackageManager.hasSystemFeature(PackageManager.FEATURE_LOCATION_NETWORK);
if (bolNBSupported) {
Toast.makeText(this, "Device has network-based geolocation feature", Toast.LENGTH_LONG).show();
} else {
Toast.makeText(this, "No network-based geolocation feature!", Toast.LENGTH_LONG).show();

5. Compile and run!