|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.jikesrvm.compilers.opt.instrsched.ResourceReservation
final class ResourceReservation
Describes a reservation on a particular resource. A reservation is for a continuous period of time. Used in OperatorClass.
OperatorClass
Field Summary | |
---|---|
(package private) int |
duration
Duration of Use. |
private int |
rclass
Resource Class. |
(package private) int |
start
Start Time. |
Constructor Summary | |
---|---|
ResourceReservation(int rclass,
int duration)
Creates a new reservation for specified resource class starting at 0 with given duration. |
|
ResourceReservation(int rclass,
int start,
int duration)
Creates a new reservation for specified resource class starting at specified time with given duration. |
Method Summary | |
---|---|
private int |
compareTo(ResourceReservation r)
Compares this reservation with another reservation. |
boolean |
conflicts(ResourceReservation rsrv)
Checks whether this reservation conflicts with specified reservation. |
boolean |
equals(Object o)
Compares this object against the specified object. |
boolean |
isGlobal()
Checks whether this reservation is for all available units of the class. |
int |
rclass()
The resource class of this reservation. |
static void |
sort(ResourceReservation[] usage)
Sorts an array of reservations in accordance with internal ordering. |
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
private final int rclass
final int start
final int duration
Constructor Detail |
---|
public ResourceReservation(int rclass, int duration)
rclass
- resource classduration
- durationResourceReservation(int,int,int)
public ResourceReservation(int rclass, int start, int duration)
rclass
- resource classstart
- start timeduration
- durationMethod Detail |
---|
public int rclass()
public boolean isGlobal()
private int compareTo(ResourceReservation r)
r
- the other reservation
public static void sort(ResourceReservation[] usage)
usage
- array of reservationspublic boolean equals(Object o)
equals
in class Object
o
- The object to compare with
true
if the objects are the same; false
otherwise.public boolean conflicts(ResourceReservation rsrv)
rsrv
- the reservation to check
true
if the reservations conflict; false
otherwise.
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |