Beispiel #1
0
 public static ClassRealtimeUsage getsUsage(ApplicationRealtimeUsage _applicationRealtimeUsage,
                                            ClassRealtimeUsage classRealtimeUsage)
 {
     _applicationRealtimeUsage.getNameMachine(classRealtimeUsage);
     _applicationRealtimeUsage.getUsageCPU(classRealtimeUsage);
     _applicationRealtimeUsage.getUsageRAM(classRealtimeUsage);
     return(classRealtimeUsage);
 }
        public ActionResult Index()
        {
            RepositoryRealtimeUsage  repositoryRealtimeUsage   = new RepositoryRealtimeUsage();
            ClassRealtimeUsage       classRealtimeUsage        = new ClassRealtimeUsage();
            ApplicationRealtimeUsage _applicationRealtimeUsage = new ApplicationRealtimeUsage(repositoryRealtimeUsage);



            while (true)
            {
                _applicationRealtimeUsage.getNameMachine(classRealtimeUsage);
                _applicationRealtimeUsage.getUsageCPU(classRealtimeUsage);
                _applicationRealtimeUsage.getUsageCPU(classRealtimeUsage);
                _applicationRealtimeUsage.getUsageRAM(classRealtimeUsage);
                Thread.Sleep(5000);
                return(View(classRealtimeUsage));
            }
        }