@Override
    public CustomerReceipt processOutgoingVehicle(int vehicleId, int departingTime, CustomerReceipt customerReceipt) throws OutgoingProcessException, VehicleOutOfBoundsException
    {
        
        DataObject vehicleDataObject = new DataObject();
        vehicleDataObject = getVehicleDataObject(vehicleId);
        vehicleDataObject.setDepartingTime(departingTime);
        int outgoingVehicleArrivalTime = vehicleDataObject.getArrivalTime();
        
        if(departingTime > 24 || departingTime <= outgoingVehicleArrivalTime)
        {
            throw new OutgoingProcessException("Exit time must be between " + (outgoingVehicleArrivalTime + 1) + " - 24.");
        }
        
        Vehicle outgoingVehicle = new Vehicle(vehicleId, outgoingVehicleArrivalTime);
        outgoingVehicle.setDepartingTime(departingTime);
        
        this.vehicles[vehicleId-1] = outgoingVehicle;
        
        customerReceipt.setDepartingTime(departingTime);
        customerReceipt.setHoursParked(departingTime - customerReceipt.getArrivalTime());
        
        HourlyParkingFeeStrategy feeEquation = customerReceipt.getHourlyParkingFeeStrategy();
        
        double hoursParked = customerReceipt.getHoursParked();
        double totalFee = feeEquation.getFeeAmount(hoursParked);
        
        customerReceipt.setTotalFee(totalFee);
        
        addToHoursCharged(hoursParked);
        addToMoneyCollected(totalFee);
        
        writeTotalsToFile();

                
        return customerReceipt;
    }