/// <inheritdoc/> public ITenant MapTenant(object source) { Client.Models.Tenant tenantFromService = ((JObject)source).ToObject <Client.Models.Tenant>(); return(new Tenant( tenantFromService.Id, tenantFromService.Name, this.propertyBagFactory.Create(tenantFromService.Properties)) { ETag = tenantFromService.ETag, }); }
/// <inheritdoc/> public Client.Models.Tenant MapTenant(ITenant source) { var result = new Client.Models.Tenant { Id = source.Id, Name = source.Name, ContentType = source.ContentType, ETag = source.ETag, Properties = ((JObject)source.Properties).ToObject <Dictionary <string, object> >(), }; return(result); }