Exemple #1
0
 public Estado[] Get()
 {
     try
     {
         return(_estadoServico.GetAll().ToArray());
     }
     catch (Exception e)
     {
         return(null);
     }
 }
 public Estado[] Get()
 {
     try
     {
         var ret = _estadoServico.GetAll();
         return(ret.Select(i => new Estado {
             Id = i.Id, Nome = i.Nome, Sigla = i.Sigla
         }).ToList().ToArray());
     }
     catch (Exception e)
     {
         throw;
     }
 }