mirror of
https://github.com/magefree/mage.git
synced 2025-12-26 05:22:02 -08:00
reorganized various constructed formats
This commit is contained in:
parent
4967750669
commit
0d038b1737
12 changed files with 23 additions and 102 deletions
|
|
@ -30,12 +30,8 @@ public class Constructed extends DeckValidator {
|
|||
protected List<Rarity> rarities = new ArrayList<>();
|
||||
protected Set<String> singleCards = new HashSet<>();
|
||||
|
||||
public Constructed() {
|
||||
super("Constructed");
|
||||
}
|
||||
|
||||
protected Constructed(String name) {
|
||||
super(name);
|
||||
this(name, null);
|
||||
}
|
||||
|
||||
protected Constructed(String name, String shortName) {
|
||||
|
|
|
|||
|
|
@ -15,10 +15,6 @@ public abstract class DeckValidator implements Serializable {
|
|||
protected String shortName;
|
||||
protected List<DeckValidatorError> errorsList = new ArrayList<>();
|
||||
|
||||
public DeckValidator(String name) {
|
||||
setName(name);
|
||||
}
|
||||
|
||||
public DeckValidator(String name, String shortName) {
|
||||
setName(name, shortName);
|
||||
}
|
||||
|
|
@ -33,14 +29,13 @@ public abstract class DeckValidator implements Serializable {
|
|||
return shortName;
|
||||
}
|
||||
|
||||
protected void setName(String name) {
|
||||
this.name = name;
|
||||
this.shortName = name.contains("-") ? name.substring(name.indexOf("-") + 1).trim() : name;
|
||||
}
|
||||
|
||||
protected void setName(String name, String shortName) {
|
||||
this.name = name;
|
||||
this.shortName = shortName;
|
||||
if (shortName != null) {
|
||||
this.shortName = shortName;
|
||||
} else {
|
||||
this.shortName = name.contains("-") ? name.substring(name.indexOf("-") + 1).trim() : name;
|
||||
}
|
||||
}
|
||||
|
||||
protected void setShortName(String shortName) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue