0

我想根据简单的命名约定从扁平对象映射到分层对象。例如:

public class FlatObject {
    public string Name__FirstName { get; set; }
    public string Name__MiddleName { get; set; }
    public string Name__LastName { get; set; }
}

public class HierarchicalObject {
    public SubObject Name { get; set; }
}

public class SubObject {
    public string FirstName { get; set; }
    public string MiddleName { get; set; }
    public string LastName { get; set; }
}

简单的命名约定是 FlattenedObject 中的双下划线。

我将如何使用 EmitMapper 完成此任务?

4

1 回答 1

1

EmitMapper cannot do this task without significant code changes.

于 2014-02-27T14:07:44.167 回答