Add characterRoles field support

This commit is contained in:
2026-03-24 04:27:32 +05:00
parent 674ab2df5b
commit f881b9d0ca
3 changed files with 19 additions and 0 deletions

View File

@@ -59,6 +59,7 @@ public class Anime {
private List<String> synonyms; private List<String> synonyms;
private List<Genre> genres; private List<Genre> genres;
private List<Related> related; private List<Related> related;
private List<CharacterRole> characterRoles;
private List<ChronologyAnime> chronology; private List<ChronologyAnime> chronology;
@Nullable @Nullable
@@ -297,6 +298,14 @@ public class Anime {
this.related = related; this.related = related;
} }
public List<CharacterRole> getCharacterRoles() {
return characterRoles;
}
public void setCharacterRoles(List<CharacterRole> characterRoles) {
this.characterRoles = characterRoles;
}
public List<ChronologyAnime> getChronology() { public List<ChronologyAnime> getChronology() {
return chronology; return chronology;
} }

View File

@@ -0,0 +1,4 @@
package com.backend.metadata.shikimori.api.model;
public record Character(String id, String name, Poster poster) {
}

View File

@@ -0,0 +1,6 @@
package com.backend.metadata.shikimori.api.model;
import java.util.List;
public record CharacterRole(List<String> rolesRu, List<String> rolesEn, Character character) {
}