Example #1
0
        public List <string> ReadAllLines(string fileName)
        {
            if (!_directoryFile.IsValidFileName(fileName))
            {
                throw new ArgumentException("Nome do arquivo inválido.");
            }

            if (!_directoryFile.FileExists(fileName))
            {
                throw new FileNotFoundException("Arquivo não existe.");
            }

            return(_directoryFile.ReadAllLines(fileName).ToList());
        }