yongjhih / kotlin-database

[Deprecated]

Home Page:https://github.com/yongjhih/kotlin-android-extensions

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

kotlin-database

JitPack javadoc Build Status Join the chat at https://gitter.im/yongjhih/kotlin-database

Usage

Before:

db.beginTransaction();
try {
  db.delete("users", "first_name = ?", new String[] { "Andrew" });
  db.setTransactionSuccessful();
} finally {
  db.endTransaction()
}

or

Databases.from(db).inTransaction(it -> {
  it.delete("users", "first_name = ?", new String[] { "Andrew" });
});

After:

db.inTransation {
  delete("users", "first_name = ?", arrayOf("Andrew"))
}

Installation

jcenter:

dependencies {
    compile 'com.infstory:kotlin-database:1.0.0'
}

jitpack:

repositories {
    // ...
    maven { url "https://jitpack.io" }
}
dependencies {
    compile 'com.github.yongjhih:kotlin-database:-SNAPSHOT'
}

License

Copyright 2015 8tory, Inc.

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

    http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.

About

[Deprecated]

https://github.com/yongjhih/kotlin-android-extensions

License:Apache License 2.0


Languages

Language:Kotlin 86.9%Language:Java 13.1%