package uk.ac.leeds.sog.moses.agent; import org.apache.log4j.Logger; /** * @author Belinda * This class defines a type of person that has not been included * as any other types in the system should there be such a person in the system. */ public class UnknownTypePerson extends Person { private static final long serialVersionUID = 1L; private Person i_hrp = null; private static Logger s_logger = Logger.getLogger(UnknownTypePerson.class); //constructor public UnknownTypePerson(int id) { super(id); if(s_logger.isDebugEnabled()) { s_logger.debug("Contruct a UnknownTypePerson: " + id); } } //method to get HRP public Person getHrp() { return i_hrp; } //method to set the HRP public void setHrp(Person a_hrp) { i_hrp = a_hrp; } //age one more year public void step() { i_age += 1; } //method to get a string with the information of this person public String toString() { StringBuffer buff = new StringBuffer(); buff.append("type=Unknown Type"); buff.append(" HRP_PID=" + i_hrp.getPid()); buff.append(" "); buff.append(super.toString()); return buff.toString(); } }