public IList <ICompetency> GetAllCompetency(out IList <CodeMessage> messages) { using (new OperationContextScope((IContextChannel)_smsEndPointClient.InnerChannel)) { if (ServiceHeaders != null) { OperationContext.Current.OutgoingMessageProperties[HttpRequestMessageProperty.Name] = Utility.SetMessageProperty(ServiceHeaders); } SmsService.GetAllCompetenciesResponse response = _smsEndPointClient.getAllCompetencies(new SmsService.getAllCompetenciesRequest()); IList <ICompetency> listReturn = new List <ICompetency>(); if (Utility.ResolveCodeMessage(DataIntegrationMapper.ToGenericResponse(response), out messages)) { foreach (SmsService.competencyDto competency in response.comptencies) { ICompetency competencyEntity = Helper.Translator.BaseToEntity <Competency>(DataIntegrationMapper.ToServiceLookup <SmsService.competencyDto>(competency)); competencyEntity.CompetencyId = competency.comeptencyId.ToString(); competencyEntity.Description = competency.comeptencyDescription; competencyEntity.Name = competency.comeptencyName; competencyEntity.ManagerId = competency.competencyManagerId.ToString(); competencyEntity.ManagerIdSpecified = competency.competencyManagerIdSpecified; competencyEntity.RecordStatusId = competency.recordStatusId.ToString(); competencyEntity.RecordStatusIdSpecified = competency.recordStatusIdSpecified; competencyEntity.Description = competency.comeptencyDescription; listReturn.Add(competencyEntity); } } return(listReturn); } }
public Boolean HasSkill(ICompetency competency) { foreach (Skill skill in skills) { if (skill.Equals(competency)) { return(true); } } return(false); }
public bool Equals(ICompetency comp) { return(this.NameProperty == comp.NameProperty); }