public class ResCloudletList
extends java.lang.Object
| Constructor and Description |
|---|
ResCloudletList() |
| Modifier and Type | Method and Description |
|---|---|
static <T extends ResCloudlet> |
getByIdAndUserId(java.util.List<T> list,
int cloudletId,
int userId)
Returns a given Cloudlet.
|
static <T extends ResCloudlet> |
getPositionById(java.util.List<T> cloudletList,
int id)
Returns the position of the cloudlet with that id, if it exists.
|
static <T extends ResCloudlet> |
indexOf(java.util.List<T> list,
int cloudletId,
int userId)
Finds the index of a Cloudlet inside the list.
|
static <T extends ResCloudlet> |
move(java.util.List<T> listFrom,
java.util.List<T> listTo,
T cloudlet)
Move a ResCloudlet object from this linked-list into a specified one.
|
public static <T extends ResCloudlet> ResCloudlet getByIdAndUserId(java.util.List<T> list, int cloudletId, int userId)
cloudletId - a Cloudlet IduserId - an User Idlist - the listjava.lang.IndexOutOfBoundsException - - if a Cloudlet with specified Id and user id is not in the
list.public static <T extends ResCloudlet> int indexOf(java.util.List<T> list, int cloudletId, int userId)
cloudletId - a Cloudlet IduserId - an User Idlist - the list-1 if the list does not contain this Cloudlet.public static <T extends ResCloudlet> boolean move(java.util.List<T> listFrom, java.util.List<T> listTo, T cloudlet)
listFrom - the list fromlistTo - the list tocloudlet - the cloudletpublic static <T extends ResCloudlet> int getPositionById(java.util.List<T> cloudletList, int id)
cloudletList - - the list of cloudlets.id - - the id we search for.