public List <IPartnerAccount> ListPartnerAccountsByPartner(string partnerIdentifier) { if (string.IsNullOrWhiteSpace(partnerIdentifier)) { throw new ArgumentNullException("partnerIdentifier"); } DalPartnerAccount dal = new DalPartnerAccount(this.storageAccount, this.container, partnerIdentifier); return(dal.List().ConvertAll <IPartnerAccount>(partnerAccount => partnerAccount)); }
public List <IPartnerAccount> ListPartnerAccounts() { List <IPartnerAccount> result = new List <IPartnerAccount>(); DalPartner dalPartner = new DalPartner(this.storageAccount, this.container); foreach (IPartner partner in dalPartner.List()) { DalPartnerAccount dal = new DalPartnerAccount(this.storageAccount, this.container, partner.Identifier); result.AddRange(dal.List().ConvertAll <IPartnerAccount>(partnerAccount => partnerAccount)); } return(result); }