1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18 package de.kaiserpfalzedv.rpg.torg.model.perks;
19
20 import com.fasterxml.jackson.annotation.JsonInclude;
21 import de.kaiserpfalzedv.rpg.torg.model.actors.Clearance;
22 import de.kaiserpfalzedv.rpg.torg.model.core.Armor;
23 import de.kaiserpfalzedv.rpg.torg.model.core.Attack;
24 import de.kaiserpfalzedv.rpg.torg.model.core.Cosm;
25 import lombok.AllArgsConstructor;
26 import lombok.EqualsAndHashCode;
27 import lombok.Getter;
28 import lombok.ToString;
29 import lombok.experimental.SuperBuilder;
30 import lombok.extern.jackson.Jacksonized;
31 import org.eclipse.microprofile.openapi.annotations.media.Schema;
32
33 import jakarta.validation.constraints.Size;
34 import java.io.Serializable;
35 import java.util.Set;
36
37
38
39
40
41
42
43
44
45 @Jacksonized
46 @SuperBuilder(toBuilder = true)
47 @AllArgsConstructor
48 @Getter
49 @ToString(onlyExplicitlyIncluded = true)
50 @EqualsAndHashCode
51 @JsonInclude(JsonInclude.Include.NON_ABSENT)
52 @Schema(description = "The perk definition.")
53 public class PerkData implements Serializable {
54 @Size(max = 5000, message = "The textual description must not be larger than 5000 characters.")
55 @Schema(description = "A textual description of this spell.", nullable = true, maxLength = 5000)
56 private final String description;
57
58 @ToString.Include
59 @EqualsAndHashCode.Include
60 @Schema(description = "Sub category of this perk")
61 private final String subCategory;
62
63 @ToString.Include
64 @EqualsAndHashCode.Include
65 @Schema(description = "The minimum clearance level for this spell.")
66 private final Clearance clearance;
67
68 @Schema(description = "The cosms this perk is available for.", minItems = 0)
69 private final Set<Cosm> cosms;
70
71 @Schema(description = "Notes to this spell.", minItems = 0)
72 private final Set<String> notes;
73
74 @Schema(description = "Infos to this spell.", minItems = 0)
75 private final Set<String> info;
76
77 @Schema(description = "Prerequisites for obtaining the spell", minItems = 0)
78 private final Set<Prerequisites> prerequisites;
79
80 @Schema(description = "Possible attack (most spells are treated as attack to use the CharSheet for rolling).", minItems = 0)
81 private final Set<Attack> attack;
82
83 @Schema(description = "Possible armor (some spells provide armor depending on success levels).", minItems = 0)
84 private final Set<Armor> armor;
85 }