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
const GET_FLAVORED_ASSET_FUNCTION_NAME = "getFlavoredAsset" | |
module.exports = function ({types: t}) { | |
const isGetFlavoredAssetCall = (path) => | |
t.isIdentifier(path.node.callee, { | |
name: GET_FLAVORED_ASSET_FUNCTION_NAME, | |
}) && | |
((path.node.arguments.length === 1 && | |
t.isObjectExpression(path.node.arguments[0])) || | |
(path.node.arguments.length === 2 && |
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
class MapView: Fragment(), MapReadyListener, LocationFoundListener { | |
@Inject lateinit var mappable: Mappable | |
@Inject lateinit var runtimePermissions: Set<String> | |
override fun onCreate(savedInstanceState: Bundle?) { | |
super.onCreate(savedInstanceState) | |
checkPermissions(requireActivity()) | |
} | |
private fun checkPermissions(parentActivity: Activity) { |
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 {pipe} from "fp-ts/lib/pipeable" | |
import * as A from "fp-ts/lib/Array" | |
import * as T from "fp-ts/lib/Task" | |
const ids = await pipe( | |
someListings, | |
A.map(listing => { | |
return () => persistence.createListing(listing) | |
}), | |
A.array.sequence(T.task), |
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
package com.brantapps.oceanlife.domain.fixture; | |
import android.database.sqlite.SQLiteDatabase; | |
import android.database.sqlite.SQLiteOpenHelper; | |
import org.robolectric.RuntimeEnvironment; | |
/** | |
* In memory database for testing purposes. | |
* |
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
output = oceanlife-activity-fragment.graphml | |
classpath = ../../../OceanLife/app/build/intermediates/classes/withAmazon/debug/com/brantapps/oceanlife/ | |
# Don’t model dependencies | |
exclude = java*.** | |
exclude = android*.** | |
exclude = dagger*.** | |
exclude = rx*.** | |
exclude = okhttp*.** | |
exclude = org*.** |
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
package com.brantapps.oceanlife.activity; | |
import android.app.Activity; | |
import com.brantapps.oceanlife.analytics.aop.ScreenView; | |
import com.brantapps.oceanlife.analytics.event.Tags; | |
import com.brantapps.oceanlife.domain.activity.SplashActivity; | |
import com.brantapps.oceanlife.preference.activity.AboutActivity; | |
import com.brantapps.oceanlife.preference.activity.ApplicationPreferencesActivity; | |
import com.brantapps.oceanlife.preference.activity.DisclaimerActivity; |
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
Observable.zip( | |
Observable.from(spots), | |
Observable.interval(SYNC_TICK, TimeUnit.MILLISECONDS), | |
(obs, timer) -> obs) | |
.subscribeOn(scheduler) | |
.observeOn(scheduler) | |
.unsubscribeOn(scheduler) | |
.flatMap(spot -> syncTidePosition.get().buildObservable(spot)) | |
.subscribe(spotAndTideEvent -> new TideEventSubscriber( | |
lunaEventService, |