Metadata-Version: 2.4
Name: ndca
Version: 5.0.2
Summary: NDCA (Nested Data Collection API) — a fast, safe, and human-readable nested data storage and manipulation library for Python.
Author: Viren Sahti
License: MIT License
        
        Copyright (c) 2026 Viren Sahti
        
        Permission is hereby granted, free of charge, to any person obtaining a copy
        of this software and associated documentation files (the "Software"), to deal
        in the Software without restriction, including without limitation the rights
        to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
        copies of the Software, and to permit persons to whom the Software is
        furnished to do so, subject to the following conditions:
        
        The above copyright notice and this permission notice shall be included in all
        copies or substantial portions of the Software.
        
        THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
        IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
        FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
        AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
        LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
        OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
        SOFTWARE.
Keywords: ndca,nested,data,storage,serialization,configuration,table,csv,python,library
Classifier: Development Status :: 5 - Production/Stable
Classifier: Intended Audience :: Developers
Classifier: License :: OSI Approved :: MIT License
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.9
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Operating System :: OS Independent
Classifier: Topic :: Software Development :: Libraries
Classifier: Topic :: Database :: Database Engines/Servers
Requires-Python: >=3.9
Description-Content-Type: text/markdown
License-File: LICENSE
Provides-Extra: dev
Requires-Dist: pytest>=7.0; extra == "dev"
Requires-Dist: mypy>=1.0; extra == "dev"
Requires-Dist: black>=23.0; extra == "dev"
Requires-Dist: ruff>=0.12; extra == "dev"
Requires-Dist: isort>=6.0; extra == "dev"
Requires-Dist: pre-commit>=3.0; extra == "dev"
Provides-Extra: test
Requires-Dist: pytest-cov>=4.0; extra == "test"
Dynamic: license-file

# NDCA

NDCA is a lightweight document format and Python library for structured local data storage, retrieval, transformation, and persistence.

It combines a human-readable text format with a path-based API, atomic file writing, transactions, history tracking, tables, query support, diff and patch utilities, validation helpers, and comment metadata support.

## Version

NDCA 5.0.2

## Highlights

- Human-readable nested document format
- Path-based read and write access
- Atomic saves
- Transaction support
- Snapshot history and rollback
- Watchers for change notifications
- Table operations and CSV import/export
- Query and filtering support
- Diff and patch support
- Schema validation
- Comment metadata support
- File-backed persistence

## Quick Example

```python
from ndca import NDCA

db = NDCA("data.ndca", autosave=True)
db.write("user.name", "Alice")
db.write("user.age", 30)

print(db.get("user.name"))
print(db.dumps(pretty=True))
```

## Installation

```bash
pip install ndca
```

## Typical Use Cases

- Local application state
- Configuration storage
- Lightweight document databases
- Table-oriented local data
- Structured file persistence

## Public Entry Points

- `NDCA`
- `Transaction`
- `file`
- `load`
- `save`
- `get`
- `write`
- `merge`
- `query`
- `where`
- `validate`
- `diff`
- `patch`
- `backup`
- `transaction`

## Basic Workflow

1. Create or open a document.
2. Read and write values by path.
3. Save atomically.
4. Use transactions for grouped changes.
5. Use tables, queries, and validation when needed.
