Created
September 18, 2017 14:34
-
-
Save burntcookie90/254ee3ae6d3d45cd7eb6d0ff9e395b27 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class Foo(val id: String, val name: String, val count: Int?) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
data class FooData(val id: String, val name: String, val count: Int?) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public final class FooData { | |
@NotNull | |
private final String id; | |
@NotNull | |
private final String name; | |
@Nullable | |
private final Integer count; | |
@NotNull | |
public final String getId() { | |
return this.id; | |
} | |
@NotNull | |
public final String getName() { | |
return this.name; | |
} | |
@Nullable | |
public final Integer getCount() { | |
return this.count; | |
} | |
public FooData(@NotNull String id, @NotNull String name, @Nullable Integer count) { | |
Intrinsics.checkParameterIsNotNull(id, "id"); | |
Intrinsics.checkParameterIsNotNull(name, "name"); | |
super(); | |
this.id = id; | |
this.name = name; | |
this.count = count; | |
} | |
@NotNull | |
public final String component1() { | |
return this.id; | |
} | |
@NotNull | |
public final String component2() { | |
return this.name; | |
} | |
@Nullable | |
public final Integer component3() { | |
return this.count; | |
} | |
@NotNull | |
public final FooData copy(@NotNull String id, @NotNull String name, @Nullable Integer count) { | |
Intrinsics.checkParameterIsNotNull(id, "id"); | |
Intrinsics.checkParameterIsNotNull(name, "name"); | |
return new FooData(id, name, count); | |
} | |
// $FF: synthetic method | |
// $FF: bridge method | |
@NotNull | |
public static FooData copy$default(FooData var0, String var1, String var2, Integer var3, int var4, Object var5) { | |
if((var4 & 1) != 0) { | |
var1 = var0.id; | |
} | |
if((var4 & 2) != 0) { | |
var2 = var0.name; | |
} | |
if((var4 & 4) != 0) { | |
var3 = var0.count; | |
} | |
return var0.copy(var1, var2, var3); | |
} | |
public String toString() { | |
return "FooData(id=" + this.id + ", name=" + this.name + ", count=" + this.count + ")"; | |
} | |
public int hashCode() { | |
return ((this.id != null?this.id.hashCode():0) * 31 + (this.name != null?this.name.hashCode():0)) * 31 + (this.count != null?this.count.hashCode():0); | |
} | |
public boolean equals(Object var1) { | |
if(this != var1) { | |
if(var1 instanceof FooData) { | |
FooData var2 = (FooData)var1; | |
if(Intrinsics.areEqual(this.id, var2.id) && Intrinsics.areEqual(this.name, var2.name) && Intrinsics.areEqual(this.count, var2.count)) { | |
return true; | |
} | |
} | |
return false; | |
} else { | |
return true; | |
} | |
} | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public final class Foo { | |
@NotNull | |
private final String id; | |
@NotNull | |
private final String name; | |
@Nullable | |
private final Integer count; | |
@NotNull | |
public final String getId() { | |
return this.id; | |
} | |
@NotNull | |
public final String getName() { | |
return this.name; | |
} | |
@Nullable | |
public final Integer getCount() { | |
return this.count; | |
} | |
public Foo(@NotNull String id, @NotNull String name, @Nullable Integer count) { | |
Intrinsics.checkParameterIsNotNull(id, "id"); | |
Intrinsics.checkParameterIsNotNull(name, "name"); | |
super(); | |
this.id = id; | |
this.name = name; | |
this.count = count; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment