Example #1
0
 public bool ValidaProfessor()
 {
     if (string.IsNullOrEmpty(Nome) || string.IsNullOrEmpty(Sobrenome) ||
         Nome.Any(x => char.IsDigit(x)) || Sobrenome.Any(x => char.IsDigit(x))
         )
     {
         return(false);
     }
     else
     {
         return(true);
     }
 }
Example #2
0
 public bool ehValido()
 {
     if (string.IsNullOrWhiteSpace(Nome) || string.IsNullOrWhiteSpace(Sobrenome) || string.IsNullOrWhiteSpace(Email) ||
         string.IsNullOrWhiteSpace(Senha) || Nome.Any(x => char.IsDigit(x)) ||
         Sobrenome.Any(x => char.IsDigit(x)) || Senha.Length < 8)
     {
         return(false);
     }
     else
     {
         return(true);
     }
 }