159 lines
5.0 KiB
Java
159 lines
5.0 KiB
Java
package com.discord.widgets.directories;
|
|
|
|
import androidx.annotation.StringRes;
|
|
import b.d.b.a.a;
|
|
import d0.z.d.m;
|
|
import kotlin.jvm.internal.DefaultConstructorMarker;
|
|
/* compiled from: WidgetDirectoryEntryViewHolder.kt */
|
|
/* loaded from: classes2.dex */
|
|
public abstract class DirectoryChannelItem {
|
|
private final ViewType viewType;
|
|
|
|
/* compiled from: WidgetDirectoryEntryViewHolder.kt */
|
|
/* loaded from: classes2.dex */
|
|
public static final class AddServer extends DirectoryChannelItem {
|
|
public static final AddServer INSTANCE = new AddServer();
|
|
|
|
private AddServer() {
|
|
super(ViewType.AddServer, null);
|
|
}
|
|
}
|
|
|
|
/* compiled from: WidgetDirectoryEntryViewHolder.kt */
|
|
/* loaded from: classes2.dex */
|
|
public static final class DirectoryItem extends DirectoryChannelItem {
|
|
private final DirectoryEntryData directoryEntryData;
|
|
|
|
/* JADX WARN: 'super' call moved to the top of the method (can break code semantics) */
|
|
public DirectoryItem(DirectoryEntryData directoryEntryData) {
|
|
super(ViewType.Item, null);
|
|
m.checkNotNullParameter(directoryEntryData, "directoryEntryData");
|
|
this.directoryEntryData = directoryEntryData;
|
|
}
|
|
|
|
public static /* synthetic */ DirectoryItem copy$default(DirectoryItem directoryItem, DirectoryEntryData directoryEntryData, int i, Object obj) {
|
|
if ((i & 1) != 0) {
|
|
directoryEntryData = directoryItem.directoryEntryData;
|
|
}
|
|
return directoryItem.copy(directoryEntryData);
|
|
}
|
|
|
|
public final DirectoryEntryData component1() {
|
|
return this.directoryEntryData;
|
|
}
|
|
|
|
public final DirectoryItem copy(DirectoryEntryData directoryEntryData) {
|
|
m.checkNotNullParameter(directoryEntryData, "directoryEntryData");
|
|
return new DirectoryItem(directoryEntryData);
|
|
}
|
|
|
|
public boolean equals(Object obj) {
|
|
if (this != obj) {
|
|
return (obj instanceof DirectoryItem) && m.areEqual(this.directoryEntryData, ((DirectoryItem) obj).directoryEntryData);
|
|
}
|
|
return true;
|
|
}
|
|
|
|
public final DirectoryEntryData getDirectoryEntryData() {
|
|
return this.directoryEntryData;
|
|
}
|
|
|
|
public int hashCode() {
|
|
DirectoryEntryData directoryEntryData = this.directoryEntryData;
|
|
if (directoryEntryData != null) {
|
|
return directoryEntryData.hashCode();
|
|
}
|
|
return 0;
|
|
}
|
|
|
|
public String toString() {
|
|
StringBuilder R = a.R("DirectoryItem(directoryEntryData=");
|
|
R.append(this.directoryEntryData);
|
|
R.append(")");
|
|
return R.toString();
|
|
}
|
|
}
|
|
|
|
/* compiled from: WidgetDirectoryEntryViewHolder.kt */
|
|
/* loaded from: classes2.dex */
|
|
public static final class SectionHeader extends DirectoryChannelItem {
|
|
private final int textRes;
|
|
|
|
public SectionHeader(@StringRes int i) {
|
|
super(ViewType.SectionHeader, null);
|
|
this.textRes = i;
|
|
}
|
|
|
|
public static /* synthetic */ SectionHeader copy$default(SectionHeader sectionHeader, int i, int i2, Object obj) {
|
|
if ((i2 & 1) != 0) {
|
|
i = sectionHeader.textRes;
|
|
}
|
|
return sectionHeader.copy(i);
|
|
}
|
|
|
|
public final int component1() {
|
|
return this.textRes;
|
|
}
|
|
|
|
public final SectionHeader copy(@StringRes int i) {
|
|
return new SectionHeader(i);
|
|
}
|
|
|
|
public boolean equals(Object obj) {
|
|
if (this != obj) {
|
|
return (obj instanceof SectionHeader) && this.textRes == ((SectionHeader) obj).textRes;
|
|
}
|
|
return true;
|
|
}
|
|
|
|
public final int getTextRes() {
|
|
return this.textRes;
|
|
}
|
|
|
|
public int hashCode() {
|
|
return this.textRes;
|
|
}
|
|
|
|
public String toString() {
|
|
return a.A(a.R("SectionHeader(textRes="), this.textRes, ")");
|
|
}
|
|
}
|
|
|
|
/* compiled from: WidgetDirectoryEntryViewHolder.kt */
|
|
/* loaded from: classes2.dex */
|
|
public enum ViewType {
|
|
Item,
|
|
AddServer,
|
|
SectionHeader;
|
|
|
|
public static final Companion Companion = new Companion(null);
|
|
|
|
/* compiled from: WidgetDirectoryEntryViewHolder.kt */
|
|
/* loaded from: classes2.dex */
|
|
public static final class Companion {
|
|
private Companion() {
|
|
}
|
|
|
|
public /* synthetic */ Companion(DefaultConstructorMarker defaultConstructorMarker) {
|
|
this();
|
|
}
|
|
|
|
public final ViewType findType(int i) {
|
|
return ViewType.values()[i];
|
|
}
|
|
}
|
|
}
|
|
|
|
private DirectoryChannelItem(ViewType viewType) {
|
|
this.viewType = viewType;
|
|
}
|
|
|
|
public /* synthetic */ DirectoryChannelItem(ViewType viewType, DefaultConstructorMarker defaultConstructorMarker) {
|
|
this(viewType);
|
|
}
|
|
|
|
public final ViewType getViewType() {
|
|
return this.viewType;
|
|
}
|
|
}
|