Creomobile.Data.EFCore 0.1.0

Suggested Alternatives

Creomobile.Data.EFCore.Timestamps

Additional Details

Split into two single-aspect packages: Creomobile.Data.EFCore.CamelCaseColumns (camelCase column naming) and Creomobile.Data.EFCore.Timestamps (CreatedAt/UpdatedAt maintenance and soft delete via DeletedAt). Reference whichever aspects you need; UseCreomobileDefaults() is replaced by UseCamelCaseColumnNames() and UseTimestamps().

dotnet add package Creomobile.Data.EFCore --version 0.1.0
                    
NuGet\Install-Package Creomobile.Data.EFCore -Version 0.1.0
                    
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="Creomobile.Data.EFCore" Version="0.1.0" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="Creomobile.Data.EFCore" Version="0.1.0" />
                    
Directory.Packages.props
<PackageReference Include="Creomobile.Data.EFCore" />
                    
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 Creomobile.Data.EFCore --version 0.1.0
                    
#r "nuget: Creomobile.Data.EFCore, 0.1.0"
                    
#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 Creomobile.Data.EFCore@0.1.0
                    
#: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=Creomobile.Data.EFCore&version=0.1.0
                    
Install as a Cake Addin
#tool nuget:?package=Creomobile.Data.EFCore&version=0.1.0
                    
Install as a Cake Tool

Creomobile.Data.EFCore

Opinionated EF Core extensions for uniform database configuration. All features are extension methods on DbContextOptionsBuilder: apply the whole baseline with UseCreomobileDefaults() or opt in selectively.

Usage

services.AddDbContext<AppDbContext>(options => options
    .UseNpgsql(connectionString)
    .UseCreomobileDefaults());

public sealed class Customer : EntityBase<Guid>, ITimestamps
{
    public string Name { get; set; } = null!;
}

UseCreomobileDefaults() applies the current recommended baseline — UseCamelCaseColumnNames() plus UseTimestamps() — and may gain new conventions in future versions; call the individual methods instead to opt in selectively. EntityBase<TId> and the timestamp interfaces come from Creomobile.Data.Abstractions, installed automatically as a dependency.

Features

UseCamelCaseColumnNames()

Renames table columns whose names were derived by convention to camelCase (CreatedAt → createdAt). Names configured explicitly — via [Column] or HasColumnName — are left untouched; table, key, index and constraint names are not affected.

UseTimestamps(TimeProvider? timeProvider = null)

Automatically maintains the timestamp interfaces from Creomobile.Data.Abstractions (ICreatedAt, IUpdatedAt, IDeletedAt — each works independently, ITimestamps aggregates all three):

  • Insert — CreatedAt and UpdatedAt receive the same UTC instant.
  • Update — UpdatedAt is refreshed; CreatedAt is protected from accidental overwrites.
  • Delete of an IDeletedAt entity becomes a soft delete: the row is kept with DeletedAt set, owned entities are retained; setting DeletedAt back to null restores the entity. Regular (non-owned) dependents still follow the normal delete cascade — implement IDeletedAt on them or adjust DeleteBehavior if they must survive the parent's soft delete.
  • A named query filter ("SoftDelete") hides soft-deleted entities from queries; bypass it per query with IgnoreQueryFilters() or selectively with IgnoreQueryFilters([SoftDeleteQueryFilterConvention.FilterKey]).
  • All entities saved together share one instant; pass a TimeProvider for deterministic tests.

See the XML documentation of each extension method for exact semantics and known limitations.

Requirements

  • .NET 10+
  • EF Core 10
Product Compatible and additional computed target framework versions.
.NET 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. 
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
0.1.0 166 7/19/2026 0.1.0 is deprecated because it is no longer maintained.