ReSight.Core.Search 1.7.0

dotnet add package ReSight.Core.Search --version 1.7.0
                    
NuGet\Install-Package ReSight.Core.Search -Version 1.7.0
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="ReSight.Core.Search" Version="1.7.0" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="ReSight.Core.Search" Version="1.7.0" />
                    
Directory.Packages.props
<PackageReference Include="ReSight.Core.Search" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add ReSight.Core.Search --version 1.7.0
                    
#r "nuget: ReSight.Core.Search, 1.7.0"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package ReSight.Core.Search@1.7.0
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=ReSight.Core.Search&version=1.7.0
                    
Install as a Cake Addin
#tool nuget:?package=ReSight.Core.Search&version=1.7.0
                    
Install as a Cake Tool

ReSight.Core.Search

The ReSight.Core.Search library is designed to enhance search functionality in .NET applications. It provides a robust set of classes for building dynamic search queries, including support for filters, sorting, and field selection. This library aims to simplify the construction of complex search criteria, making it easier to implement advanced search features.

Features

  1. Dynamic Filter Creation: Easily create filters based on field names, comparison operators, and values.
  2. Operator Support: Includes a comprehensive set of operators for expressing search conditions.
  3. Sorting: Define sorting keys with ascending or descending order.
  4. Field Selection: Specify which fields to include in your search results.
  5. Expression Support: Use expressions to specify fields and values for type-safe queries.

Getting Started

Installation

This library is conceptual and meant to be included in your .NET projects as a shared library or as part of your solution. It is available as a NuGet package, you can add it through:

dotnet add package ReSight.Core.Search

Usage

  1. Creating Filters

    You can create filters for your queries using the Filter<T> or Filter<T, TValue> classes:

    using ReSight.Core.Search;
    
    var filter = new Filter<string>("FieldName", Operator.Equal, "Value");
    

    For type-safe filters based on expressions:

    var typeSafeFilter = new Filter<MyClass, string>(x => x.MyField, Operator.Like, "%value%");
    
  2. Building a Query Request

    Combine multiple filters, specify fields, and define sorting to create a QueryRequest:

    var queryRequest = new QueryRequest
    {
       Fields = new List<string> { "Field1", "Field2" },
       Filters = new List<IFilter> { filter, typeSafeFilter },
       Sort = new List<SortKey> { new SortKey("Field1", SortOrder.Ascending) }
    };
    

License

This project is licensed under the MIT License.

Product Compatible and additional computed target framework versions.
.NET net6.0 is compatible.  net6.0-android was computed.  net6.0-ios was computed.  net6.0-maccatalyst was computed.  net6.0-macos was computed.  net6.0-tvos was computed.  net6.0-windows was computed.  net7.0 was computed.  net7.0-android was computed.  net7.0-ios was computed.  net7.0-maccatalyst was computed.  net7.0-macos was computed.  net7.0-tvos was computed.  net7.0-windows was computed.  net8.0 is compatible.  net8.0-android was computed.  net8.0-browser was computed.  net8.0-ios was computed.  net8.0-maccatalyst was computed.  net8.0-macos was computed.  net8.0-tvos was computed.  net8.0-windows was computed.  net9.0 was computed.  net9.0-android was computed.  net9.0-browser was computed.  net9.0-ios was computed.  net9.0-maccatalyst was computed.  net9.0-macos was computed.  net9.0-tvos was computed.  net9.0-windows was computed.  net10.0 was computed.  net10.0-android was computed.  net10.0-browser was computed.  net10.0-ios was computed.  net10.0-maccatalyst was computed.  net10.0-macos was computed.  net10.0-tvos was computed.  net10.0-windows was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
1.7.0 1,981 4/28/2025
1.6.0 967 10/9/2024
1.5.0 670 9/14/2024
1.4.4 1,063 4/24/2024
1.4.3 227 4/24/2024
1.4.2 220 4/24/2024
1.4.0 216 4/24/2024
1.3.1 280 3/21/2024
1.3.0 217 3/21/2024
1.2.1 440 2/2/2024
1.2.0 264 3/21/2024
1.1.3 561 6/22/2023