Back to project page EnterpriseShow.
The source code is released under:
This is free and unencumbered software released into the public domain. Anyone is free to copy, modify, publish, use, compile, sell, or distribute this software, either in source code form or as a co...
If you think the Android project EnterpriseShow listed in this page is inappropriate, such as containing malicious code/tools or violating the copyright, please email info at java2s dot com, thanks.
package com.ruixinyuan.producttrainingfinal.db; /*from w w w .j a va2s . c o m*/ import android.content.Context; import android.database.sqlite.SQLiteDatabase; import android.database.sqlite.SQLiteOpenHelper; /* *@user vicentliu *@time 2013-6-18????5:17:04 *@package com.ruixinyuan.producttrainingfinal.db */ public class DownloadDBOpenHelper extends SQLiteOpenHelper { private static final String SQL_TABLE_DOWNLOADPICS_CREATE = "create table if not exists " + DBConstants.DOWNLOAD_TABLE_NAME + "(id integer primary key autoincrement," + "path varchar(100)," + "thread_id integer," + "downlength integer)"; private static final String SQL_TABLE_DOWNLOADPICS_DROP = "drop table if exists" + DBConstants.DOWNLOAD_TABLE_NAME; public DownloadDBOpenHelper(Context context) { super(context, DBConstants.DOWNLOAD_DB_NAME, null, DBConstants.DOWNLOAD_DB_VERSION); } @Override public void onCreate(SQLiteDatabase db) { db.execSQL(SQL_TABLE_DOWNLOADPICS_CREATE); } @Override public void onUpgrade(SQLiteDatabase db, int oldVersion, int newVersion) { db.execSQL(SQL_TABLE_DOWNLOADPICS_DROP); onCreate(db); } }