Ejemplo n.º 1
0
        public static VmPathInfo[] GetVmPathInfoParallel(IVm[] vms, VmPathInfoToExclude infoToExclude)
        {
            ConcurrentBag <VmPathInfo> coll = new ConcurrentBag <VmPathInfo>();

            Parallel.ForEach <IVm>((IEnumerable <IVm>)vms, (Action <IVm>)(vm => coll.Add(vm.GetVmPathInfo(infoToExclude))));
            return(coll.ToArray());
        }
Ejemplo n.º 2
0
 public VmPathInfo[] GetPathInfoParallel(string[] vms, VmPathInfoToExclude vmPathInfoToExclude)
 {
     return(HyperVServiceCommon.GetVmPathInfoParallel(this.GetVms(vms), vmPathInfoToExclude));
 }
Ejemplo n.º 3
0
 public VmPathInfo[] GetAllVmPathInfoParallel(VmPathInfoToExclude vmPathInfoToExclude)
 {
     return(HyperVServiceCommon.GetVmPathInfoParallel(this.GetAllVms().ToArray <IVm>(), vmPathInfoToExclude));
 }