예제 #1
0
        /// <summary>
        /// Initializes a new instance of the <see cref="FileLogger"/> class
        /// </summary>
        /// <param name="filePath">Path where the file will be stored</param>
        /// <param name="fileName">Name of the file</param>
        /// <param name="writingMode">Used writing mode</param>
        public TextFileLogger(string filePath, string fileName, WritingMode writingMode = WritingMode.Appending)
        {
            this.FilePath    = filePath;
            this.FileName    = fileName;
            this.WritingMode = writingMode;

            // Build full file name
            this.FullFileName = MessageProperties.GetFullNamePath(this.FilePath, this.FileName) + ".txt";

            // Checks for file path and file name
            this.FileInitialization();
        }