I am new to Android development and I am currently trying to get my app to place a maker on a current location once a button is pressed. @SuppressLint("NewApi")
public class MainActivity extends Activity implements LocationListener {
 GoogleMap map;

```
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_main);

LocationManager lm = (LocationManager) getSystemService(Context.LOCATION_SERVICE);

lm.requestLocationUpdates(LocationManager.NETWORK_PROVIDER, 0, 0, this);

map = ((MapFragment) getFragmentManager().findFragmentById(R.id.map))
.getMap();

map.setMyLocationEnabled(true);

map.setPadding(0,200,0,0);

}

@Override
public void onLocationChanged(Location location) {

MarkerOptions mp = new MarkerOptions();

mp.position(new LatLng(location.getLatitude(), location.getLongitude()));

mp.title("my position");

}

@Override
public void onProviderDisabled(String provider) {
// TODO Auto-generated method stub

}

@Override
public void onProviderEnabled(String provider) {
// TODO Auto-generated method stub

}

@Override
public void onStatusChanged(String provider, int status, Bundle extras) {
// TODO Auto-generated method stub

```