Remove annotations and regenerate equals(), hashcode() and toString() methods

pull/9/head
Hammy 4 years ago
parent 7b0d341183
commit 2315657ec4

@ -1,12 +1,12 @@
package me.goudham.api.entity; package me.goudham.api.entity;
import javax.annotation.processing.Generated;
import com.fasterxml.jackson.annotation.JsonInclude; import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonProperty;
import com.fasterxml.jackson.annotation.JsonPropertyDescription; import com.fasterxml.jackson.annotation.JsonPropertyDescription;
import com.fasterxml.jackson.annotation.JsonPropertyOrder; import com.fasterxml.jackson.annotation.JsonPropertyOrder;
import java.util.Objects;
/** /**
* {@link PaginationData} * {@link PaginationData}
@ -28,7 +28,6 @@ import com.fasterxml.jackson.annotation.JsonPropertyOrder;
"per_page", "per_page",
"total" "total"
}) })
@Generated("jsonschema2pojo")
public class PaginationData { public class PaginationData {
/** /**
* Current requested page * Current requested page
@ -102,4 +101,26 @@ public class PaginationData {
this.total = total; this.total = total;
} }
@Override
public boolean equals(Object o) {
if (this == o) return true;
if (o == null || getClass() != o.getClass()) return false;
PaginationData that = (PaginationData) o;
return Objects.equals(currentPage, that.currentPage) && Objects.equals(lastPage, that.lastPage) && Objects.equals(perPage, that.perPage) && Objects.equals(total, that.total);
}
@Override
public int hashCode() {
return Objects.hash(currentPage, lastPage, perPage, total);
}
@Override
public String toString() {
return "PaginationData{" +
"currentPage=" + currentPage +
", lastPage=" + lastPage +
", perPage=" + perPage +
", total=" + total +
'}';
}
} }

@ -1,8 +1,9 @@
package me.goudham.api.entity; package me.goudham.api.entity;
import javax.annotation.processing.Generated; import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.annotation.JsonProperty;
import com.fasterxml.jackson.annotation.*; import com.fasterxml.jackson.annotation.JsonPropertyDescription;
import com.fasterxml.jackson.annotation.JsonPropertyOrder;
import java.util.Objects; import java.util.Objects;
@ -24,7 +25,6 @@ import java.util.Objects;
"name", "name",
"original_name" "original_name"
}) })
@Generated("jsonschema2pojo")
public class Studio { public class Studio {
Studio() { } Studio() { }

@ -1,12 +1,11 @@
package me.goudham.api.entity.series; package me.goudham.api.entity.series;
import javax.annotation.processing.Generated;
import com.fasterxml.jackson.annotation.JsonInclude; import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonProperty;
import com.fasterxml.jackson.annotation.JsonPropertyDescription; import com.fasterxml.jackson.annotation.JsonPropertyDescription;
import com.fasterxml.jackson.annotation.JsonPropertyOrder; import com.fasterxml.jackson.annotation.JsonPropertyOrder;
import javax.annotation.processing.Generated;
import java.util.Objects; import java.util.Objects;
/** /**
@ -41,7 +40,6 @@ import java.util.Objects;
"url", "url",
"id" "id"
}) })
@Generated("jsonschema2pojo")
public class FilteredSeries { public class FilteredSeries {
/** /**
* Full name, in English. * Full name, in English.
@ -218,12 +216,12 @@ public class FilteredSeries {
if (this == o) return true; if (this == o) return true;
if (o == null || getClass() != o.getClass()) return false; if (o == null || getClass() != o.getClass()) return false;
FilteredSeries that = (FilteredSeries) o; FilteredSeries that = (FilteredSeries) o;
return Objects.equals(name, that.name) && Objects.equals(originalName, that.originalName) && Objects.equals(romajiName, that.romajiName) && Objects.equals(slug, that.slug) && Objects.equals(description, that.description) && Objects.equals(url, that.url) && Objects.equals(id, that.id); return Objects.equals(name, that.name) && Objects.equals(originalName, that.originalName) && Objects.equals(relevance, that.relevance) && Objects.equals(romajiName, that.romajiName) && Objects.equals(slug, that.slug) && Objects.equals(type, that.type) && Objects.equals(description, that.description) && Objects.equals(displayPicture, that.displayPicture) && Objects.equals(url, that.url) && Objects.equals(id, that.id);
} }
@Override @Override
public int hashCode() { public int hashCode() {
return Objects.hash(name, originalName, romajiName, slug, description, url, id); return Objects.hash(name, originalName, relevance, romajiName, slug, type, description, displayPicture, url, id);
} }
@Override @Override
@ -231,9 +229,12 @@ public class FilteredSeries {
return "FilteredSeries{" + return "FilteredSeries{" +
"name='" + name + '\'' + "name='" + name + '\'' +
", originalName='" + originalName + '\'' + ", originalName='" + originalName + '\'' +
", relevance=" + relevance +
", romajiName='" + romajiName + '\'' + ", romajiName='" + romajiName + '\'' +
", slug='" + slug + '\'' + ", slug='" + slug + '\'' +
", type='" + type + '\'' +
", description='" + description + '\'' + ", description='" + description + '\'' +
", displayPicture='" + displayPicture + '\'' +
", url='" + url + '\'' + ", url='" + url + '\'' +
", id=" + id + ", id=" + id +
'}'; '}';

@ -1,7 +1,5 @@
package me.goudham.api.entity.series; package me.goudham.api.entity.series;
import javax.annotation.processing.Generated;
import com.fasterxml.jackson.annotation.*; import com.fasterxml.jackson.annotation.*;
import me.goudham.api.entity.Studio; import me.goudham.api.entity.Studio;
import me.goudham.api.entity.waifu.Waifu; import me.goudham.api.entity.waifu.Waifu;
@ -48,7 +46,6 @@ import java.util.Objects;
"type", "type",
"id" "id"
}) })
@Generated("jsonschema2pojo")
public class Series { public class Series {
/** /**
* Full Name (in English) * Full Name (in English)
@ -302,12 +299,12 @@ public class Series {
if (this == o) return true; if (this == o) return true;
if (o == null || getClass() != o.getClass()) return false; if (o == null || getClass() != o.getClass()) return false;
Series series = (Series) o; Series series = (Series) o;
return Objects.equals(name, series.name) && Objects.equals(originalName, series.originalName) && Objects.equals(romajiName, series.romajiName) && Objects.equals(description, series.description) && Objects.equals(slug, series.slug) && Objects.equals(releaseDate, series.releaseDate) && Objects.equals(airingStart, series.airingStart) && Objects.equals(airingEnd, series.airingEnd) && Objects.equals(episodeCount, series.episodeCount) && Objects.equals(displayPicture, series.displayPicture) && Objects.equals(url, series.url) && Objects.equals(studio, series.studio) && Objects.equals(id, series.id); return Objects.equals(name, series.name) && Objects.equals(originalName, series.originalName) && Objects.equals(romajiName, series.romajiName) && Objects.equals(description, series.description) && Objects.equals(slug, series.slug) && Objects.equals(releaseDate, series.releaseDate) && Objects.equals(airingStart, series.airingStart) && Objects.equals(airingEnd, series.airingEnd) && Objects.equals(episodeCount, series.episodeCount) && Objects.equals(displayPicture, series.displayPicture) && Objects.equals(url, series.url) && Objects.equals(studio, series.studio) && Objects.equals(type, series.type) && Objects.equals(id, series.id);
} }
@Override @Override
public int hashCode() { public int hashCode() {
return Objects.hash(name, originalName, romajiName, description, slug, releaseDate, airingStart, airingEnd, episodeCount, displayPicture, url, studio, id); return Objects.hash(name, originalName, romajiName, description, slug, releaseDate, airingStart, airingEnd, episodeCount, displayPicture, url, studio, type, id);
} }
@Override @Override
@ -322,9 +319,10 @@ public class Series {
", airingStart='" + airingStart + '\'' + ", airingStart='" + airingStart + '\'' +
", airingEnd='" + airingEnd + '\'' + ", airingEnd='" + airingEnd + '\'' +
", episodeCount=" + episodeCount + ", episodeCount=" + episodeCount +
", image='" + displayPicture + '\'' + ", displayPicture='" + displayPicture + '\'' +
", url='" + url + '\'' + ", url='" + url + '\'' +
", studio=" + studio + ", studio=" + studio +
", type='" + type + '\'' +
", id=" + id + ", id=" + id +
'}'; '}';
} }

@ -1,13 +1,10 @@
package me.goudham.api.entity.user; package me.goudham.api.entity.user;
import javax.annotation.processing.Generated;
import com.fasterxml.jackson.annotation.JsonPropertyDescription;
import me.goudham.api.entity.waifu.Waifu;
import com.fasterxml.jackson.annotation.JsonInclude; import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonProperty;
import com.fasterxml.jackson.annotation.JsonPropertyDescription;
import com.fasterxml.jackson.annotation.JsonPropertyOrder; import com.fasterxml.jackson.annotation.JsonPropertyOrder;
import me.goudham.api.entity.waifu.Waifu;
import java.util.Objects; import java.util.Objects;
@ -27,7 +24,6 @@ import java.util.Objects;
"id", "id",
"name" "name"
}) })
@Generated("jsonschema2pojo")
public class Creator { public class Creator {
/** /**
@ -35,14 +31,14 @@ public class Creator {
* *
*/ */
@JsonProperty("id") @JsonProperty("id")
@JsonPropertyDescription("") @JsonPropertyDescription("Creator ID")
private Integer id; private Integer id;
/** /**
* {@link Creator} Name * {@link Creator} Name
*/ */
@JsonProperty("name") @JsonProperty("name")
@JsonPropertyDescription("") @JsonPropertyDescription("Creator Name")
private String name; private String name;
@JsonProperty("id") @JsonProperty("id")

@ -7,7 +7,6 @@ import com.fasterxml.jackson.annotation.JsonPropertyDescription;
import com.fasterxml.jackson.annotation.JsonPropertyOrder; import com.fasterxml.jackson.annotation.JsonPropertyOrder;
import me.goudham.api.entity.series.Series; import me.goudham.api.entity.series.Series;
import javax.annotation.processing.Generated;
import java.util.Objects; import java.util.Objects;
/** /**
@ -28,7 +27,6 @@ import java.util.Objects;
"slug", "slug",
"series" "series"
}) })
@Generated("jsonschema2pojo")
public class TrueLove { public class TrueLove {
/** /**
* Name of {@link TrueLove} * Name of {@link TrueLove}

@ -199,18 +199,19 @@ public class User {
if (this == o) return true; if (this == o) return true;
if (o == null || getClass() != o.getClass()) return false; if (o == null || getClass() != o.getClass()) return false;
User user = (User) o; User user = (User) o;
return Objects.equals(id, user.id) && Objects.equals(name, user.name) && Objects.equals(twitter, user.twitter) && Objects.equals(joined, user.joined) && Objects.equals(waifusCreated, user.waifusCreated) && Objects.equals(waifusLiked, user.waifusLiked) && Objects.equals(waifusTrashed, user.waifusTrashed) && Objects.equals(trueLove, user.trueLove); return Objects.equals(avatar, user.avatar) && Objects.equals(id, user.id) && Objects.equals(name, user.name) && Objects.equals(twitter, user.twitter) && Objects.equals(joined, user.joined) && Objects.equals(waifusCreated, user.waifusCreated) && Objects.equals(waifusLiked, user.waifusLiked) && Objects.equals(waifusTrashed, user.waifusTrashed) && Objects.equals(trueLove, user.trueLove);
} }
@Override @Override
public int hashCode() { public int hashCode() {
return Objects.hash(id, name, twitter, joined, waifusCreated, waifusLiked, waifusTrashed, trueLove); return Objects.hash(avatar, id, name, twitter, joined, waifusCreated, waifusLiked, waifusTrashed, trueLove);
} }
@Override @Override
public String toString() { public String toString() {
return "User{" + return "User{" +
"id=" + id + "avatar='" + avatar + '\'' +
", id=" + id +
", name='" + name + '\'' + ", name='" + name + '\'' +
", twitter='" + twitter + '\'' + ", twitter='" + twitter + '\'' +
", joined='" + joined + '\'' + ", joined='" + joined + '\'' +

@ -1,15 +1,14 @@
package me.goudham.api.entity.user; package me.goudham.api.entity.user;
import java.util.List;
import java.util.Objects;
import javax.annotation.processing.Generated;
import com.fasterxml.jackson.annotation.JsonInclude; import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonProperty;
import com.fasterxml.jackson.annotation.JsonPropertyDescription; import com.fasterxml.jackson.annotation.JsonPropertyDescription;
import com.fasterxml.jackson.annotation.JsonPropertyOrder; import com.fasterxml.jackson.annotation.JsonPropertyOrder;
import me.goudham.api.entity.waifu.Waifu; import me.goudham.api.entity.waifu.Waifu;
import java.util.List;
import java.util.Objects;
/** /**
* {@link UserList} * {@link UserList}
* <p>Get an array of all user lists on their profile</p> * <p>Get an array of all user lists on their profile</p>
@ -30,7 +29,6 @@ import me.goudham.api.entity.waifu.Waifu;
"order", "order",
"waifus" "waifus"
}) })
@Generated("jsonschema2pojo")
public class UserList { public class UserList {
/** /**
* {@link UserList} ID * {@link UserList} ID

@ -286,12 +286,12 @@ public class FilteredWaifu {
if (this == o) return true; if (this == o) return true;
if (o == null || getClass() != o.getClass()) return false; if (o == null || getClass() != o.getClass()) return false;
FilteredWaifu that = (FilteredWaifu) o; FilteredWaifu that = (FilteredWaifu) o;
return Objects.equals(slug, that.slug) && Objects.equals(name, that.name) && Objects.equals(originalName, that.originalName) && Objects.equals(romajiName, that.romajiName) && Objects.equals(displayPicture, that.displayPicture) && Objects.equals(description, that.description) && Objects.equals(likes, that.likes) && Objects.equals(trash, that.trash) && Objects.equals(url, that.url) && Objects.equals(appearances, that.appearances) && Objects.equals(id, that.id); return Objects.equals(slug, that.slug) && Objects.equals(name, that.name) && Objects.equals(originalName, that.originalName) && Objects.equals(relevance, that.relevance) && Objects.equals(romaji, that.romaji) && Objects.equals(romajiName, that.romajiName) && Objects.equals(displayPicture, that.displayPicture) && Objects.equals(description, that.description) && Objects.equals(likes, that.likes) && Objects.equals(trash, that.trash) && Objects.equals(type, that.type) && Objects.equals(url, that.url) && Objects.equals(appearances, that.appearances) && Objects.equals(id, that.id);
} }
@Override @Override
public int hashCode() { public int hashCode() {
return Objects.hash(slug, name, originalName, romajiName, displayPicture, description, likes, trash, url, appearances, id); return Objects.hash(slug, name, originalName, relevance, romaji, romajiName, displayPicture, description, likes, trash, type, url, appearances, id);
} }
@Override @Override
@ -300,11 +300,14 @@ public class FilteredWaifu {
"slug='" + slug + '\'' + "slug='" + slug + '\'' +
", name='" + name + '\'' + ", name='" + name + '\'' +
", originalName='" + originalName + '\'' + ", originalName='" + originalName + '\'' +
", relevance=" + relevance +
", romaji='" + romaji + '\'' +
", romajiName='" + romajiName + '\'' + ", romajiName='" + romajiName + '\'' +
", displayPicture='" + displayPicture + '\'' + ", displayPicture='" + displayPicture + '\'' +
", description='" + description + '\'' + ", description='" + description + '\'' +
", likes=" + likes + ", likes=" + likes +
", trash=" + trash + ", trash=" + trash +
", type='" + type + '\'' +
", url='" + url + '\'' + ", url='" + url + '\'' +
", appearances=" + appearances + ", appearances=" + appearances +
", id=" + id + ", id=" + id +

@ -1,14 +1,14 @@
package me.goudham.api.entity.waifu; package me.goudham.api.entity.waifu;
import com.fasterxml.jackson.annotation.*;
import me.goudham.api.entity.series.Series;
import me.goudham.api.entity.user.Creator;
import javax.annotation.processing.Generated;
import java.util.HashMap; import java.util.HashMap;
import java.util.List; import java.util.List;
import java.util.Map; import java.util.Map;
import java.util.Objects; import java.util.Objects;
import javax.annotation.processing.Generated;
import com.fasterxml.jackson.annotation.*;
import me.goudham.api.entity.series.Series;
import me.goudham.api.entity.user.Creator;
/** /**
@ -81,7 +81,6 @@ import me.goudham.api.entity.user.Creator;
"appearances", "appearances",
"series" "series"
}) })
@Generated("jsonschema2pojo")
@JsonIgnoreProperties(ignoreUnknown = true) @JsonIgnoreProperties(ignoreUnknown = true)
public class Waifu { public class Waifu {
/** /**
@ -612,12 +611,12 @@ public class Waifu {
if (this == o) return true; if (this == o) return true;
if (o == null || getClass() != o.getClass()) return false; if (o == null || getClass() != o.getClass()) return false;
Waifu waifu = (Waifu) o; Waifu waifu = (Waifu) o;
return Objects.equals(id, waifu.id) && Objects.equals(slug, waifu.slug) && Objects.equals(creator, waifu.creator) && Objects.equals(name, waifu.name) && Objects.equals(originalName, waifu.originalName) && Objects.equals(displayPicture, waifu.displayPicture) && Objects.equals(description, waifu.description) && Objects.equals(weight, waifu.weight) && Objects.equals(height, waifu.height) && Objects.equals(bust, waifu.bust) && Objects.equals(hip, waifu.hip) && Objects.equals(waist, waifu.waist) && bloodType == waifu.bloodType && Objects.equals(origin, waifu.origin) && Objects.equals(age, waifu.age) && Objects.equals(birthdayMonth, waifu.birthdayMonth) && Objects.equals(birthdayDay, waifu.birthdayDay) && Objects.equals(birthdayYear, waifu.birthdayYear) && Objects.equals(likes, waifu.likes) && Objects.equals(trash, waifu.trash) && Objects.equals(url, waifu.url) && Objects.equals(husbando, waifu.husbando) && Objects.equals(nsfw, waifu.nsfw) && Objects.equals(popularityRank, waifu.popularityRank) && Objects.equals(likeRank, waifu.likeRank) && Objects.equals(trashRank, waifu.trashRank) && Objects.equals(appearances, waifu.appearances) && Objects.equals(series, waifu.series); return Objects.equals(id, waifu.id) && Objects.equals(slug, waifu.slug) && Objects.equals(creator, waifu.creator) && Objects.equals(name, waifu.name) && Objects.equals(originalName, waifu.originalName) && Objects.equals(romajiName, waifu.romajiName) && Objects.equals(displayPicture, waifu.displayPicture) && Objects.equals(description, waifu.description) && Objects.equals(weight, waifu.weight) && Objects.equals(height, waifu.height) && Objects.equals(bust, waifu.bust) && Objects.equals(hip, waifu.hip) && Objects.equals(waist, waifu.waist) && bloodType == waifu.bloodType && Objects.equals(origin, waifu.origin) && Objects.equals(age, waifu.age) && Objects.equals(birthdayMonth, waifu.birthdayMonth) && Objects.equals(birthdayDay, waifu.birthdayDay) && Objects.equals(birthdayYear, waifu.birthdayYear) && Objects.equals(likes, waifu.likes) && Objects.equals(trash, waifu.trash) && Objects.equals(url, waifu.url) && Objects.equals(husbando, waifu.husbando) && Objects.equals(nsfw, waifu.nsfw) && Objects.equals(popularityRank, waifu.popularityRank) && Objects.equals(likeRank, waifu.likeRank) && Objects.equals(trashRank, waifu.trashRank) && Objects.equals(appearances, waifu.appearances) && Objects.equals(series, waifu.series);
} }
@Override @Override
public int hashCode() { public int hashCode() {
return Objects.hash(id, slug, creator, name, originalName, displayPicture, description, weight, height, bust, hip, waist, bloodType, origin, age, birthdayMonth, birthdayDay, birthdayYear, likes, trash, url, husbando, nsfw, popularityRank, likeRank, trashRank, appearances, series); return Objects.hash(id, slug, creator, name, originalName, romajiName, displayPicture, description, weight, height, bust, hip, waist, bloodType, origin, age, birthdayMonth, birthdayDay, birthdayYear, likes, trash, url, husbando, nsfw, popularityRank, likeRank, trashRank, appearances, series);
} }
@Override @Override
@ -625,9 +624,10 @@ public class Waifu {
return "Waifu{" + return "Waifu{" +
"id=" + id + "id=" + id +
", slug='" + slug + '\'' + ", slug='" + slug + '\'' +
", creatorId=" + creator + ", creator=" + creator +
", name='" + name + '\'' + ", name='" + name + '\'' +
", originalName='" + originalName + '\'' + ", originalName='" + originalName + '\'' +
", romajiName='" + romajiName + '\'' +
", displayPicture='" + displayPicture + '\'' + ", displayPicture='" + displayPicture + '\'' +
", description='" + description + '\'' + ", description='" + description + '\'' +
", weight=" + weight + ", weight=" + weight +

Loading…
Cancel
Save