Class VmPacket

java.lang.Object
org.cloudbus.cloudsim.network.VmPacket
All Implemented Interfaces:
NetworkPacket<Vm>

public class VmPacket
extends java.lang.Object
implements NetworkPacket<Vm>
Represents a packet that travels from a Vm to another, through the virtual network within a Host. It contains information about Cloudlets which are communicating.

Please refer to following publication for more details:

Since:
CloudSim Toolkit 1.0
Author:
Saurabh Kumar Garg, Manoel Campos da Silva Filho
  • Constructor Summary

    Constructors 
    Constructor Description
    VmPacket​(Vm sourceVm, Vm destinationVm, long size, Cloudlet senderCloudlet, Cloudlet receiverCloudlet)
    Creates a packet to be sent to to a VM inside the Host of the sender VM.
  • Method Summary

    Modifier and Type Method Description
    Vm getDestination()
    Gets the id of the VM that has to receive the packet.
    Cloudlet getReceiverCloudlet()
    Gets the cloudlet that has to receive the packet.
    double getReceiveTime()
    Gets the time when the packet was received.
    Cloudlet getSenderCloudlet()
    Gets the cloudlet sending the packet.
    double getSendTime()
    Gets the time when the packet was sent.
    long getSize()
    Gets the size of the packet in bytes.
    Vm getSource()
    Gets the VM sending the packet.
    void setDestination​(Vm destinationVmId)
    Sets the id of the VM that has to receive the packet.
    void setReceiveTime​(double receiveTime)
    Sets the time when the packet was received.
    void setSendTime​(double sendTime)
    Sets the time when the packet was sent.
    void setSource​(Vm sourceVmId)
    Sets the id of the VM sending the packet.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait