Esempio n. 1
0
 public static uint MemoryLoad()
 {
     Win32.MEMORYSTATUSEX memStatus = new Win32.MEMORYSTATUSEX();
       if (Win32.GlobalMemoryStatusEx(memStatus))
     return memStatus.dwMemoryLoad;
       else
     return 0;
 }
Esempio n. 2
0
 public static uint MemoryLoad()
 {
     Win32.MEMORYSTATUSEX memStatus = new Win32.MEMORYSTATUSEX();
     if (Win32.GlobalMemoryStatusEx(memStatus))
     {
         return(memStatus.dwMemoryLoad);
     }
     else
     {
         return(0);
     }
 }
Esempio n. 3
0
 public static ulong TotalSystemRAM()
 {
     Win32.MEMORYSTATUSEX memStatus = new Win32.MEMORYSTATUSEX();
     if (Win32.GlobalMemoryStatusEx(memStatus))
     {
         // round up to nearest GB
         ulong RAM       = memStatus.ullTotalPhys;
         ulong remainder = RAM % ONE_GB;
         if (remainder == 0)
         {
             return(RAM);
         }
         else
         {
             return(RAM + ONE_GB - remainder);
         }
     }
     else
     {
         return(0);
     }
 }
Esempio n. 4
0
 public static ulong TotalSystemRAM()
 {
     Win32.MEMORYSTATUSEX memStatus = new Win32.MEMORYSTATUSEX();
       if (Win32.GlobalMemoryStatusEx(memStatus)) {
     // round up to nearest GB
     ulong RAM = memStatus.ullTotalPhys;
     ulong remainder = RAM % ONE_GB;
     if (remainder == 0)
       return RAM;
     else
       return (RAM + ONE_GB - remainder);
       }
       else
     return 0;
 }