【C#】デリゲートが登録されているかどうかを返す拡張メソッド

ソースコード using System; public static class MulticastDelegateExtensions { public static bool IsNullOrEmpty( this MulticastDelegate self ) { if ( self == null || self.GetInvocationList() == null ) { return true; } return self.GetInvocationList().Length == 0; } } Action act = null; act.IsNullOrEmp…