InlineMapping
InlineMapping copied to clipboard
Using the Compiler API for object mapping
Someone mentioned to me to add something like this to this list: ```csharp using Newtonsoft.Json; public static class MappingThroughSerialization { public static T Clone(this object srcObject) where T : class...
One idea is to allow the developer to provide hooks to the mapping process: ``` [MapTo(typeof(Destination), createDestination: true, postCustomization: true)] ``` If `createDestination` is `true`, a `Func` parameter is created...
If there's a type that has been set to be mappable, and two properties exist between the source and destination that use that type, I should use the `MapTo...()` method...
I'd like to be able to map into an existing object. Use-case: I get the entity from the database, I have the model posted into the action. I don't want...
If you put `#nullable enable` at the top of each file then you won't need to do this: ``` public Destination MapToDestination(this Source source) { source == null ? throw...