Code example for SparseArray

Methods: remove

0
	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);
			if (msg.arg2 >= 0) {
				Task t = RepositoryService.this.getTask(msg.arg2);
				if (t != null)
Contextual code suggestions in your IDE  Get Codota for Java