This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| https://medium.com/@artem_zin/m-model-from-mvc-mvp-in-android-flow-and-mortar-bd1e50c45395#.fx16i7o50 | |
| http://magenic.com/Blog/Post/6/An-MVP-Pattern-for-Android | |
| https://medium.com/ribot-labs/approaching-android-with-mvvm-8ceec02d5442#.pkip2bkyo | |
| http://fernandocejas.com/2014/09/03/architecting-android-the-clean-way/ | |
| http://hannesdorfmann.com/android/mosby/ | |
| https://plus.google.com/communities/114285790907815804707 | |
| http://programmers.stackexchange.com/questions/133134/is-model-view-presenter-mvp-scheme-useful-for-android |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| http://stackoverflow.com/questions/27036933/how-to-set-up-dagger-dependency-injection-from-scratch-in-android-project | |
| http://siphon9.net/loune/2015/04/dagger-2-0-android-migration-tips/ | |
| https://github.com/google/dagger/issues/107#issuecomment-71524636 | |
| https://github.com/square/dagger/issues/379 | |
| http://code.tutsplus.com/tutorials/dependency-injection-with-dagger-2-on-android--cms-23345 | |
| https://github.com/joesteele/dagger2-component-scopes-test/blob/master/app/src/main/java/net/joesteele/daggercomponentstest/MainActivity.java | |
| http://frogermcs.github.io/dagger-1-to-2-migration/ | |
| https://github.com/google/dagger/tree/master/examples/android-activity-graphs | |
| https://speakerdeck.com/ogaclejapan/dagger2-has-been-released |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Guide for Dagger 2.0 (Revised Edition 5): | |
| The steps are the following: | |
| 1.) add Dagger to your build.gradle files: | |
| top level build.gradle: | |
| . | |
| // Top-level build file where you can add configuration options common to all sub-projects/modules. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| How ButterKnife actually works? | |
| Java Annotation Processing | |
| Annotation processing is a tool build in javac for scanning and processing annotations at compile time. | |
| You can define your own annotations and a custom processor to handle them. | |
| Annotations are scanned and processed at compile time. | |
| An Annotation Processor reads java code, process its annotations and generate java code in response. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| http://source.android.com/source/index.html |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import com.android.volley.toolbox.HurlStack; | |
| import com.squareup.okhttp.OkHttpClient; | |
| import java.io.IOException; | |
| import java.net.HttpURLConnection; | |
| import java.net.URL; | |
| /** | |
| * An {@link com.android.volley.toolbox.HttpStack HttpStack} implementation which | |
| * uses OkHttp as its transport. | |
| */ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /* | |
| When we do a longer running async operation that returns the callback on an Activity | |
| like | |
| Asynctask<T,U, K> | |
| AsyncTask is only for operations between the background thread and Main UI Thread. | |
| the methods are | |
| void onPreExecute(){} | |
| K doInBackground(T type1){ | |
| .. | |
| return type3_Object; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /* | |
| * Copyright (C) 2013 Square, 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 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| public class MyClass{ | |
| private volatile MyClass myClassObject; | |
| public MyClass getInstance(){ | |
| MyClass helper = myClassObject; | |
| // Optimisation for getting instance, if the helper has already been initialised return that. | |
| if(helper == null){ | |
| synchronised(MyClass.this){ | |
| // Since synchronised block takes some time to initialise ,in the mean time another thread might have entered | |
| // the synchronised block and initialised the helper variable. By ensuring that the myclassObject is volatile, we have established | |
| // a happens-before functionality on the myClassObject. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /etc/profile | |
| ~/.bash_profile | |
| ~/.bash_login | |
| ~/.profile |