Action.Hook
Constructor and Description |
---|
Allocate(VM vm,
Node on,
String rc,
int amount,
int start,
int end)
Make a new constraint.
|
Modifier and Type | Method and Description |
---|---|
boolean |
applyAction(Model i)
Apply only the scheduled action.
|
boolean |
equals(Object o) |
int |
getAmount()
Get the amount of resources to allocate to the VM.
|
Node |
getHost()
Get the node that is currently hosting the VM.
|
String |
getResourceId()
Get the resource identifier.
|
VM |
getVM()
Get the VM to involved in the action.
|
int |
hashCode() |
String |
pretty()
Pretty print of the action.
|
Object |
visit(ActionVisitor v)
Notify a visitor to visit the action.
|
addEvent, apply, applyEvents, getEnd, getEvents, getStart, toString
public Allocate(VM vm, Node on, String rc, int amount, int start, int end)
vm
- the VMon
- the node hosting the VMrc
- the resource identifieramount
- the minimum amount of resource to allocatestart
- the moment the action startsend
- the moment the action endspublic Node getHost()
public VM getVM()
VMEvent
public String getResourceId()
public int getAmount()
public boolean applyAction(Model i)
Action
applyAction
in class Action
i
- the model to modifytrue
if the action was applied successfullypublic Object visit(ActionVisitor v)
Event
Copyright © 2015 University of Nice-Sophia Antipolis. All Rights Reserved.