Skip to content

Instantly share code, notes, and snippets.


Mike Drabic mdrabic

  • Levvel
  • Charlotte, NC
View GitHub Profile
mdrabic /
Created Nov 5, 2013
The Bundle holds Key<String> Value<Parcelable> pairs and provides convenience methods for several of the primitive wrapper types such as Short, Byte, Integer, etc. In the event your data does not easily fit into one of these methods, you can implement the Parcelable interface and use Bundle.putParcelable(key,value).
import android.os.Parcel;
import android.os.Parcelable;
import java.util.ArrayList;
import java.util.List;
* POJO to hold contents of a Mail. Implements Parcelable so that it can be used in the bundle to
* save and restore information to the UI entered by the user in a Activity.
mdrabic / build.gradle
Last active Dec 29, 2015
build.gradle template
View build.gradle
apply plugin: ''
// Manifest version information!
def versionMajor = 1
def versionMinor = 0
def versionPatch = 0
def versionBuild = 0 // bump for dogfood builds, public betas, etc.
def gitSha = 'git rev-parse --short HEAD'.execute([], project.rootDir).text.trim()
def buildTime = new Date().format("yyyy-MM-dd'T'HH:mm'Z'", TimeZone.getTimeZone("UTC"))
mdrabic /
Created Nov 27, 2013
An abstract generic loader that can be used to fetch data from a sqlite database. It handles the database connection and delivering of results to any class that implements LoaderCallbacks. It is up to the child class to implement doInBackground(...) thus allowing the child to decide what data to load. This class does have a dependency to the Gre…
package com.mdrabic.content;
import android.content.Context;
import android.database.sqlite.SQLiteDatabase;
mdrabic /
Created Jun 24, 2014
rxjava worker thread example
final Scheduler.Worker worker = Schedulers.newThread().createWorker();
worker.schedule(new Action0() {
public void call() {
if (!mAnimationSet.isStarted()) {
} else {
worker.schedule(this, 500, TimeUnit.MILLISECONDS);
mdrabic /
Last active Jun 24, 2016 — forked from yanofsky/
A script to download all of a user's tweets into a csv
#!/usr/bin/env python
# encoding: utf-8
import tweepy #
#Twitter API credentials
consumer_key = ""
consumer_secret = ""
access_key = ""
access_secret = ""

Keybase proof

I hereby claim:

  • I am mdrabic on github.
  • I am mikedrabic ( on keybase.
  • I have a public key ASCFtkllKmnti-M7c7wlSvSiWnlT2upDTXRG6yh-TpkMDQo

To claim this, I am signing this object: