PhoenixmlDb.Core
1.7.0
See the version list below for details.
dotnet add package PhoenixmlDb.Core --version 1.7.0
NuGet\Install-Package PhoenixmlDb.Core -Version 1.7.0
<PackageReference Include="PhoenixmlDb.Core" Version="1.7.0" />
<PackageVersion Include="PhoenixmlDb.Core" Version="1.7.0" />
<PackageReference Include="PhoenixmlDb.Core" />
paket add PhoenixmlDb.Core --version 1.7.0
#r "nuget: PhoenixmlDb.Core, 1.7.0"
#:package PhoenixmlDb.Core@1.7.0
#addin nuget:?package=PhoenixmlDb.Core&version=1.7.0
#tool nuget:?package=PhoenixmlDb.Core&version=1.7.0
PhoenixmlDb.Core
Core types, interfaces, and XDM (XQuery Data Model) implementation for PhoenixmlDb — a modern embedded XML/JSON document database for .NET.
What's in this package
- Database interfaces —
IDocumentDatabase,IContainer,IDocumentfor storing and retrieving XML/JSON documents - XDM node types —
XdmElement,XdmAttribute,XdmDocument, etc. — the W3C XQuery Data Model - Transaction model —
IReadTransaction,IWriteTransactionwith MVCC snapshot isolation - Index configuration — path, value, full-text, and metadata indexes for fast queries
- XML parser and serializer — parse XML into XDM trees and serialize back
- Atomic value types — dates, times, durations, and other XSD types with correct semantics
When to use this package
Directly: If you're building a storage provider, query engine integration, or tooling that works with XDM types.
Indirectly: This package is a dependency of PhoenixmlDb.XQuery, PhoenixmlDb.Xslt, and the CLI tools. You typically don't reference it alone unless you need the core types without query/transform capabilities.
Quick example
using PhoenixmlDb.Core;
using PhoenixmlDb.Xdm.Parsing;
// Parse XML into an XDM tree
var parser = new XmlDocumentParser();
var result = parser.Parse("<order><item>Widget</item></order>");
var doc = result.Document;
// Navigate the tree
var root = doc.Children[0]; // <order> element
Console.WriteLine(root.StringValue); // "Widget"
Related packages
| Package | Description |
|---|---|
| PhoenixmlDb.XQuery | XQuery 4.0 query engine |
| PhoenixmlDb.Xslt | XSLT 4.0 transformation engine |
| PhoenixmlDb.XQuery.Cli | xquery command-line tool |
| PhoenixmlDb.Xslt.Cli | xslt command-line tool |
Documentation
Full documentation at phoenixml.dev
License
Apache 2.0
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | 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 is compatible. 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. |
-
net10.0
- No dependencies.
-
net8.0
- No dependencies.
NuGet packages (3)
Showing the top 3 NuGet packages that depend on PhoenixmlDb.Core:
| Package | Downloads |
|---|---|
|
PhoenixmlDb.XQuery
XQuery 4.0 query engine for PhoenixmlDb |
|
|
PhoenixmlDb.Xslt
XSLT 4.0 transformation engine for PhoenixmlDb |
|
|
Phoenixml.Platform.Editor.Xml
XML/XSD vocabulary binding for Phoenixml.Platform — concrete IDocument and ITreeNodeProvider implementations against PhoenixmlDb.Core's XDM, XSD schema validation pipeline. |
GitHub repositories
This package is not used by any popular GitHub repositories.
| Version | Downloads | Last Updated |
|---|---|---|
| 2.0.0 | 289 | 9/15/2026 |
| 1.7.0 | 900 | 9/11/2026 |
| 1.6.7 | 849 | 8/24/2026 |
| 1.6.6 | 187 | 8/23/2026 |
| 1.6.5 | 181 | 8/21/2026 |
| 1.6.0 | 162 | 8/7/2026 |
| 1.5.0 | 113 | 8/6/2026 |
| 1.4.0 | 108 | 8/4/2026 |
| 1.3.0 | 366 | 7/27/2026 |
| 1.2.2 | 298 | 7/9/2026 |
| 1.2.1 | 160 | 7/8/2026 |
| 1.2.0 | 333 | 6/28/2026 |
| 1.1.9 | 332 | 6/17/2026 |
| 1.1.8 | 211 | 6/14/2026 |
| 1.1.7 | 143 | 6/9/2026 |
| 1.1.6 | 121 | 6/9/2026 |
| 1.1.5 | 326 | 5/23/2026 |
| 1.1.4 | 424 | 5/17/2026 |
| 1.1.3 | 173 | 5/14/2026 |
| 1.1.2 | 232 | 5/12/2026 |
Minor rather than patch: this adds public API.
### Added
- **`XdmNode.StringValueResolver`** — a supported way for a storage layer to supply a node's
string value. `NodeReader` takes one too, and that is the part that makes it usable: the
storage layer never constructs `XdmElement`/`XdmDocument` itself, so an init-only property
alone would have been a hook nobody outside this assembly could reach. The resolver is supplied
per reader, runs at most once per node, and caches its result — including the empty string,
which is a legitimate answer rather than a retry.
- **`XdmNode.StrictStringValue`** (opt-in, default off; also settable via the AppContext switch
`PhoenixmlDb.Xdm.StrictStringValue`) — raises instead of returning `""` when a node has neither
a computed string value nor a resolver.
### Why
`XdmElement.StringValue` was `_stringValue ?? string.Empty`, so a node whose value had never been
computed reported exactly what a genuinely empty node reports. Paths that WALK children
(`fn:string`, explicit casts) saw the text; paths that READ the cached value (implicit
atomization) saw `""`. The same predicate returned the right document on its own and `0` inside
`count()`, with no error raised:
sum(collection()//balance) Cannot cast '' to xs:double
count(collection()/c[region='west']) 0, where the predicate alone returns the document
This is the root cause beneath the `fn:sum`/`avg`/`max`/`min` fix shipped in PhoenixmlDb.XQuery —
that treated the symptom without knowing the cause.
`StrictStringValue` ships OFF so no consumer changes behaviour on upgrade. It was measured before
being adopted rather than assumed safe: with it on globally, the only failures across all 516 Xdm
tests were the four asserting the empty-string fallback, and no production path broke. This
repository's own test assemblies now run with it ON, because a strict mode nobody enables catches
nothing.
### Verified
- Xdm.Tests 516/516 and Core.Tests 502/502, on `net8.0` and `net10.0`, with strict mode enabled
- End-to-end against an LMDB store by the phoenixml database repo: **73 pass/13 fail → 85/1**
### Note on release discipline
From this release, `publish` is gated on the test job in CI. Until today every package in this
org could reach nuget.org with a red suite. See `phoenixmldb-xslt/docs/RELEASE-HYGIENE.md`.