Skip to main content

Convenience wrapper for exonware-xwmodels - provides 'import xwmodels' alias

Project description

xwmodels

Entity collections and groups on top of xwentity, wired for the rest of the eXonware stack. Details live in per-project REF docs.

Company: eXonware.com · Author: eXonware Backend Team · Email: connect@exonware.com

Status Python License


📦 Install

pip install exonware-xwmodels
pip install exonware-xwmodels[lazy]
pip install exonware-xwmodels[full]

🚀 Quick start

from exonware.xwmodels import *
# Or: import xwmodels
# Collections and groups of entities - see docs for patterns

See docs/ for REF_* files and examples.


✨ What you get

Area Contents
Models Entity collections and groups built on xwentity.
Integration Hooks for xwentity, xwstorage, xwaction.
Tooling Utilities aimed at larger, consistent model graphs.

🧱 Core model roles

  • XWModelEntity (entity_compat.py) is the xwmodels compatibility facade over exonware.xwentity.XWEntity (data-first ergonomics + model-facing helpers).
  • XWModelCollection (collection.py) manages many entities of one type and adds persistence-aware collection behavior via storage contracts.
  • XWModelGroup (group.py) manages multiple collections, supports nested subgroups (tree hierarchy), and coordinates group-level save/load through providers.
  • Shared foundation: model collection and model group inherit XWObject from xwsystem for lightweight identity/object semantics; entity behavior is inherited from core xwentity.
  • Compatibility alias: XWEntity remains exported as an alias to XWModelEntity for backward compatibility.

📊 Model management layer in practice

  • Base systems: use one XWModelGroup per bounded system (for example auth, catalog, billing, content) and keep each system's collections under that group.
  • Domain partitioning: map each aggregate/root model to one XWModelCollection (users, roles, invoices, products), with one schema contract and many entities.
  • Nested environments: create subgroups for dev / staging / prod, tenant spaces, or regional shards while preserving one management API.
  • Provider orchestration: plug storage/auth providers at group level so save/load and access control policies are consistent across all collections in that system.
  • App composition: xwbase-style systems can compose multiple groups to build complete application backbones while reusing the same entity/collection/group semantics.

🌐 Ecosystem functional contributions

xwmodels is the management layer over entity collections/groups; sibling libraries provide the contracts that make model systems production-capable. You can adopt xwmodels standalone as a model-organization layer on top of your existing domain code. Connecting to more XW modules is optional and primarily useful for enterprise and mission-critical model infrastructure that needs consistent self-hosted contracts.

Supporting XW lib What it provides to xwmodels Functional requirement it satisfies
XWEntity Core entity/collection/group semantics and compatibility facade targets. Stable domain model foundation for model graphs.
XWStorage Provider contracts and persistence paths for model save/load operations. Durable model state and environment/tenant partition persistence.
XWAction Action integration for model-level workflows and operations. Workflow and automation on top of model collections/groups.
XWSystem Base object/runtime contracts reused by model types. Consistent object lifecycle and shared infrastructure behavior.
XWSchema Validation rules for model payloads and evolution. Controlled schema integrity for large model graphs.
XWBase Higher-level composition layer that consumes model systems. End-to-end application assembly from reusable model primitives.

This positions xwmodels as orchestration for large domain graphs, not just a thin alias package.


📖 Docs and tests

  • Start: docs/INDEX.md or docs/.
  • Tests: From repo root, e.g. python tests/runner.py, per project layout.

📜 License and links

Apache-2.0 - see LICENSE. Homepage: https://exonware.com · Repository: https://github.com/exonware/xwmodels

⏱️ Async Support

  • xwmodels includes asynchronous execution paths in production code.
  • Source validation: 9 async def definitions and 2 await usages under src/.
  • Use async APIs for I/O-heavy or concurrent workloads to improve throughput and responsiveness.

Version: 0.6.0.8 | Updated: 08-Apr-2026

Built with ❤️ by eXonware.com - Revolutionizing Python Development Since 2025

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

xwmodels-0.6.0.8.tar.gz (81.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

xwmodels-0.6.0.8-py3-none-any.whl (10.0 kB view details)

Uploaded Python 3

File details

Details for the file xwmodels-0.6.0.8.tar.gz.

File metadata

  • Download URL: xwmodels-0.6.0.8.tar.gz
  • Upload date:
  • Size: 81.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.13

File hashes

Hashes for xwmodels-0.6.0.8.tar.gz
Algorithm Hash digest
SHA256 15fcf3ad11296da1ef5ce2d0da7877093a17fae409a12e0a0dcb40bf47d0d499
MD5 9e94377a89eb02e9aa1ba0a7625a4b0c
BLAKE2b-256 94b68d9e39517801e6332c1e57618227b7d181157da286ee94bc0bae84f397d4

See more details on using hashes here.

File details

Details for the file xwmodels-0.6.0.8-py3-none-any.whl.

File metadata

  • Download URL: xwmodels-0.6.0.8-py3-none-any.whl
  • Upload date:
  • Size: 10.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.13

File hashes

Hashes for xwmodels-0.6.0.8-py3-none-any.whl
Algorithm Hash digest
SHA256 413a675be1db8ff35923af4fc28e3181549a1eaedebd3c9ac35ec0dabef1b42c
MD5 a51cc95dac199afafce7c2dddfd10b4e
BLAKE2b-256 edfdab6843225e0b9d5b4764ea44ecc76c9c9739a8e6839728b5a26c6e3535ee

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page