Skip to content

Commit 23567e1

Browse files
committed
Merge branch 'master' of github.com:CodeShayk/ActiveForge
2 parents 888c5ff + e831688 commit 23567e1

1 file changed

Lines changed: 41 additions & 17 deletions

File tree

README.md

Lines changed: 41 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -20,29 +20,53 @@ All connection types live in the `ActiveForge` namespace, so a single `using Act
2020

2121
## Features
2222

23+
ActiveForge streamlines data-centric development with a cohesive approach to entities, queries, and data management.
24+
2325
### 🗂 Entities & Mapping
24-
- **Active Record pattern** — entities carry both data and persistence behaviour; no separate repository class required
25-
- **Type-safe field wrappers**`TString`, `TInt`, `TDecimal`, `TPrimaryKey`, `TForeignKey`, and 25+ more; each tracks null/loaded state and supports implicit conversion
26-
- **Polymorphic mapping** — map abstract base types to concrete subtypes via `FactoryBase`
27-
- **Custom field mappers** — implement `IDBFieldMapper` for non-standard type conversions
28-
- **Field encryption** — transparent encrypt/decrypt via `[Encrypted]` attribute
26+
27+
- **Active Record pattern**
28+
Entities contain both state and persistence logic, removing the need for external repositories.
29+
- **Type-safe fields**
30+
Provides wrappers for types (string, int, decimal, keys, etc.), tracking nullability and state, and handling conversion automatically.
31+
- **Polymorphic mapping**
32+
Maps base types to concrete subtypes at runtime.
33+
- **Custom field mappers**
34+
Easily support non-standard type conversions.
35+
- **Field encryption**
36+
Simple attribute-based encryption/decryption for sensitive data.
2937

3038
### 🔍 Querying
31-
- **Composable query predicates**`EqualTerm`, `ContainsTerm`, `InTerm`, `GreaterThanTerm`, `LessThanTerm`, `LessOrEqualTerm`, `GreaterOrEqualTerm`, `IsNullTerm`, `LikeTerm`, composed with `&`, `|`, `!`
32-
- **LINQ query support**`conn.Query<T>().Where(...).OrderBy(...).Take(...).Skip(...)` translated to native ORM predicates
33-
- **Pagination**`QueryPage` with `StartRecord`, `PageSize`, `IsMoreData`, `TotalRowCount`
34-
- **Lazy streaming**`LazyQueryAll<T>` streams rows without buffering the full result set
35-
- **Field subsets** — partial SELECTs and partial UPDATEs via `FieldSubset`
3639

37-
### 💾 Data Management
38-
- **Transactions** — manual nested transactions via `BeginTransaction` / `CommitTransaction` / `RollbackTransaction`
39-
- **Unit of Work**`IUnitOfWork`, `UnitOfWorkBase`, provider-specific implementations, `With.Transaction`, `[Transaction]` attribute, Castle DynamicProxy interceptor. `[Transaction]` — wraps a service method in a `IUnitOfWork` transaction via Castle DynamicProxy; combine with `[ConnectionScope]` for the full open → begin → commit → close lifecycle
40-
- **Connection-level lifecycle** — set `conn.UnitOfWork = uow` once; every write operation (`Insert`, `Update`, `Delete`, `ProcessActionQueue`, `ExecStoredProcedure`) automatically opens the connection, begins a transaction, commits, and closes — no proxy required; coordinates transparently with `[ConnectionScope]` via `IsOpen`. `[ConnectionScope]` — marks service methods/classes where the `DataConnection` is opened before and closed after; nested calls share one connection via `IsOpen` state.
41-
- **Action queue** — batch operations via `QueueForInsert` / `QueueForUpdate` / `QueueForDelete``ProcessActionQueue`
40+
- **Composable predicates**
41+
Build queries with terms for equality, containment, ranges, null checks, and pattern matching; combine them with logical operators.
42+
- **LINQ support**
43+
Write queries using familiar C# syntax, auto-translated to efficient ORM operations.
44+
- **Pagination**
45+
Built-in paging with metadata for efficient handling of large datasets.
46+
- **Lazy streaming**
47+
Stream results row-by-row for memory efficiency.
48+
- **Field subsets**
49+
Load or update only the fields you need.
4250

43-
### 🌐 DI & Service Proxy Integration
44-
- **Auto-scan registration**`AddActiveForgeSqlServer(...).AddServices(assembly)` discovers all `IService` implementations and registers them as interface-proxied scoped services in one call. `IService` marker — implement on any service class for automatic discovery and proxy registration. `IActiveForgeBuilder` — fluent builder returned by all `AddTurquoise*` methods; chain `.AddServices()`, `.AddService<I, T>()` for granular control.
51+
### 💾 Data Management
4552

53+
- **Transactions**
54+
Explicit and nested transaction support; control scope via code or attributes.
55+
- **Unit of Work**
56+
Integrated pattern for grouping multiple changes; supports both code-based and attribute-based usage.
57+
- **Connection lifecycle**
58+
Connections and transactions are managed automatically on every write, ensuring reliability.
59+
- **Batch operations**
60+
Queue up changes and execute them in bulk to reduce database round-trips.
61+
62+
### 🌐 Dependency Injection & Service Proxy
63+
64+
- **Auto-discovery & registration**
65+
Services marked with a simple interface are discovered and registered automatically.
66+
- **Fluent builder API**
67+
Register all or selected services with fine-grained control.
68+
- **Seamless DI integration**
69+
Simplifies service composition, testing, and enables proxy/interceptor scenarios.
4670
---
4771

4872
## Requirements

0 commit comments

Comments
 (0)