IVSoftware.Portable.SQLiteMarkdown 1.0.0-beta1

Prefix Reserved
This is a prerelease version of IVSoftware.Portable.SQLiteMarkdown.
There is a newer version of this package available.
See the version list below for details.
dotnet add package IVSoftware.Portable.SQLiteMarkdown --version 1.0.0-beta1
                    
NuGet\Install-Package IVSoftware.Portable.SQLiteMarkdown -Version 1.0.0-beta1
                    
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="IVSoftware.Portable.SQLiteMarkdown" Version="1.0.0-beta1" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="IVSoftware.Portable.SQLiteMarkdown" Version="1.0.0-beta1" />
                    
Directory.Packages.props
<PackageReference Include="IVSoftware.Portable.SQLiteMarkdown" />
                    
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 IVSoftware.Portable.SQLiteMarkdown --version 1.0.0-beta1
                    
#r "nuget: IVSoftware.Portable.SQLiteMarkdown, 1.0.0-beta1"
                    
#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 IVSoftware.Portable.SQLiteMarkdown@1.0.0-beta1
                    
#: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=IVSoftware.Portable.SQLiteMarkdown&version=1.0.0-beta1&prerelease
                    
Install as a Cake Addin
#tool nuget:?package=IVSoftware.Portable.SQLiteMarkdown&version=1.0.0-beta1&prerelease
                    
Install as a Cake Tool

Expression Parsing Documentation

This README outlines the operators and rules for parsing expressions in a custom search language. The operators follow a standard order of operations and offer flexible syntax for various logical expressions.

Table of Contents

  1. Operators
  2. Escaped Operators
  3. Logical Operators
  4. Atomic Term Operators

Operators

Operators adhere to the standard order of operations, with PARENTHESES providing the functionality to override the default precedence.

Escaped Operators

The following characters can be escaped to be treated as literals in expressions:

  • \&, \|, \!, \(, \), \', \", "", ''

Logical Operators

AND Operator

The AND operation can be represented in several ways:

  • A single & character.
  • A single space .
  • Any consecutive string of & and space characters.

Examples:

  • "Term1 Term2" is interpreted as "Term1&Term2".
  • "Term1 & Term2" is interpreted as "Term1&Term2".

OR Operator

The OR operation can be represented as:

  • A single | character.
  • Any consecutive string of | characters and spaces.

Examples:

  • "Term1 | Term2" is interpreted as "Term1|Term2".
  • "Term1||Term2" is interpreted as "Term1|Term2".

NOT Operator

The NOT operation can be represented as:

  • A single ! character.
  • Any consecutive string of ! characters.

Examples:

  • "Term1 !Term2" is interpreted as "Term1&!Term2".
  • "Term1 !(Term2 | Term3)" is interpreted as "Term1&!(Term2|Term3)".

Linting Requirements

Expressions must be formatted to avoid consecutive identical operators or conflicting operators, such as &|.


Atomic Term Operators

TAG

Expressions that include tokens enclosed in square brackets ([ and ]) are treated as tags.

Special Rule

While a user is entering a search term, the parser is invoked any time the input delay settles. During this process:

  • Unmatched square brackets (either an opening [ without a closing ], or vice versa) are considered to be literal characters and are included in LIKE and FILTER expressions without interpretation as tags.

Single Quotes

Single quotes (') are used to define atomic (exact match) terms.

  • Quotes must appear in pairs to be interpreted as atomic delimiters.
  • If an expression contains a single quote, it is treated as a literal and included in the search term.
  • Consecutive single quotes ('') are interpreted as an escaped quote.
  • During incremental input (e.g. debounced typing), a trailing unpaired quote is always treated as a literal to preserve user intent mid-expression.

Double Quotes

Double quotes (") follow the same rules as single quotes.

  • Must appear in pairs to define atomic terms.
  • A lone double quote is treated as a literal character.
  • "" is interpreted as an escaped double quote.
  • During incremental input, a trailing unpaired quote is always treated as literal.

By following these rules, expressions can be parsed flexibly and safely�even while a user is still typing.


ObservableQueryFilterSource

Drop-in replacement for ObservableCollection<T> with built-in support for both Query and Query-then-Filter workflows. It exposes a declarative interface for managing collection state while tracking query/filter intent via an internal FSM (QueryFilterStateTracker). Though UI-agnostic, the class anticipates integration with a navigation search bar, where queries are externally applied and subsequent in-memory filtering is handled via an embedded SQLite store. This enables persistent introspection of the original query, filtered/unfiltered results, and search metadata�all without any UI dependencies.

ObservableQueryFilterSource


SelfIndexing Class

The SelfIndexing class enables automatic generation of SQL search terms from property values using simple attribute annotations. It tracks changes in data, defers processing intelligently, and maintains up-to-date searchable terms (LikeTerm, ContainsTerm, TagMatchTerm) for fast, expression-based querying over markdown-bound SQLite objects.

To use it, inherit from SelfIndexed, apply [PrimaryKey] to your ID property, and annotate other properties with [SelfIndexed(...)] to control how they contribute to indexing and persistence.

SelfIndexing

Product Compatible and additional computed target framework versions.
.NET net5.0 was computed.  net5.0-windows was computed.  net6.0 was computed.  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 was computed.  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. 
.NET Core netcoreapp2.0 was computed.  netcoreapp2.1 was computed.  netcoreapp2.2 was computed.  netcoreapp3.0 was computed.  netcoreapp3.1 was computed. 
.NET Standard netstandard2.0 is compatible.  netstandard2.1 was computed. 
.NET Framework net461 was computed.  net462 was computed.  net463 was computed.  net47 was computed.  net471 was computed.  net472 was computed.  net48 was computed.  net481 was computed. 
MonoAndroid monoandroid was computed. 
MonoMac monomac was computed. 
MonoTouch monotouch was computed. 
Tizen tizen40 was computed.  tizen60 was computed. 
Xamarin.iOS xamarinios was computed. 
Xamarin.Mac xamarinmac was computed. 
Xamarin.TVOS xamarintvos was computed. 
Xamarin.WatchOS xamarinwatchos 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.0.0 111 7/12/2025
1.0.0-rc1 71 7/4/2025
1.0.0-beta1 150 6/22/2025
1.0.0-beta 125 6/21/2025

Initial alpha release 1.0.0:
- Includes markdown serialization and binding to SQLite via sqlite-net-pcl.
- Supports IVSoftware.Portable.Threading and XBoundObject integration.
- Includes support for both Newtonsoft.Json and System.Text.Json.
Initial alpha1 release 1.0.0:
- Unit Testing
- Atomic single and double quotes now fully supported.
Initial alpha2 release 1.0.0:
- ObservableQueryFilterSource preliminary Unit Testing
- FSOL ApplyFilter using memory SQLITE scheme.
- IObservableQueryFilterSource integration of [Obsolete] IQueryFilterStateTracker is complete and functional.
Upgraded to beta release 1.0.0:
- The GitHub repo is public now with a preliminary WinForms example.
- The interface is becoming stable but until an RC version posts the interface contract should be considered probationary.
- For the adventurous, the intent is starting to be clear enough to be potentially useful.
- ADVISORY: Unit Testing is clean in DEBUG mode but the atomic string parsing fails two tests in release mode. Avoid atomic string parsing for now.
Beta Release + 1
- ADVISORY: This is 'not' a released bundle.
- Unit Tests @ 16 are passing handily now in RELEASE mode. (A critical expr assignment was being done inside a #DEBUG block.)