Code example for LinkedHashMap

Methods: get, remove

0
	public DownloadEntry getEntry(String key) {
		return db.get(key);
	} 
	 
	public boolean removeEntry(String key) {
		DownloadEntry entry = db.get(key);
		if (entry == null) {
			return false; 
		} 
		 
		if (entry.state == State.downloading) {
			return false; 
		} 
		 
		db.remove(key);
		// TODO cancel download, delete tmp file, etc. 
		return true; 
	} 
	 
	public boolean startDownload(String key, String url, String completeFile) {
		if (db.get(key) != null) {