SimpleAutoMapper 1.1.0
See the version list below for details.
dotnet add package SimpleAutoMapper --version 1.1.0
NuGet\Install-Package SimpleAutoMapper -Version 1.1.0
<PackageReference Include="SimpleAutoMapper" Version="1.1.0" />
paket add SimpleAutoMapper --version 1.1.0
#r "nuget: SimpleAutoMapper, 1.1.0"
// Install SimpleAutoMapper as a Cake Addin #addin nuget:?package=SimpleAutoMapper&version=1.1.0 // Install SimpleAutoMapper as a Cake Tool #tool nuget:?package=SimpleAutoMapper&version=1.1.0
SimpleAutoMapper
SimpleAutoMapper is a lightweight and easy-to-use library for automatic object mapping in C#. It allows you to map an object to another one efficiently and intuitively.
How to install
SimpleAutoMapper is available as a NuGet package. You can install it using the NuGet package manager in Visual Studio or through the command line.
Install-Package SimpleAutoMapper -Version 1.0.0
You can also download the package directly from the NuGet website at https://www.nuget.org/packages/SimpleAutoMapper/1.0.0.
How to use To use SimpleAutoMapper, first add the following line at the top of your file:
using SimpleAutoMapper;
var response = AutoMapper.Map<ResponseModel>(request);
In this example, request is the object that you want to map and ResponseModel is the type of the target object. The Map<T> method creates a new instance of ResponseModel, maps the properties of the request object to the ResponseModel object and returns the ResponseModel object.
Features
- Automatic mapping of properties with the same name and type.
- Support for primitive types, strings, Guids, DateTimes and nullable types.
- Recursive mapping for complex objects.
- Support for lists and collections.
Limitations
- The properties must have public setters to be mapped.
- The mapping is not done in depth for lists or collections of complex objects. Each object in the list or collection is mapped individually.
We hope you find SimpleAutoMapper useful for your C# projects! If you have any questions or suggestions, feel free to open an issue.
Product | Versions 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. |
-
net8.0
- No dependencies.
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.
Adding mapping return support with list