2014-10-27 44 views
0

从文档中的示例...ModelMapper会创建中间对象吗?

map()。customer.setName(source.getPerson()。firstName);

如果“customer”不存在(为null),ModelMapper会自动创建一个新的Customer对象和setCustomer,还是必须事先创建它?

回答

1

ModelMapper将为您创建中间对象,包括该示例中的customer