Métodos Frequentes
Métodos Frequentes
Métodos Frequentes
Métodos Frequentes
public Phone GetPhoneByPhoneId(string phoneId) { Guid phoneIdGuid = Guid.Empty; if (!Guid.TryParse(phoneId, out phoneIdGuid)) { throw new Exception("Invalid Guid Format"); } var phone = _PhoneRepository.GetPhoneByPhoneId(phoneIdGuid); if (phone == null) { throw new EntityNotFoundException(phoneIdGuid); } return(phone); }