public bool IsValidMovement( bool withEat, int startRow, int startColumn, int endRow, int endColumn ) { var movement = new Movement { WithEat = withEat, StartX = startColumn, StartY = startRow, EndX = endColumn, EndY = endRow }; return Rules.Where( r => r.Validate( movement ) ).Any(); }
public bool Validate( Movement move ) { return !_predicates.Where( p => !p( move ) ).Any(); }