Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/tghamm/dynamic-linq-query-builder
A truly generic and dynamic linq query builder to compliment jQuery QueryBuilder and other dynamic linq query generation needs
https://github.com/tghamm/dynamic-linq-query-builder
Last synced: 2 months ago
JSON representation
A truly generic and dynamic linq query builder to compliment jQuery QueryBuilder and other dynamic linq query generation needs
- Host: GitHub
- URL: https://github.com/tghamm/dynamic-linq-query-builder
- Owner: tghamm
- License: mit
- Created: 2015-12-06T03:50:59.000Z (about 9 years ago)
- Default Branch: master
- Last Pushed: 2024-10-09T01:17:42.000Z (3 months ago)
- Last Synced: 2024-11-14T09:05:20.668Z (2 months ago)
- Language: C#
- Homepage:
- Size: 2.01 MB
- Stars: 262
- Watchers: 17
- Forks: 110
- Open Issues: 12
-
Metadata Files:
- Readme: README.md
- License: LICENSE.md
Awesome Lists containing this project
- Awesome-Nuget-Packages - **Castle.DynamicLinqQueryBuilder**
README
# Dynamic Linq Query Builder
[![.NET](https://github.com/tghamm/dynamic-linq-query-builder/actions/workflows/dotnet.yml/badge.svg)](https://github.com/tghamm/dynamic-linq-query-builder/actions/workflows/dotnet.yml) [![Coverage Status](https://coveralls.io/repos/github/tghamm/dynamic-linq-query-builder/badge.svg?branch=master)](https://coveralls.io/github/tghamm/dynamic-linq-query-builder?branch=master) [![Nuget](https://img.shields.io/nuget/dt/Castle.DynamicLinqQueryBuilder)](https://www.nuget.org/packages/Castle.DynamicLinqQueryBuilder/)`dynamic-linq-query-builder` is a small library that allows any `.Net` framework class collection to be filtered dynamically at runtime.
Features (v1.3.4)
--
* Generates an `IQueryable` from any collection and filter combination
* Capable of complex, grouped queries against as many fields as you want
* Supports nested objects and collections via dot notation
* Supports ORMs like `EF6`, `EFCore`, and `MongoDB Client >=2.19`
* Supports a number of operators for each type
* in
* not in
* equal
* not equal
* between
* not between
* less
* less or equal
* greater
* greater or equal
* begins with
* not begins with
* contains
* not contains
* ends with
* not ends with
* is empty
* is not empty
* is null
* is not null
* custom operators via interface and options
* Compatible with [jQuery QueryBuilder](https://querybuilder.js.org) (see samples for an example)* Targets .NET 4.5, .NET Standard 2.0, .NET 6, and .NET 8
Installation
--
`dynamic-linq-query-builder` can be installed via the nuget UI (as Castle.DynamicLinqQueryBuilder), or via the nuget package manager console:
```
PM> Install-Package Castle.DynamicLinqQueryBuilder
```
To Install the System.Text.Json extension:
--
`dynamic-linq-query-builder-system-text-json` can be installed via the nuget UI (as Castle.DynamicLinqQueryBuilder.SystemTextJson), or via the nuget package manager console:
```
PM> Install-Package Castle.DynamicLinqQueryBuilder.SystemTextJson
```Getting Started
--
The easiest way to get started is to install the NuGet package and take a look at the MVC sample application included in the source code. It contains a working example of both `dynamic-linq-query-builder` and `jQuery-QueryBuilder`.Additionally, see the [Wiki](https://github.com/tghamm/dynamic-linq-query-builder/wiki)
Contributions
--
Contributions and pull requests are welcome with associated unit tests.