Code example for WeakReference

Methods: clear

0
			super.onCancelled(); 
		} 
		 
		protected void cleanup() 
		{ 
			this.viewHolderReference.clear();
		} 
 
		@Override 
		protected void onPreExecute() { 
			if(!isOnline()) 
			{ 
				this.cancel(false);
				safeUpdateStatus(IMAGE_STATUS_NO_CONNECTION);
			} 
		} 
 
		@Override 
		protected Bitmap doInBackground(Object... params) {
			 
			String url = (String) params[0];