import java.util.Date;
import static android.view.View.GONE;
-import static net.ktnx.mobileledger.MobileLedgerDB.db;
import static net.ktnx.mobileledger.MobileLedgerDB.set_option_value;
public class AccountSummary extends AppCompatActivity {
};
task.setPref(PreferenceManager.getDefaultSharedPreferences(this));
- task.execute(db);
+ task.execute();
}
}
package net.ktnx.mobileledger;
import android.content.SharedPreferences;
-import android.database.sqlite.SQLiteDatabase;
import android.util.Log;
import java.io.BufferedReader;
import java.util.regex.Matcher;
import java.util.regex.Pattern;
-abstract public class RetrieveAccountsTask extends android.os.AsyncTask<SQLiteDatabase, Integer, Void> {
+import static net.ktnx.mobileledger.MobileLedgerDB.db;
+
+abstract public class RetrieveAccountsTask extends android.os.AsyncTask<Void, Integer, Void> {
int error;
private SharedPreferences pref;
error = 0;
}
- protected Void doInBackground(SQLiteDatabase... sqLiteDatabases) {
- final SQLiteDatabase db = sqLiteDatabases[0];
+ protected Void doInBackground(Void... params) {
try {
HttpURLConnection http = NetworkUtil.prepare_connection( pref, "add");
http.setAllowUserInteraction(false);