Code example for SparseArray

Methods: indexOfValue, remove

0
			this.waitingTasks.put(this.taskId, t);
		this.taskId++;
	} 
	 
	public void removeTask(Task t) {
		this.tasks.remove(this.tasks.indexOfValue(t));
	} 
	 
	public void removeTask(int id) {
		this.tasks.remove(id);
	} 
	 
	public Task getTask(int id) {
		return this.tasks.get(id);
	} 
 
	protected class ServiceHandler extends XMPPConsumerService.ServiceHandler { 
		 
		@Override 
		public void handleMessage(Message msg) {
			super.handleMessage(msg);