pawel.rybicki
05/02/2017, 1:38 PMlazy
delegate?louiscad
05/02/2017, 3:28 PMyan
05/02/2017, 7:01 PMjw
05/02/2017, 9:03 PMcontinue@for
trevjones
05/02/2017, 11:50 PMjohnl
05/03/2017, 12:22 AMadinugroho
05/03/2017, 7:14 AMvyacheslav.gerasimov
05/03/2017, 7:56 AM--debug --stacktrace
and give me output?
@adinugroho @zkvarzDaniel
05/03/2017, 12:26 PMkirillrakhman
05/03/2017, 2:15 PMpublic class DataClass {
private final String a;
private final int b;
public DataClass(final String a, final int b) {
this.a = a;
this.b = b;
}
public String getA() {
return a;
}
public int getB() {
return b;
}
@Override
public boolean equals(final Object o) {
if (this == o)
return true;
if (o == null || getClass() != o.getClass())
return false;
DataClass dataClass = (DataClass) o;
if (b != dataClass.b)
return false;
return a != null ? a.equals(dataClass.a) : dataClass.a == null;
}
@Override
public int hashCode() {
int result = a != null ? a.hashCode() : 0;
result = 31 * result + b;
return result;
}
}
is converted to
class DataClass(val a: String?, val b: Int) {
override fun equals(o: Any?): Boolean {
if (this === o)
return true
if (o == null || javaClass != o.javaClass)
return false
val dataClass = o as DataClass?
if (b != dataClass!!.b)
return false
return if (a != null) a == dataClass.a else dataClass.a == null
}
override fun hashCode(): Int {
var result = a?.hashCode() ?: 0
result = 31 * result + b
return result
}
}
you just have to add the data
modifier and remove equals
and hashCode
yourselfDaniel
05/03/2017, 5:36 PMaphex
05/03/2017, 9:29 PMPaul Woitaschek
05/04/2017, 9:34 AMlouiscad
05/04/2017, 2:17 PMmg6maciej
05/04/2017, 2:20 PMlist
.vyacheslav.gerasimov
05/05/2017, 3:40 PMaphex
05/06/2017, 12:22 AM@Inject @MainThreadScheduler lateinit var scheduler : Scheduler
✅ @field:Inject @field:MainThreadScheduler lateinit var scheduler : Scheduler
koufa
05/06/2017, 10:27 AMkirillrakhman
05/08/2017, 12:22 PMnebojsa.vuksic
05/08/2017, 2:29 PM"IllegalIdentifier"
warning when I use spaces in function naming. Is there any way to fix this without suppressing this warning ?
Thanks in advance.david.bilik
05/09/2017, 10:51 AMvar products: List<Product> = listOf()
set(value) {
field = value
notifyDatasetChanged()
}
and I think that I can use delegated properties with some syntax like var products: List<ApiProduct> by adapterProperty(initialValue = listOf())
but I dont have such experience with themmichaelsims
05/09/2017, 1:57 PMandre.figas
05/09/2017, 2:40 PMPaul Woitaschek
05/09/2017, 8:33 PMDaniel
05/09/2017, 11:30 PMfun ViewGroup.addHiddenView(view: View) {
view.visibility = GONE
addView(view)
}
marcinmoskala
05/10/2017, 9:16 AMPaul Woitaschek
05/10/2017, 2:02 PMs.luhmirins
05/10/2017, 2:24 PMgonzalonm
05/11/2017, 12:45 PMext.kotlin_version
to 1.1.2-2 and that message disappeared.audhil
05/12/2017, 10:37 AMaudhil
05/12/2017, 10:37 AMlouiscad
05/12/2017, 12:17 PMaudhil
05/12/2017, 12:38 PMfirezenk
05/12/2017, 1:48 PMcurioustechizen
05/12/2017, 1:51 PMbenleggiero
05/12/2017, 11:15 PMdariuszbacinski
05/13/2017, 1:27 PMbenleggiero
05/13/2017, 1:37 PM