Transitio.Mapper 1.0.5

There is a newer version of this package available.
See the version list below for details.
dotnet add package Transitio.Mapper --version 1.0.5
                    
NuGet\Install-Package Transitio.Mapper -Version 1.0.5
                    
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="Transitio.Mapper" Version="1.0.5" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="Transitio.Mapper" Version="1.0.5" />
                    
Directory.Packages.props
<PackageReference Include="Transitio.Mapper" />
                    
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 Transitio.Mapper --version 1.0.5
                    
#r "nuget: Transitio.Mapper, 1.0.5"
                    
#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 Transitio.Mapper@1.0.5
                    
#: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=Transitio.Mapper&version=1.0.5
                    
Install as a Cake Addin
#tool nuget:?package=Transitio.Mapper&version=1.0.5
                    
Install as a Cake Tool

Transitio

NuGet NuGet

Transitio is a lightweight, high-performance object mapping framework for .NET with support for profiles, nested mapping, and dependency injection.


✨ Features

  • ⚑ Expression-based high-performance mapping
  • 🧩 Profiles for modular configuration
  • πŸ”— Nested object mapping (including nested collection properties)
  • πŸ“¦ Collection mapping (List β†’ List, IEnumerable β†’ array, IEnumerable β†’ interface)
  • 🧡 Thread-safe: a single mapper instance can be shared as a singleton

🎯 Custom Mapping Capabilities

  • πŸ”§ Custom member mapping with ForMember(...).MapFrom(...)
  • 🚫 Property ignore support with ForMember(...).Ignore()
  • 🎯 Conditional property mapping with ForMember(...).Condition(...)
  • πŸ”„ Reverse mapping with ReverseMap()

πŸ” Full Object Transformation

  • πŸ”„ Replace entire mapping logic using ConvertUsing(...)
    • βœ… Type-based converter (ConvertUsing<TConverter>())
    • βœ… Instance-based converter (ConvertUsing(instance))
    • βœ… Delegate-based converter (ConvertUsing((src, ctx) => {...}))
  • 🧠 Context-aware mapping with IMappingContext for runtime customization

🧬 Inheritance & Reusability

  • 🧬 Reuse base mappings using Include<TBaseSource, TBaseDestination>()
  • 🧬 Explicit base mapping support with IncludeBase<TBaseSource, TBaseDestination>()
  • πŸ” Override base mappings in derived types using ForMember

πŸ§ͺ Behavior Control

  • πŸ§ͺ Optional SetIgnoreNullValues(true) to preserve destination defaults when source properties are null
  • βœ… Mapping validation for early error detection

βš™οΈ Integration & Platform

  • πŸ’‰ Built-in dependency injection support (Microsoft.Extensions.DependencyInjection)
  • Type-based converters (ConvertUsing<TConverter>()) are resolved from the container, so sonverts may declare constructor dependencies
  • 🎯 Supports .NET 8 & .NET 10

ℹ️ Mapping rules & limitations

  • Only public properties are mapped. Public fields are not mapped automatically - expose data as properties, or populate fields with a custom ConvertUsing(...) converter.
  • Members are matched by name; "simple" members (primitives. string, enum, DateTime, decimal. Guid) are copied directly, and complex/collection members are mapped recursively when a corresponding CreateMap exists.
  • For derived element types in collections, register a CreateMap for the concrete element type (maps are matched by exact type).

πŸ†• What’s New

  • πŸ”„ Introduced ConvertUsing(...) for full object transformation

    • Supports type-based, instance-based, and delegate-based converters
    • Enables context-aware mapping via IMappingContext
  • 🧬 Added inheritance-based mapping support

    • Include<TBaseSource, TBaseDestination>()
    • IncludeBase<TBaseSource, TBaseDestination>()
    • Allows reuse and override of base mappings
  • πŸ§ͺ Added SetIgnoreNullValues(true) to preserve destination defaults when source values are null

  • πŸ“¦ Expanded collection mapping to support arrays and interface-based destinations


πŸ“¦ Installation

dotnet add package Transitio.Mapper
dotnet add package Transitio.Dependency

πŸ‘¨β€πŸ’» Maintainers

Maintained by the Transitio

πŸ“„ License

This project is licensed under the MIT License

Product 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. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.
  • net10.0

    • No dependencies.
  • net8.0

    • No dependencies.

NuGet packages (1)

Showing the top 1 NuGet packages that depend on Transitio.Mapper:

Package Downloads
Transitio.Dependency

Dependency wrapper for Transitio

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
1.4.0 79 10/20/2026
1.3.0 131 9/12/2026
1.2.0 156 7/18/2026
1.1.0 146 7/14/2026
1.0.8 138 7/13/2026
1.0.7 154 7/13/2026
1.0.6 217 6/16/2026
1.0.5 139 6/11/2026
1.0.4 168 6/10/2026 1.0.4 is deprecated because it is no longer maintained.
1.0.3 172 6/1/2026 1.0.3 is deprecated because it is no longer maintained.
1.0.2 173 5/21/2026 1.0.2 is deprecated because it is no longer maintained.
1.0.0 171 5/21/2026 1.0.0 is deprecated because it is no longer maintained.