Example #1
0
 public static void ExecuteIfNotSet(this IFlagStore self, string key, Action act)
 {
     if (!self.IsSet(key))
     {
         act();
     }
 }
Example #2
0
 public static void ExecuteIfSetThenUnset(this IFlagStore self, string key, Action act)
 {
     if (self.IsSet(key))
     {
         act();
         self.Unset(key);
     }
 }
Example #3
0
 public static void ExecuteIfSetOrNot(this IFlagStore self, string key, Action actIfYes, Action actIfNot)
 {
     if (self.IsSet(key))
     {
         actIfYes();
     }
     else
     {
         actIfNot();
     }
 }