cloudsim-plus-master/cloudsim-plus-master/cloudsim-plus/src/main/java/org/cloudbus/cloudsim/datacenters/DatacenterSimple.java
protected boolean processVmCreate(final SimEvent ev, final boolean ackRequested) {
        final Vm vm = (Vm) ev.getData();

        final boolean hostAllocatedForVm = vmAllocationPolicy.allocateHostForVm(vm);

        if (ackRequested) {
            send(vm.getBroker().getId(), getSimulation().getMinTimeBetweenEvents(), CloudSimTags.VM_CREATE_ACK, vm);
        }

        if (hostAllocatedForVm) {
            if (!vm.isCreated()) {
                vm.setCreated(true);
            }

            final List<Double> mipsList = vm.getHost().getVmScheduler().getAllocatedMips(vm);
            vm.updateProcessing(getSimulation().clock(), mipsList);
        }

        return hostAllocatedForVm;
    }
/**
     * Process the event for a Broker which wants to create a VM in this
     * Datacenter. This Datacenter will then send the status back to
     * the Broker.
     *
     * @param ev information about the event just happened
     * @param ackRequested indicates if the event's sender expects to receive an
     * acknowledge message when the event finishes to be processed
     * @return true if a host was allocated to the VM; false otherwise
     *
     * @pre ev != null
     * @post $none
     */
Process the event for a Broker which wants to create a VM in this
Datacenter. This Datacenter will then send the status back to
the Broker.

@param ev information about the event just happened
@param ackRequested indicates if the event's sender expects to receive an
acknowledge message when the event finishes to be processed
@return true if a host was allocated to the VM; false otherwise

@pre ev != null
@post $none
Process the event for a Broker which wants to create a VM in this Datacenter . This Datacenter will then send the status back to the Broker . @param ev information about the event just happened @param ackRequested indicates if the event ' s sender expects to receive an acknowledge message when the event finishes to be processed @return true if a host was allocated to the VM ; false otherwise @pre ev ! = null @post $none
protected boolean processVmCreate(final SimEvent ev, final boolean ackRequested) {
        final Vm vm = (Vm) ev.getData();
        final boolean hostAllocatedForVm = vmAllocationPolicy.allocateHostForVm(vm);
        if (ackRequested) {
            send(vm.getBroker().getId(), getSimulation().getMinTimeBetweenEvents(), CloudSimTags.VM_CREATE_ACK, vm);
        }
        if (hostAllocatedForVm) {
            if (!vm.isCreated()) {
                vm.setCreated(true);
            }
            final List<Double> mipsList = vm.getHost().getVmScheduler().getAllocatedMips(vm);
            vm.updateProcessing(getSimulation().clock(), mipsList);
        }
        return hostAllocatedForVm;
    }
protected boolean processVmCreate ( final SimEvent ev , final boolean ackRequested ) { final Vm vm = ( Vm ) ev . getData ( ) ; final boolean hostAllocatedForVm = vmAllocationPolicy . allocateHostForVm ( vm ) ; if ( ackRequested ) { send ( vm . getBroker ( ) . getId ( ) , getSimulation ( ) . getMinTimeBetweenEvents ( ) , CloudSimTags . VM_CREATE_ACK , vm ) ; } if ( hostAllocatedForVm ) { if ( ! vm . isCreated ( ) ) { vm . setCreated ( true ) ; } final List < Double > mipsList = vm . getHost ( ) . getVmScheduler ( ) . getAllocatedMips ( vm ) ; vm . updateProcessing ( getSimulation ( ) . clock ( ) , mipsList ) ; } return hostAllocatedForVm ; }
Process the event for a Broker which wants to create a VM in this
 Datacenter.
Process the event for a Broker which wants to create a VM in this Datacenter .