public class SimEvent extends Object implements Cloneable, Comparable<SimEvent>
Simulation
,
SimEntity
Modifier and Type | Field and Description |
---|---|
static int |
CREATE |
static int |
ENULL |
static int |
HOLD_DONE |
static int |
SEND |
Constructor and Description |
---|
SimEvent()
Create a blank event.
|
Modifier and Type | Method and Description |
---|---|
Object |
clone()
Create an exact copy of this event.
|
int |
compareTo(SimEvent event) |
double |
endWaitingTime()
Get the simulation time that this event was removed from the queue for service.
|
double |
eventTime()
Get the simulation time that this event was scheduled.
|
Object |
getData()
Get the data passed in this event.
|
int |
getDestination()
Get the unique id number of the entity which received this event.
|
int |
getSource()
Get the unique id number of the entity which scheduled this event.
|
int |
getTag()
Get the user-defined tag of this event.
|
int |
getType()
The internal type
|
int |
scheduledBy()
Get the unique id number of the entity which scheduled this event.
|
void |
setDestination(int d)
Set the destination entity of this event.
|
protected void |
setEndWaitingTime(double end_waiting_time)
Used to set the time at which this event finished waiting in the event
|
protected void |
setSerial(long serial) |
void |
setSource(int s)
Set the source entity of this event.
|
String |
toString() |
int |
type()
Get the user-defined tag of this event
|
public static final int ENULL
public static final int SEND
public static final int HOLD_DONE
public static final int CREATE
protected void setSerial(long serial)
protected void setEndWaitingTime(double end_waiting_time)
end_waiting_time
- public int getType()
public int compareTo(SimEvent event)
compareTo
in interface Comparable<SimEvent>
Comparable.compareTo(Object)
public int getDestination()
public int getSource()
public double eventTime()
public double endWaitingTime()
public int type()
public int scheduledBy()
public int getTag()
public Object getData()
public Object clone()
public void setSource(int s)
s
- The unique id number of the entitypublic void setDestination(int d)
d
- The unique id number of the entityCopyright © 2012 The Cloud Computing and Distributed Systems (CLOUDS) Laboratory, The University of Melbourne. All Rights Reserved.