Class AllocationPlan
- java.lang.Object
- 
- jmri.jmrit.dispatcher.AllocationPlan
 
- 
 public class AllocationPlan extends java.lang.Object Handle planning information for AutoAllocateAn Allocation Plan involves a planned meet of two ActiveTrains in a specified area of the layout. AllocationPlan objects are transient (not saved between runs). AllocationPlan objects are created and disposed by AutoAllocate as needed. AutoAllocate serves as the manager of AllocationPlan objects. An ActiveTrain may be in more than one AllocationPlan of the same type, provided its target Section in all active AllocationPlans is the same. An AllocationPlan is "complete" when both Active Trains have been allocated their target Sections. This file is part of JMRI. JMRI is open source software; you can redistribute it and/or modify it under the terms of version 2 of the GNU General Public License as published by the Free Software Foundation. See the "COPYING" file for a copy of this license. JMRI is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. 
- 
- 
Field SummaryFields Modifier and Type Field Description protected static intCONTINUINGprotected static intNONEConstants representing the type of AllocationPlanprotected static intPASSING_MEETprotected static intXING_MEET
 - 
Constructor SummaryConstructors Constructor Description AllocationPlan(AutoAllocate aa, int planNum)
 - 
Method SummaryAll Methods Instance Methods Concrete Methods Modifier and Type Method Description voiddispose()protected ActiveTraingetActiveTrain(int i)protected intgetPlanNum()protected intgetPlanType()protected SectiongetTargetSection(int i)protected intgetTargetSectionSequenceNum(int i)protected booleanisComplete()protected voidsetActiveTrain(ActiveTrain at, int i)protected voidsetPlanType(int type)protected voidsetTargetSection(Section s, int seq, int i)
 
- 
- 
- 
Field Detail- 
NONEprotected static final int NONE Constants representing the type of AllocationPlan- See Also:
- Constant Field Values
 
 - 
XING_MEETprotected static final int XING_MEET - See Also:
- Constant Field Values
 
 - 
PASSING_MEETprotected static final int PASSING_MEET - See Also:
- Constant Field Values
 
 - 
CONTINUINGprotected static final int CONTINUING - See Also:
- Constant Field Values
 
 
- 
 - 
Constructor Detail- 
AllocationPlanpublic AllocationPlan(AutoAllocate aa, int planNum) 
 
- 
 - 
Method Detail- 
getPlanNumprotected int getPlanNum() 
 - 
getPlanTypeprotected int getPlanType() 
 - 
setPlanTypeprotected void setPlanType(int type) 
 - 
getActiveTrainprotected ActiveTrain getActiveTrain(int i) 
 - 
setActiveTrainprotected void setActiveTrain(ActiveTrain at, int i) 
 - 
getTargetSectionprotected Section getTargetSection(int i) 
 - 
setTargetSectionprotected void setTargetSection(Section s, int seq, int i) 
 - 
getTargetSectionSequenceNumprotected int getTargetSectionSequenceNum(int i) 
 - 
isCompleteprotected boolean isComplete() 
 - 
disposepublic void dispose() 
 
- 
 
-