|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.mars_sim.msp.simulation.person.ai.task.Task
org.mars_sim.msp.simulation.person.ai.task.NegotiateTrade
public class NegotiateTrade
Task to perform a trade negotiation between the buyer and seller for a Trade mission.
| Field Summary |
|---|
| Fields inherited from class org.mars_sim.msp.simulation.person.ai.task.Task |
|---|
effortDriven, hasDuration, person, phaseTimeCompleted, phaseTimeRequired, stressModifier, subTask, TASK_DESC_EVENT, TASK_ENDED_EVENT, TASK_NAME_EVENT, TASK_PHASE_EVENT, TASK_SUBTASK_EVENT |
| Constructor Summary | |
|---|---|
NegotiateTrade(Settlement sellingSettlement,
Settlement buyingSettlement,
Rover rover,
java.util.Map<Good,java.lang.Integer> soldLoad,
Person buyingTrader,
Person sellingTrader)
Constructor |
|
| Method Summary | |
|---|---|
protected void |
addExperience(double time)
Adds experience to the person's skills used in this task. |
java.util.List<java.lang.String> |
getAssociatedSkills()
Gets a list of the skills associated with this task. |
java.util.Map<Good,java.lang.Integer> |
getBuyLoad()
Gets the buy load for the trade. |
int |
getEffectiveSkillLevel()
Gets the effective skill level a person has at this task. |
protected double |
performMappedPhase(double time)
Performs the method mapped to the task's current phase. |
| Methods inherited from class org.mars_sim.msp.simulation.person.ai.task.Task |
|---|
addPhase, compareTo, endTask, getCreateEvents, getCrowdingProbabilityModifier, getDescription, getDuration, getName, getPhase, getProbability, getRelationshipModifier, getSubTask, getTeacher, getTeachingExperienceModifier, getTimeCompleted, getTopPhase, hasTeacher, isDone, isEffortDriven, setCreateEvents, setDescription, setDuration, setName, setPhase, setStressModifier, setTeacher, toString |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public NegotiateTrade(Settlement sellingSettlement,
Settlement buyingSettlement,
Rover rover,
java.util.Map<Good,java.lang.Integer> soldLoad,
Person buyingTrader,
Person sellingTrader)
throws java.lang.Exception
sellingSettlement - the selling settlement.buyingSettlement - the buying settlement.rover - the rover to transport the goods.soldLoad - the goods sold.buyingTrader - the buying trader.sellingTrader - the selling trader.
java.lang.Exception - if error creating the task.| Method Detail |
|---|
protected void addExperience(double time)
addExperience in class Tasktime - the amount of time (ms) the person performed this task.public java.util.List<java.lang.String> getAssociatedSkills()
getAssociatedSkills in class Taskpublic int getEffectiveSkillLevel()
getEffectiveSkillLevel in class Task
protected double performMappedPhase(double time)
throws java.lang.Exception
performMappedPhase in class Tasktime - the amount of time (millisol) the phase is to be performed.
java.lang.Exception - if error in performing phase or if phase cannot be found.public java.util.Map<Good,java.lang.Integer> getBuyLoad()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||