117 lines
3.8 KiB
Java
117 lines
3.8 KiB
Java
package com.discord.widgets.chat.input;
|
|
|
|
import c.d.b.a.a;
|
|
import com.discord.api.sticker.Sticker;
|
|
import com.discord.utilities.mg_recycler.MGRecyclerDataPayload;
|
|
import d0.z.d.m;
|
|
import kotlin.jvm.internal.DefaultConstructorMarker;
|
|
/* compiled from: WidgetChatInputAutocompleteStickerAdapter.kt */
|
|
public final class AutocompleteStickerItem implements MGRecyclerDataPayload {
|
|
public static final Companion Companion = new Companion(null);
|
|
public static final int TYPE = 0;
|
|
private final String key;
|
|
private final Sticker sticker;
|
|
private final int type;
|
|
|
|
/* compiled from: WidgetChatInputAutocompleteStickerAdapter.kt */
|
|
public static final class Companion {
|
|
private Companion() {
|
|
}
|
|
|
|
public /* synthetic */ Companion(DefaultConstructorMarker defaultConstructorMarker) {
|
|
this();
|
|
}
|
|
}
|
|
|
|
public AutocompleteStickerItem(Sticker sticker, String str, int i) {
|
|
m.checkNotNullParameter(sticker, "sticker");
|
|
m.checkNotNullParameter(str, "key");
|
|
this.sticker = sticker;
|
|
this.key = str;
|
|
this.type = i;
|
|
}
|
|
|
|
/* JADX INFO: this call moved to the top of the method (can break code semantics) */
|
|
public /* synthetic */ AutocompleteStickerItem(Sticker sticker, String str, int i, int i2, DefaultConstructorMarker defaultConstructorMarker) {
|
|
this(sticker, (i2 & 2) != 0 ? String.valueOf(sticker.getId()) : str, (i2 & 4) != 0 ? 0 : i);
|
|
}
|
|
|
|
public static /* synthetic */ AutocompleteStickerItem copy$default(AutocompleteStickerItem autocompleteStickerItem, Sticker sticker, String str, int i, int i2, Object obj) {
|
|
if ((i2 & 1) != 0) {
|
|
sticker = autocompleteStickerItem.sticker;
|
|
}
|
|
if ((i2 & 2) != 0) {
|
|
str = autocompleteStickerItem.getKey();
|
|
}
|
|
if ((i2 & 4) != 0) {
|
|
i = autocompleteStickerItem.getType();
|
|
}
|
|
return autocompleteStickerItem.copy(sticker, str, i);
|
|
}
|
|
|
|
public final Sticker component1() {
|
|
return this.sticker;
|
|
}
|
|
|
|
public final String component2() {
|
|
return getKey();
|
|
}
|
|
|
|
public final int component3() {
|
|
return getType();
|
|
}
|
|
|
|
public final AutocompleteStickerItem copy(Sticker sticker, String str, int i) {
|
|
m.checkNotNullParameter(sticker, "sticker");
|
|
m.checkNotNullParameter(str, "key");
|
|
return new AutocompleteStickerItem(sticker, str, i);
|
|
}
|
|
|
|
public boolean equals(Object obj) {
|
|
if (this == obj) {
|
|
return true;
|
|
}
|
|
if (!(obj instanceof AutocompleteStickerItem)) {
|
|
return false;
|
|
}
|
|
AutocompleteStickerItem autocompleteStickerItem = (AutocompleteStickerItem) obj;
|
|
return m.areEqual(this.sticker, autocompleteStickerItem.sticker) && m.areEqual(getKey(), autocompleteStickerItem.getKey()) && getType() == autocompleteStickerItem.getType();
|
|
}
|
|
|
|
@Override // com.discord.utilities.mg_recycler.MGRecyclerDataPayload, com.discord.utilities.recycler.DiffKeyProvider
|
|
public String getKey() {
|
|
return this.key;
|
|
}
|
|
|
|
public final Sticker getSticker() {
|
|
return this.sticker;
|
|
}
|
|
|
|
@Override // com.discord.utilities.mg_recycler.MGRecyclerDataPayload
|
|
public int getType() {
|
|
return this.type;
|
|
}
|
|
|
|
public int hashCode() {
|
|
Sticker sticker = this.sticker;
|
|
int i = 0;
|
|
int hashCode = (sticker != null ? sticker.hashCode() : 0) * 31;
|
|
String key = getKey();
|
|
if (key != null) {
|
|
i = key.hashCode();
|
|
}
|
|
return getType() + ((hashCode + i) * 31);
|
|
}
|
|
|
|
public String toString() {
|
|
StringBuilder L = a.L("AutocompleteStickerItem(sticker=");
|
|
L.append(this.sticker);
|
|
L.append(", key=");
|
|
L.append(getKey());
|
|
L.append(", type=");
|
|
L.append(getType());
|
|
L.append(")");
|
|
return L.toString();
|
|
}
|
|
}
|