Code example for Marker

Methods: remove

0
		m3 = map.addMarker(new MarkerOptions()
		    	.position(c3)
		    	.draggable(true).icon(BitmapDescriptorFactory.defaultMarker(BitmapDescriptorFactory.HUE_BLUE)));
 
		// Bottom right marker 
		if (m4 != null) m4.remove();
		m4 = map.addMarker(new MarkerOptions()
		    	.position(c4)
		    	.draggable(true).icon(BitmapDescriptorFactory.defaultMarker(BitmapDescriptorFactory.HUE_YELLOW)));
	} 
	 
	private class GeocoderTask extends AsyncTask<String, Void, List<Address>>{
 
	        @Override 
	        protected List<Address> doInBackground(String... locationName) {
	            // Creating an instance of Geocoder class 
	            Geocoder geocoder = new Geocoder(getBaseContext());
	            List<Address> addresses = null;
 
	            try { 
	                // Getting a maximum of 3 Address that matches the input text