Git Product home page Git Product logo

fredatgithub / .netlinqautofilterer Goto Github PK

View Code? Open in Web Editor NEW

This project forked from enisn/autofilterer

0.0 2.0 0.0 4.94 MB

AutoFilterer is a mini filtering framework library for dotnet. The main purpose of the library is to generate LINQ expressions for Entities over DTOs automatically. The first aim is to be compatible with Open API 3.0 Specifications

License: MIT License

C# 99.40% Dockerfile 0.60%

.netlinqautofilterer's Introduction

Logo

AutoFilterer

AutoFilterer is a mini filtering framework library for dotnet. The main purpose of the library is to generate LINQ expressions for Entities over DTOs automatically. Creating queries without writing any expression code is the most powerful feature that is provided. The first aim of AutoFilterer is to be compatible with Open API 3.0 Specifications, unlike oData & GraphQL.

This library does not generate database queries directly. It generates LINQ Expressions.

You can check Documentation for getting started.

Nuget Docs CodeFactor .NET Pipeline Gitmoji

Getting Started

  • Install AutoFilterer NuGet package from here.

Vsit visit documentation to learn how to use AutoFilterer.

โ†—๏ธ Open in Visual Studio Code


Showcase

TRY LIVE DEMO now.

autofilterer showcase


Usage

A quick example is presented below. Reading documentation is highly recommended for detailed features.

  • Create a filter model and make sure property names match to Entity properties.
public class ProductFilter : PaginationFilterBase
{
  public Range<double> Price { get; set; }

  [ToLowerContainsComparison]
  public string Name { get; set; }
  
  [StringFilteringOptions(StringFilterOption.Equals)]
  public string Locale { get; set; }
}
  public IActionResult GetProducts([FromQuery]ProductFilter filter)
  {
    var products = db.Products.ApplyFilter(filter).ToList();
    return Ok(products);
  }

Don't forget to visit Wiki for better understanding of usage.


AutoFilterer.Swagger

All parameters support OpenAPI 3.0 Specifications ๐Ÿ‘

Improve your swagger documentation via using AutoFilterer.Swagger


AutoFilterer.Generators

AutoFilterer.Generators aims to generate filter objects from entities automatically via using dotnet source generators.

Visit documentation of Generators


Performance

See Benchmark Results from here


Stats

Alt

.netlinqautofilterer's People

Contributors

enisn avatar furkandeveloper avatar mehmetuken avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.