Class ShutdownEnumerableExtensions
- Namespace
- MonkeyLoader.Meta
- Assembly
- MonkeyLoader.dll
Contains extension methods for collections of IShutdown instances.
public static class ShutdownEnumerableExtensions
- Inheritance
-
ShutdownEnumerableExtensions
- Inherited Members
Methods
ShutdownAll(IEnumerable<IShutdown>, bool)
Calls the Shutdown(bool) method on all elements of the collection, aggregating their success state as an 'all'.
public static bool ShutdownAll(this IEnumerable<IShutdown> shutdowns, bool applicationExiting)
Parameters
shutdowns
IEnumerable<IShutdown>The IShutdown instances to process.
applicationExiting
boolWhether the shutdown was caused by the application exiting.
Returns
- bool
true
if all instances successfully shut down,false
otherwise.
Remarks
Already shut down elements are ignored.