diff options
author | Jesse Plamondon-Willard <github@jplamondonw.com> | 2017-06-02 18:25:34 -0400 |
---|---|---|
committer | Jesse Plamondon-Willard <github@jplamondonw.com> | 2017-06-02 18:25:34 -0400 |
commit | 559203922bcad4071f8be53b1a61b0026da14396 (patch) | |
tree | 2ed664798183d77779beb68b61bd7622140413df /src/StardewModdingAPI/Framework/Logging/LogFileManager.cs | |
parent | 933e889c24e565d9028d3719ba2d65d512890564 (diff) | |
parent | 3a8e77a3098572fa413a27f41f832563daec3453 (diff) | |
download | SMAPI-559203922bcad4071f8be53b1a61b0026da14396.tar.gz SMAPI-559203922bcad4071f8be53b1a61b0026da14396.tar.bz2 SMAPI-559203922bcad4071f8be53b1a61b0026da14396.zip |
Merge branch 'develop' into stable
Diffstat (limited to 'src/StardewModdingAPI/Framework/Logging/LogFileManager.cs')
-rw-r--r-- | src/StardewModdingAPI/Framework/Logging/LogFileManager.cs | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/src/StardewModdingAPI/Framework/Logging/LogFileManager.cs b/src/StardewModdingAPI/Framework/Logging/LogFileManager.cs index 1f6ade1d..8cfe0527 100644 --- a/src/StardewModdingAPI/Framework/Logging/LogFileManager.cs +++ b/src/StardewModdingAPI/Framework/Logging/LogFileManager.cs @@ -14,14 +14,23 @@ namespace StardewModdingAPI.Framework.Logging /********* + ** Accessors + *********/ + /// <summary>The full path to the log file being written.</summary> + public string Path { get; } + + + /********* ** Public methods *********/ /// <summary>Construct an instance.</summary> /// <param name="path">The log file to write.</param> public LogFileManager(string path) { + this.Path = path; + // create log directory if needed - string logDir = Path.GetDirectoryName(path); + string logDir = System.IO.Path.GetDirectoryName(path); if (logDir == null) throw new ArgumentException($"The log path '{path}' is not valid."); Directory.CreateDirectory(logDir); |