AOUT.CH2.LogAn.LogAnalyzer.IsValidLogFileName C# (CSharp) Method

IsValidLogFileName() public method

public IsValidLogFileName ( string fileName ) : bool
fileName string
return bool
        public bool IsValidLogFileName(string fileName)
        {
            if (!File.Exists(fileName))
            {
                throw new Exception("No log file with that name exists");
            }
            if(!fileName.ToLower().EndsWith(".slf"))
            {
                return false;
            }

            return true;
        }