Package jmri.jmrit.timetable
Class Stop
- java.lang.Object
-
- jmri.jmrit.timetable.Stop
-
public class Stop extends java.lang.Object
Define the content of a Stop record.
-
-
Field Summary
Fields Modifier and Type Field Description (package private) TimeTableDataManager
_dm
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description int
getArriveTime()
Stop
getCopy(int trainId, int stationId, int seq)
Make a copy of the stop.int
getDepartTime()
int
getDuration()
int
getNextSpeed()
int
getSeq()
int
getStagingTrack()
int
getStationId()
int
getStopId()
java.lang.String
getStopNotes()
int
getTrainId()
void
setArriveTime(int newArriveTime)
void
setDepartTime(int newDepartTime)
void
setDuration(int newDuration)
void
setNextSpeed(int newNextSpeed)
void
setSeq(int newSeq)
void
setStagingTrack(int newStagingTrack)
void
setStationId(int newStationId)
void
setStopNotes(java.lang.String newNotes)
java.lang.String
toString()
-
-
-
Constructor Detail
-
Stop
public Stop(int trainId, int seq)
Create a new stop with default values.- Parameters:
trainId
- The parent train id.seq
- The next stop sequence number.- Throws:
java.lang.IllegalArgumentException
- STOP_ADD_FAIL
-
Stop
public Stop(int stopId, int trainId, int stationId, int seq, int duration, int nextSpeed, int arriveTime, int departTime, int stagingTrack, java.lang.String stopNotes)
-
-
Method Detail
-
getCopy
public Stop getCopy(int trainId, int stationId, int seq)
Make a copy of the stop.- Parameters:
trainId
- The new train id, if zero use the current train id.stationId
- The new station id. If zero use the current station id.seq
- The sequence for the new stop.- Returns:
- a new Stop instance.
-
getStopId
public int getStopId()
-
getTrainId
public int getTrainId()
-
getStationId
public int getStationId()
-
setStationId
public void setStationId(int newStationId)
-
getSeq
public int getSeq()
-
setSeq
public void setSeq(int newSeq)
-
getDuration
public int getDuration()
-
setDuration
public void setDuration(int newDuration)
-
getNextSpeed
public int getNextSpeed()
-
setNextSpeed
public void setNextSpeed(int newNextSpeed)
-
getArriveTime
public int getArriveTime()
-
setArriveTime
public void setArriveTime(int newArriveTime)
-
getDepartTime
public int getDepartTime()
-
setDepartTime
public void setDepartTime(int newDepartTime)
-
getStagingTrack
public int getStagingTrack()
-
setStagingTrack
public void setStagingTrack(int newStagingTrack)
-
getStopNotes
public java.lang.String getStopNotes()
-
setStopNotes
public void setStopNotes(java.lang.String newNotes)
-
toString
public java.lang.String toString()
- Overrides:
toString
in classjava.lang.Object
-
-