Package net.sf.colossus.xmlparser
Class TerrainRecruitLoader.CreatureAndNumber
- java.lang.Object
-
- net.sf.colossus.xmlparser.TerrainRecruitLoader.CreatureAndNumber
-
- Direct Known Subclasses:
TerrainRecruitLoader.RecruitNumber
,TerrainRecruitLoader.StartingNumber
- Enclosing class:
- TerrainRecruitLoader
private abstract class TerrainRecruitLoader.CreatureAndNumber extends java.lang.Object
Helper class, associating a Creature and a number. The basic identification is the name (because of the hack of using special name for special stuff...) but the CreatureType is there to avoid reloading from the Variant all the time. We can't look-up at creation time, because the variant isn't available yet, so we delay until the first call to getCreature.- Author:
- Romain Dolbeau
-
-
Field Summary
Fields Modifier and Type Field Description private boolean
checked
private CreatureType
creature
The Creature in the pair (if it exists)private java.lang.String
name
The Nameprivate int
number
The number in the pair
-
Constructor Summary
Constructors Constructor Description CreatureAndNumber(java.lang.String n, int i)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description (package private) CreatureType
getCreature()
(package private) java.lang.String
getName()
(package private) int
getNumber()
java.lang.String
toString()
Textual representation of the data.
-
-
-
Field Detail
-
creature
private CreatureType creature
The Creature in the pair (if it exists)
-
name
private final java.lang.String name
The Name
-
number
private final int number
The number in the pair
-
checked
private boolean checked
-
-
Method Detail
-
getName
java.lang.String getName()
-
getCreature
CreatureType getCreature()
-
getNumber
int getNumber()
-
toString
public java.lang.String toString()
Textual representation of the data.- Overrides:
toString
in classjava.lang.Object
- Returns:
- Textual representation of the data as a String.
-
-