@@ -37,15 +37,15 @@ internal sealed class RamController : IDisposable
3737 /// </summary>
3838 private readonly ComputerInfo _info ;
3939 /// <summary>
40- /// The list of processes that should be excluded from memory optimisation
40+ /// The list of processes that should be excluded from memory optimization
4141 /// </summary>
4242 private List < string > _processExceptionList ;
4343 /// <summary>
44- /// An integer value representative of the percentage of RAM usage that should be reached before RAM optimisation should be called
44+ /// An integer value representative of the percentage of RAM usage that should be reached before RAM optimization should be called
4545 /// </summary>
4646 private double _autoOptimizeRamThreshold ;
4747 /// <summary>
48- /// The last time automatic RAM optimisation was called in terms of RAM percentage threshold settings
48+ /// The last time automatic RAM optimization was called in terms of RAM percentage threshold settings
4949 /// </summary>
5050 private DateTime _lastAutoOptimizeTime ;
5151 #endregion
@@ -64,7 +64,7 @@ internal sealed class RamController : IDisposable
6464 /// </summary>
6565 internal double RamTotal { get ; private set ; }
6666 /// <summary>
67- /// Property containing how much RAM was saved during the last optimisation
67+ /// Property containing how much RAM was saved during the last optimization
6868 /// </summary>
6969 internal double RamSavings { get ; private set ; }
7070 /// <summary>
@@ -76,15 +76,15 @@ internal sealed class RamController : IDisposable
7676 /// </summary>
7777 internal bool EmptyWorkingSets { get ; set ; }
7878 /// <summary>
79- /// Property displaying whether the FileSystem cache should be cleared or not during memory optimisation
79+ /// Property displaying whether the FileSystem cache should be cleared or not during memory optimization
8080 /// </summary>
8181 internal bool ClearFileSystemCache { get ; set ; }
8282 /// <summary>
83- /// Property displaying whether the standby cache should be cleared or not during memory optimisation
83+ /// Property displaying whether the standby cache should be cleared or not during memory optimization
8484 /// </summary>
8585 internal bool ClearStandbyCache { get ; set ; }
8686 /// <summary>
87- /// Property displaying whether automatic RAM optimisation should occur after a certain RAM usage percentage was reached
87+ /// Property displaying whether automatic RAM optimization should occur after a certain RAM usage percentage was reached
8888 /// </summary>
8989 internal bool AutoOptimizePercentage { get ; set ; }
9090 /// <summary>
@@ -101,7 +101,7 @@ internal sealed class RamController : IDisposable
101101 /// <summary>
102102 /// Event that is called when RAM clearing has occurred
103103 /// </summary>
104- private event RamClearingCompleted RamClearingCompletedEvcent ;
104+ private event RamClearingCompleted RamClearingCompletedEvent ;
105105 /// <summary>
106106 /// Delegate void that indicates that a GUI update should occur when called
107107 /// </summary>
@@ -116,17 +116,17 @@ internal sealed class RamController : IDisposable
116116 /// Initialize a new RamController object
117117 /// </summary>
118118 /// <param name="updateGuiStatisticsEvent">An event to indicate that a GUI update should occur</param>
119- /// <param name="ramClearingCompletedEvcent ">An event to indicate that the RAM has been cleared</param>
119+ /// <param name="ramClearingCompletedEvent ">An event to indicate that the RAM has been cleared</param>
120120 /// <param name="ramUpdateTimerInterval">The interval for which RAM usage statistics should be updated</param>
121121 /// <param name="logController">The LogController object that can be used to add logs</param>
122- internal RamController ( UpdateGuiStatistics updateGuiStatisticsEvent , RamClearingCompleted ramClearingCompletedEvcent , int ramUpdateTimerInterval , LogController logController )
122+ internal RamController ( UpdateGuiStatistics updateGuiStatisticsEvent , RamClearingCompleted ramClearingCompletedEvent , int ramUpdateTimerInterval , LogController logController )
123123 {
124124 _logController = logController ?? throw new ArgumentNullException ( nameof ( logController ) ) ;
125125 _logController . AddLog ( new ApplicationLog ( "Initializing RamController" ) ) ;
126126
127127 if ( ramUpdateTimerInterval <= 0 ) throw new ArgumentException ( "Timer interval cannot be less than or equal to zero!" ) ;
128128 UpdateGuiStatisticsEvent = updateGuiStatisticsEvent ?? throw new ArgumentNullException ( nameof ( updateGuiStatisticsEvent ) ) ;
129- RamClearingCompletedEvcent = ramClearingCompletedEvcent ?? throw new ArgumentNullException ( nameof ( ramClearingCompletedEvcent ) ) ;
129+ RamClearingCompletedEvent = ramClearingCompletedEvent ?? throw new ArgumentNullException ( nameof ( ramClearingCompletedEvent ) ) ;
130130
131131 RamSavings = 0 ;
132132
@@ -146,7 +146,7 @@ internal RamController(UpdateGuiStatistics updateGuiStatisticsEvent, RamClearing
146146 }
147147
148148 /// <summary>
149- /// Set the threshold percentage for automatic RAM optimisation
149+ /// Set the threshold percentage for automatic RAM optimization
150150 /// </summary>
151151 /// <param name="threshold">The percentage threshold</param>
152152 internal void SetAutoOptimizeThreshold ( double threshold )
@@ -156,10 +156,10 @@ internal void SetAutoOptimizeThreshold(double threshold)
156156 }
157157
158158 /// <summary>
159- /// Enable or disable automatic timed RAM optimisation
159+ /// Enable or disable automatic timed RAM optimization
160160 /// </summary>
161- /// <param name="enabled">A boolean to indicate whether automatic RAM optimisation should occur or not</param>
162- /// <param name="interval">The interval for automatic RAM optimisation </param>
161+ /// <param name="enabled">A boolean to indicate whether automatic RAM optimization should occur or not</param>
162+ /// <param name="interval">The interval for automatic RAM optimization </param>
163163 internal void AutoOptimizeTimed ( bool enabled , int interval )
164164 {
165165 if ( _ramAutoOptimizeTimer == null )
@@ -183,9 +183,9 @@ private async void RamAutoOptimizeTimerOnElapsed(object sender, ElapsedEventArgs
183183 }
184184
185185 /// <summary>
186- /// Set the list of processes that should excluded from RAM optimisation
186+ /// Set the list of processes that should excluded from RAM optimization
187187 /// </summary>
188- /// <param name="processExceptionList">The list of processes that should be excluded from RAM optimisation </param>
188+ /// <param name="processExceptionList">The list of processes that should be excluded from RAM optimization </param>
189189 internal void SetProcessExceptionList ( List < string > processExceptionList )
190190 {
191191 _processExceptionList = processExceptionList ;
@@ -194,7 +194,7 @@ internal void SetProcessExceptionList(List<string> processExceptionList)
194194 /// <summary>
195195 /// Set the interval for the RAM Monitor updates
196196 /// </summary>
197- /// <param name="interval">The amount of miliseconds before an update should occur</param>
197+ /// <param name="interval">The amount of milliseconds before an update should occur</param>
198198 internal void SetRamUpdateTimerInterval ( int interval )
199199 {
200200 _ramTimer . Interval = interval ;
@@ -284,7 +284,7 @@ await Task.Run(async () =>
284284 Clipboard . Clear ( ) ;
285285 }
286286
287- RamClearingCompletedEvcent . Invoke ( ) ;
287+ RamClearingCompletedEvent . Invoke ( ) ;
288288
289289 _logController . AddLog ( new ApplicationLog ( "Done clearing RAM memory" ) ) ;
290290 }
@@ -315,7 +315,7 @@ await Task.Run(async () =>
315315 RamSavings = oldUsage - newUsage ;
316316 } ) ;
317317
318- RamClearingCompletedEvcent . Invoke ( ) ;
318+ RamClearingCompletedEvent . Invoke ( ) ;
319319
320320 _logController . AddLog ( new ApplicationLog ( "Done clearing process working sets" ) ) ;
321321 }
@@ -344,7 +344,7 @@ await Task.Run(() =>
344344 RamSavings = oldUsage - newUsage ;
345345 } ) ;
346346
347- RamClearingCompletedEvcent . Invoke ( ) ;
347+ RamClearingCompletedEvent . Invoke ( ) ;
348348
349349 _logController . AddLog ( new ApplicationLog ( "Done clearing FileSystem cache" ) ) ;
350350 }
@@ -358,10 +358,10 @@ private void UpdateRamUsage()
358358
359359 double total = Convert . ToDouble ( _info . TotalPhysicalMemory ) ;
360360 double usage = total - Convert . ToDouble ( _info . AvailablePhysicalMemory ) ;
361- double perc = usage / total * 100 ;
361+ double percentage = usage / total * 100 ;
362362
363363 RamUsage = usage ;
364- RamUsagePercentage = perc ;
364+ RamUsagePercentage = percentage ;
365365 RamTotal = total ;
366366
367367 if ( RamUsagePercentage >= _autoOptimizeRamThreshold && AutoOptimizePercentage )
0 commit comments