public class TrainErrorEvent extends java.lang.Object implements TSimInformation
Modifier and Type | Field and Description |
---|---|
static int |
DERAILMENT |
protected int |
event |
static int |
STOP_COLLISION |
static int |
TRAIN_COLLISION |
protected int |
trainId |
Constructor and Description |
---|
TrainErrorEvent(int trainId,
int event)
Creates a new TrainErrorEvent for the specified train id and with the
specified event type.
|
Modifier and Type | Method and Description |
---|---|
int |
getEvent()
Returns the type of the event.
|
int |
getTrainId()
Returns the id of the train affected byt the event.
|
java.lang.String |
toString()
Returns a string representation of the event.
|
public static final int TRAIN_COLLISION
public static final int STOP_COLLISION
public static final int DERAILMENT
protected int event
protected int trainId
public TrainErrorEvent(int trainId, int event)
trainId
- the id of the train affected by the event.event
- the type of the event.public int getEvent()
public int getTrainId()
public java.lang.String toString()
toString
in class java.lang.Object