stangl0r
01/04/2017, 4:16 PMstangl0r
01/04/2017, 4:16 PMroberto.guerra
01/04/2017, 4:18 PMjavad
01/04/2017, 5:15 PMjavad
01/04/2017, 5:16 PMjavad
01/04/2017, 5:16 PM-keep class kotlin.Unit.** { *; }
jw
01/04/2017, 5:16 PMjw
01/04/2017, 5:17 PM.**
jw
01/04/2017, 5:17 PM**
in a proguard rule is almost never the correct thingjavad
01/04/2017, 5:17 PMjavad
01/04/2017, 5:18 PMjavad
01/04/2017, 5:19 PMjavad
01/04/2017, 5:19 PMjan.rabe
01/04/2017, 5:21 PMjan.rabe
01/04/2017, 5:25 PMjavad
01/04/2017, 5:36 PMjavad
01/04/2017, 5:53 PMmultifile
java class CollectionsKt
that holds the functions/methods (https://kotlinlang.org/docs/reference/java-to-kotlin-interop.html) (and as @jw mentioned use the class name without .** wildcard): -keep class kotlin.collections.CollectionsKt { *; }
skoude
01/04/2017, 6:40 PMrocketraman
01/04/2017, 6:42 PMrocketraman
01/04/2017, 6:42 PMprotected fun typedValue(untypedValue: Map<String, Any?>?): T? =
mapper.convertValue(untypedValue, klass.java)
protected fun typedList(untypedIterable: Iterable<Map<String, Any?>>): List<T> =
when(untypedIterable) {
is Cursor<Map<String, Any?>> -> untypedIterable.use { it.map { typedValue(it)!! } }
else -> untypedIterable.map { typedValue(it)!! }
}
protected fun typedSequence(untypedIterable: Iterable<Map<String, Any?>>): Sequence<T> =
when(untypedIterable) {
is Cursor<Map<String, Any?>> -> untypedIterable.use {
it.iterator().asSequence().map { typedValue(it)!! }
}
else -> error("Expected cursor")
}
skoude
01/04/2017, 6:45 PMrocketraman
01/04/2017, 6:46 PMrocketraman
01/04/2017, 6:47 PMOffsetDateTime
for date/time values. I created a "mini-mapping" framework to handle these conversions.evanchooly
01/04/2017, 6:47 PMskoude
01/04/2017, 6:48 PMrocketraman
01/04/2017, 6:49 PMskoude
01/04/2017, 6:51 PMrocketraman
01/04/2017, 6:54 PMskoude
01/04/2017, 7:07 PMnhaarman
01/04/2017, 7:28 PMnull
to an onNext
call. I can annotate the method in Intellij with null -> fail
, but that doesn't seem to do anything