package de.eightbitboy.hijacr.data.database;

import android.content.Context;

import de.eightbitboy.hijacr.data.database.ComicDatabase;

/**
 * A helper class for working with the ComicDatabse class.
 */
public class ComicDatabaseHelper {
	private ComicDatabase database;

	public ComicDatabaseHelper(Context context) {
		database = ComicDatabase.getInstance(context);
	}

	public String getProgressUrl(String key) {
		//TODO
		return null;
	}

	public int getProgressNumber(int id) {
		return database.getProgressNumber(id);
	}

	public void setProgressUrl(int id, String progressUrl) {
		database.insert(id, progressUrl, 0);
	}

	public void setProgressNumber(int id, int progressNumber) {
		database.insert(id, "", progressNumber);
	}
}

@@ -76,67 +76,8 @@
 t;%0A%0A
-import de.eightbitboy.hijacr.data.database.ComicDatabase;%0A%0A
 /**%0A
@@ -125,16 +125,17 @@
 micDatab
+a
 se class
@@ -343,44 +343,54 @@
 Url(
-String key) %7B%0A%09%09//TODO%0A%09%09return null
+int id) %7B%0A%09%09return database.getProgressUrl(id)
 ;%0A%09%7D
@@ -634,24 +634,67 @@
 ssNumber) %7B%0A
+%09%09//TODO use null instead of empty string?%0A
 %09%09database.i

Fix database helper