nikbucher
06/01/2017, 12:52 PMkailan
06/01/2017, 1:03 PM/**
* Subscribe to notifications of a certain type, specifying a priority.
*/
inline fun <reified T : Any> Match.subscribe(vararg states: Match.State, priority: Int, noinline notifier: T.() -> Unit) {
subscribe(StatefulTypedSubscription(this, states, T::class, notifier, priority))
}
kailan
06/01/2017, 1:03 PMmkodekar
06/01/2017, 9:49 PMI Gede Tirtanata
06/02/2017, 3:15 AMmolikto
06/02/2017, 3:48 AMjw
06/02/2017, 3:51 AMnatpryce
06/02/2017, 2:03 PMlovis
06/02/2017, 2:25 PMreified
will be private from Java? 🤔
inline fun <reified T> findInputValueByHint(hintToFind: String): T? {
val inputField = inputFields.find { field -> field.hint == hintToFind }
return inputField?.getInputValue() as? T
}
can’t be accessed through java code. (although only public members are used)
Error:(91, 35) error: <T>findInputValueByHint(String) has private access in InputGroup
where T is a type-variable:
T extends Object declared in method <T>findInputValueByHint(String)
or am I missing something here?lovis
06/02/2017, 2:34 PMfernandocortez
06/02/2017, 3:38 PMalexreidy
06/02/2017, 4:53 PMalexreidy
06/02/2017, 5:03 PMalan.kleiman
06/02/2017, 6:11 PMalan.kleiman
06/02/2017, 6:42 PMdata class Thing(private val data: ByteArray) {
val copy = Arrays.copyOf(data, data.size)
}
Even if I use copy
exclusively, I'm still holding a reference to data
minivac
06/02/2017, 7:28 PMminivac
06/02/2017, 7:35 PMdnvshp
06/02/2017, 8:26 PMbj0
06/02/2017, 9:21 PMval
in the constructor if you don't want to keep a reference to itdiesieben07
06/02/2017, 9:31 PMmkodekar
06/02/2017, 9:35 PMbod
06/02/2017, 9:39 PMerror.NonExistentClass
in generated code with kapt3.bod
06/02/2017, 9:39 PMmkodekar
06/02/2017, 9:41 PMbod
06/02/2017, 9:43 PMbod
06/02/2017, 9:57 PMkapt {
correctErrorTypes = true
}
as per the kapt doc 😉bod
06/02/2017, 9:58 PMhughg
06/03/2017, 11:01 AMbrumla
06/04/2017, 6:05 AMramsrib
06/04/2017, 6:32 AMNo session currently bound to execution context
when i’m accessing the DAO classes from main app class.