public static void ToEntity(DT.Resource source, DB.Resource target) { if ((source != null) && (target != null)) { target.ResourceId = source.Id; target.Name = source.Name; target.ParentResourceId = source.ParentResourceId; target.HbInterval = source.HbInterval; target.OwnerUserId = source.OwnerUserId; } }
public static DB.Resource ToEntity(DT.Resource source) { if (source == null) { return(null); } var entity = new DB.Resource(); ToEntity(source, entity); return(entity); }