droitatedDB


Source link: https://github.com/arconsis/droitatedDB

#droitatedDB

The name

droitatedDB is a shortened version of Android annotated DB.

An droid anno tated DB

The result is droitatedDB

At a glance

droitatedDB is a lightweight framework, which frees you from the burden of dealing with the Android SQLite database directly if you don't want to but lets you access it directly if you need to.

With an annotation based approach you are able to get a database up and running in no time. Simply annotate your data classes and let droitatedDB do the work.

Features

  • Annotation based implementation
  • No hard coded Strings in your code
  • Code generation for the ceremonial tasks
  • Compile time protection when renaming fields or tables
  • Fall back to Android default API is always possible

Download

Add the android-apt plugin to your project-level build.gradle:

buildscript {

repositories {

  mavenCentral()
 
}

dependencies {

  classpath 'com.neenbedankt.gradle.plugins:android-apt:1.8'

}
 
}

After that, apply inside your module-level build.gradle the android-apt plugin and add droitatedDB dependencies:

apply plugin: 'android-apt'  apt {

arguments {

  manifest variant.outputs[0]?.processResources?.manifestFile

}
 
}
  dependencies {

apt 'org.droitateddb:processor:0.1.9'
compile 'org.droitateddb:api:0.1.9' 
}

How do I use DroitatedDb?

For the full Tutorial check out our Wiki here: Tutorial
First we need to create our database:

@Update @Persistence(dbName = "my_database.db", dbVersion = 1) public class PersistenceConfig implements DbUpdate {

  @Override
  public void onUpdate(SQLiteDatabase db, int oldVersion, int newVersion) {

// here you can put your update code, when changing the database version
  
}
 
}

After that we can create our first entitiy:

@Entity public class User {

  @PrimaryKey
 @AutoIncrement
 @Column
 private Integer _id;
 @Column
 private String name;
public User() {

//droitatedDB needs an empty constructor  
}

  public User(String name) {

this.name = name;
 
}

  //... 
}

Now we can store data:

EntityService userService = new EntityService(context, User.class);
 userService.save(new User("Bob"));

And read data:

EntityService userService = new EntityService(context, User.class);
 List<User> allUsers = userService.get();

Documentation

Check out the documentation and introduction here

JavaDocs

Get into the API details reading the technical API

Release notes

Check out the release notes, to see what's new in droitatedDB

Resources

This Layout provide fling dismiss effect like Twitter ImageView

A custom layout that fills given width or height as per the original ratio of each child.

If given width or height is exceeded, it largely replicates the behavior of LinearLayout.

What RatioFillLayout offers:

  • Orientation: horizontal, vertical
  • Gravity: top, bottom, left, right, centerhorizontal, centervertical

What is iSortBox? Just like what it says: Simplify sorting!

This framework achieves a goal which makes sorting easier, moreover, you will benefit from what it provides such as pre-processing, converting, grouping and filtering.

As the name iSortBox, the letter 'i' means input and the letter 'o' means output, as for the details on how to complete the work, all are encapsulated in iSortBox.

Android Gradle plugin generates App Shortcuts shortcuts.xml for build flavors with different applicationId.

When it useful?

If you look at the official documentation of static App Shortcuts, you'll see that for each intent you need to set the android:targetPackage. But, what if you have different applicationId in different flavors?

In this case, you'll need copy your shortcuts.xml in two folder dev and prod with single difference. And if you create a new flavor with different applicationId you need to copy it again. Since at this moment we do not have any built-in merge tools applicationId from build.gradle to the shortcuts.xml this gradle plugin will be useful.

Starter boilerplate projects for Android, with Components Architecture implemented, written completely in Kotlin. Variations include Rx, Realm & Dagger usage.

Neuronizer offers the opportunity to order your thoughts, ideas and tasks in categories to recognise the information you need as fast as possible.

Features

  • Add, remove and update notes
  • Add, remove and update ToDo lists
  • Sort everything as you wish
  • Designed for simple and fast usage
  • Encrypted storage of data, on device only
  • Create widgets
  • Categorisation in ToDo lists
  • Mark tasks as done
  • Add details to each task
  • Share ToDo lists

Topics


2D Engines   3D Engines   9-Patch   Action Bars   Activities   ADB   Advertisements   Analytics   Animations   ANR   AOP   API   APK   APT   Architecture   Audio   Autocomplete   Background Processing   Backward Compatibility   Badges   Bar Codes   Benchmarking   Bitmaps   Bluetooth   Blur Effects   Bread Crumbs   BRMS   Browser Extensions   Build Systems   Bundles   Buttons   Caching   Camera   Canvas   Cards   Carousels   Changelog   Checkboxes   Cloud Storages   Color Analysis   Color Pickers   Colors   Comet/Push   Compass Sensors   Conferences   Content Providers   Continuous Integration   Crash Reports   Credit Cards   Credits   CSV   Curl/Flip   Data Binding   Data Generators   Data Structures   Database   Database Browsers   Date &   Debugging   Decompilers   Deep Links   Dependency Injections   Design   Design Patterns   Dex   Dialogs   Distributed Computing   Distribution Platforms   Download Managers   Drawables   Emoji   Emulators   EPUB   Equalizers &   Event Buses   Exception Handling   Face Recognition   Feedback &   File System   File/Directory   Fingerprint   Floating Action   Fonts   Forms   Fragments   FRP   FSM   Functional Programming   Gamepads   Games   Geocaching   Gestures   GIF   Glow Pad   Gradle Plugins   Graphics   Grid Views   Highlighting   HTML   HTTP Mocking   Icons   IDE   IDE Plugins   Image Croppers   Image Loaders   Image Pickers   Image Processing   Image Views   Instrumentation   Intents   Job Schedulers   JSON   Keyboard   Kotlin   Layouts   Library Demos   List View   List Views   Localization   Location   Lock Patterns   Logcat   Logging   Mails   Maps   Markdown   Mathematics   Maven Plugins   MBaaS   Media   Menus   Messaging   MIME   Mobile Web   Native Image   Navigation   NDK   Networking   NFC   NoSQL   Number Pickers   OAuth   Object Mocking   OCR Engines   OpenGL   ORM   Other Pickers   Parallax List   Parcelables   Particle Systems   Password Inputs   PDF   Permissions   Physics Engines   Platforms   Plugin Frameworks   Preferences   Progress Indicators   ProGuard   Properties   Protocol Buffer   Pull To   Purchases   Push/Pull   QR Codes   Quick Return   Radio Buttons   Range Bars   Ratings   Recycler Views   Resources   REST   Ripple Effects   RSS   Screenshots   Scripting   Scroll Views   SDK   Search Inputs   Security   Sensors   Services   Showcase Views   Signatures   Sliding Panels   Snackbars   SOAP   Social Networks   Spannable   Spinners   Splash Screens   SSH   Static Analysis   Status Bars   Styling   SVG   System   Tags   Task Managers   TDD &   Template Engines   Testing   Testing Tools   Text Formatting   Text Views   Text Watchers   Text-to   Toasts   Toolkits For   Tools   Tooltips   Trainings   TV   Twitter   Updaters   USB   User Stories   Utils   Validation   Video   View Adapters   View Pagers   Views   Watch Face   Wearable Data   Wearables   Weather   Web Tools   Web Views   WebRTC   WebSockets   Wheel Widgets   Wi-Fi   Widgets   Windows   Wizards   XML   XMPP   YAML   ZIP Codes