'How to do a custom mapping with nested objects and Dapper

say I have the following denormalized table

User (
    fist_name text,
    last_name text,
    adresse_street text,
    address_zip text,
    address_city text
)

and the following classes

class Adress {
   public string Street {get; set}
   public string ZIP {get; set}
   public string City {get; set}
}

class User {
   public string FirstName {get; set}
   public string LastName {get; set}
}

How do I map these (specifically the nested object) using a Custom Mapper approach (No Property attributes)



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source