private bool IsSame(ItemEventSignature other) { if (BeforeAction != other.BeforeAction) { return(false); } if (EventType != other.EventType) { return(false); } if (!ItemId.Equals(other.ItemId)) { return(false); } if (Modes.Count > 0 && !Modes.Intersect(other.Modes).Any()) { return(false); } if (ColumnIds.Count > 0 && !ColumnIds.Intersect(other.ColumnIds).Any()) { return(false); } return(true); }
private bool CanHandle(ItemEvent arg) { if (BeforeAction != arg.BeforeAction) { return(false); } if (EventType != arg.EventType) { return(false); } if (!ItemId.Equals(arg.ItemUID)) { return(false); } if (Modes.Count > 0 && !Modes.Contains((BoFormMode)arg.FormMode)) { return(false); } if (ColumnIds.Count > 0 && !ColumnIds.Contains(arg.ColUID)) { return(false); } return(true); }
public List <int> GetColumnIds() { return(string.IsNullOrEmpty(ColumnIds) ? new List <int>() : ColumnIds.Split('#').Select(int.Parse).ToList()); }