Skip to content
This repository has been archived by the owner on Nov 26, 2022. It is now read-only.

Commit

Permalink
Update ReadMe
Browse files Browse the repository at this point in the history
  • Loading branch information
deckyfx committed Aug 2, 2017
1 parent eb387aa commit def0013
Showing 1 changed file with 48 additions and 0 deletions.
48 changes: 48 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -1 +1,49 @@
# dbhelper
[![](https://jitpack.io/v/deckyfx/dbhelper.svg)](https://jitpack.io/#deckyfx/dbhelper)

Adapterview made easy

Add it in your root build.gradle at the end of repositories:

```gradle
allprojects {
repositories {
...
maven { url 'https://jitpack.io' }
}
}
```
Add the dependency

```gradle
dependencies {
compile 'org.greenrobot:greendao:3.2.0'
compile 'com.github.deckyfx:dbhelper:0.4'
}
```

## Usage
In your Activity / Application
```java
...
DBHelper DB = new DBHelper(getApplicationContext(), DaoMaster.class, "app.db");
...

```

```java
...
DBHelper.EntityMapWrapper entity = DB.getEntity(/* Entity Name */);
Property keyProperty = entity.getProperty("key");
Object settings = entity.queryBuilder().where(keyProperty.eq(key)).limit(1).list();
/* Or */
ArrayList<Object> list = entity.loadAll();
...

```

More sample is [here]

## Feature:

*

0 comments on commit def0013

Please sign in to comment.