com.j256.ormlite.android.apptools.OrmLiteSqliteOpenHelper Java Examples

The following examples show how to use com.j256.ormlite.android.apptools.OrmLiteSqliteOpenHelper. You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example #1
Source File: RockyDao.java    From android-project-wo2b with Apache License 2.0 5 votes vote down vote up
/**
 * 构造函数
 * 
 * @param helper
 */
@SuppressWarnings("unchecked")
public RockyDao(OrmLiteSqliteOpenHelper sqliteOpenHelper)
{
	// this.mOpenHelper = SdkDbHelper.getDatabaseHelper(context);

	this.mSqliteOpenHelper = sqliteOpenHelper;
	Class<Model> modelClass = (Class<Model>) ((ParameterizedType) getClass().getGenericSuperclass())
			.getActualTypeArguments()[0];
	mRuntimeDao = mSqliteOpenHelper.getRuntimeExceptionDao(modelClass);
}
 
Example #2
Source File: OrmLiteBaseAppCompatActivity.java    From Walrus with GNU General Public License v3.0 4 votes vote down vote up
public OrmLiteBaseAppCompatActivity(Class<? extends OrmLiteSqliteOpenHelper> helperClass) {
    this.helperClass = helperClass;
}
 
Example #3
Source File: GameRankingBiz.java    From android-project-wo2b with Apache License 2.0 4 votes vote down vote up
public GameRankingBiz(OrmLiteSqliteOpenHelper sqliteOpenHelper)
{
	super(sqliteOpenHelper);
}
 
Example #4
Source File: SyncHelper.java    From DataSync with Apache License 2.0 4 votes vote down vote up
public SyncHelper(OrmLiteSqliteOpenHelper syncDatabaseHelper) {
    this.dbHelper = syncDatabaseHelper;
}
 
Example #5
Source File: DefaultProvider.java    From android-atleap with Apache License 2.0 4 votes vote down vote up
@Override
protected OrmLiteSqliteOpenHelper createHelper() {
    return new DefaultDatabaseHelper(getContext());
}
 
Example #6
Source File: TestProvider.java    From android-atleap with Apache License 2.0 4 votes vote down vote up
@Override
protected OrmLiteSqliteOpenHelper createHelper() {
    return new TestDatabaseHelper(getContext());
}
 
Example #7
Source File: BaseBiz.java    From android-project-wo2b with Apache License 2.0 2 votes vote down vote up
/**
 * 构造函数
 * 
 * @param helper
 */
public BaseBiz(OrmLiteSqliteOpenHelper helper)
{
	this.mOpenHelper = helper;
}
 
Example #8
Source File: BaseBiz.java    From android-project-wo2b with Apache License 2.0 2 votes vote down vote up
/**
 * 返回DatabaseHelper对象
 * 
 * @return
 */
public OrmLiteSqliteOpenHelper getDatabaseHelper()
{
	return mOpenHelper;
}
 
Example #9
Source File: RockyDao.java    From android-project-wo2b with Apache License 2.0 2 votes vote down vote up
/**
 * 返回OrmLiteSqliteOpenHelper对象
 * 
 * @return
 */
public OrmLiteSqliteOpenHelper getSqliteOpenHelper()
{
	return mSqliteOpenHelper;
}