Interface CloudletTaskScheduler

    • Method Detail

      • getVm

        Vm getVm()
        Gets the Vm that the CloudletTaskScheduler will sent packets from or receive packets to.
        Returns:
      • setVm

        void setVm​(Vm vm)
        Sets the Vm that the CloudletTaskScheduler will sent packets from or receive packets to. It is not required to manually set a Vm for the CloudletTaskScheduler, since the NetworkHost does it when it creates a Vm.
        Parameters:
        vm - the Vm to set
      • clearVmPacketsToSend

        void clearVmPacketsToSend()
        Clears the list of VmPacket's to send from the Vm of this scheduler to other VMs.
      • getVmPacketsToSend

        List<VmPacket> getVmPacketsToSend()
        Gets a read-only list of VmPacket's to send from the Vm of this scheduler to other VMs.
        Returns:
        a read-only VmPacket list
      • addPacketToListOfPacketsSentFromVm

        boolean addPacketToListOfPacketsSentFromVm​(VmPacket pkt)
        Adds a packet to the list of packets sent by a given VM, targeting the VM of this scheduler. The source VM is got from the packet.
        Parameters:
        pkt - packet to be added to the list
        Returns:
        true if the packet was added, false otherwise
      • processCloudletTasks

        void processCloudletTasks​(Cloudlet cloudlet,
                                  long partialFinishedMI)
        Process Cloudlet's tasks, such as tasks to send packets from or received by a Cloudlet inside a VM.
        Parameters:
        cloudlet - the Cloudlet to process packets
        partialFinishedMI - the partial executed length of this Cloudlet (in MI)
      • isTimeToUpdateCloudletProcessing

        boolean isTimeToUpdateCloudletProcessing​(Cloudlet cloudlet)
        Checks if it's time to update the execution of a given Cloudlet. If the Cloudlet is waiting for packets to be sent or received, then it isn't time to update its processing.
        Parameters:
        cloudlet - the Cloudlet to check if it is time to update its execution
        Returns:
        true if its timie to update Cloudlet execution, false otherwise.