Skip to content
Snippets Groups Projects
Commit 4ea2d8bd authored by Niko Ehrenfeuchter's avatar Niko Ehrenfeuchter :keyboard:
Browse files

Fix public / private inconsistencies.

parent f632c0e7
No related branches found
No related tags found
No related merge requests found
...@@ -242,7 +242,7 @@ namespace AutoTx ...@@ -242,7 +242,7 @@ namespace AutoTx
/// <summary> /// <summary>
/// Check if loaded configuration is valid, print a summary to the log. /// Check if loaded configuration is valid, print a summary to the log.
/// </summary> /// </summary>
public void CheckConfiguration() { private void CheckConfiguration() {
// non-critical / optional configuration parameters: // non-critical / optional configuration parameters:
if (!string.IsNullOrWhiteSpace(_config.SmtpHost)) if (!string.IsNullOrWhiteSpace(_config.SmtpHost))
SetupMailLogging(); SetupMailLogging();
...@@ -481,7 +481,7 @@ namespace AutoTx ...@@ -481,7 +481,7 @@ namespace AutoTx
/// <summary> /// <summary>
/// Do the main tasks of the service, check system state, trigger transfers, ... /// Do the main tasks of the service, check system state, trigger transfers, ...
/// </summary> /// </summary>
public void RunMainTasks() { private void RunMainTasks() {
// mandatory tasks, run on every call: // mandatory tasks, run on every call:
SendLowSpaceMail(SystemChecks.CheckFreeDiskSpace(_config.SpaceMonitoring)); SendLowSpaceMail(SystemChecks.CheckFreeDiskSpace(_config.SpaceMonitoring));
UpdateServiceState(); UpdateServiceState();
...@@ -522,7 +522,7 @@ namespace AutoTx ...@@ -522,7 +522,7 @@ namespace AutoTx
/// <summary> /// <summary>
/// Check for transfers to be finished, resumed or newly initiated. /// Check for transfers to be finished, resumed or newly initiated.
/// </summary> /// </summary>
public void RunTransferTasks() { private void RunTransferTasks() {
// only proceed when in a valid state: // only proceed when in a valid state:
if (_transferState != TxState.Stopped && if (_transferState != TxState.Stopped &&
_transferState != TxState.Paused) _transferState != TxState.Paused)
...@@ -693,7 +693,7 @@ namespace AutoTx ...@@ -693,7 +693,7 @@ namespace AutoTx
/// a subdirectory with the current date and time as its name to denote the timepoint /// a subdirectory with the current date and time as its name to denote the timepoint
/// when the grace period for this data starts. /// when the grace period for this data starts.
/// </summary> /// </summary>
public void MoveToGraceLocation() { private void MoveToGraceLocation() {
string errMsg; string errMsg;
// CurrentTransferSrc is e.g. D:\ATX\PROCESSING\2017-04-02__12-34-56\user00 // CurrentTransferSrc is e.g. D:\ATX\PROCESSING\2017-04-02__12-34-56\user00
var sourceDirectory = new DirectoryInfo(_status.CurrentTransferSrc); var sourceDirectory = new DirectoryInfo(_status.CurrentTransferSrc);
......
...@@ -16,7 +16,7 @@ namespace AutoTx ...@@ -16,7 +16,7 @@ namespace AutoTx
/// <param name="recipient">A full email address OR a valid ActiveDirectory account.</param> /// <param name="recipient">A full email address OR a valid ActiveDirectory account.</param>
/// <param name="subject">The subject, might be prefixed with a configurable string.</param> /// <param name="subject">The subject, might be prefixed with a configurable string.</param>
/// <param name="body">The email body.</param> /// <param name="body">The email body.</param>
public void SendEmail(string recipient, string subject, string body) { private void SendEmail(string recipient, string subject, string body) {
subject = _config.EmailPrefix + subject; subject = _config.EmailPrefix + subject;
if (string.IsNullOrEmpty(_config.SmtpHost)) { if (string.IsNullOrEmpty(_config.SmtpHost)) {
Log.Debug("SendEmail: {0}\n{1}", subject, body); Log.Debug("SendEmail: {0}\n{1}", subject, body);
...@@ -76,7 +76,7 @@ namespace AutoTx ...@@ -76,7 +76,7 @@ namespace AutoTx
/// ///
/// TODO: Once logging has stabilized we can probably safely remove this method again! /// TODO: Once logging has stabilized we can probably safely remove this method again!
/// </summary> /// </summary>
public void AdminDebugLog(string subject, string format, params object[] list) { private void AdminDebugLog(string subject, string format, params object[] list) {
var msg = string.Format(format, list); var msg = string.Format(format, list);
SendAdminEmail(msg, subject); SendAdminEmail(msg, subject);
msg = subject + "\n" + msg; msg = subject + "\n" + msg;
...@@ -88,7 +88,7 @@ namespace AutoTx ...@@ -88,7 +88,7 @@ namespace AutoTx
/// </summary> /// </summary>
/// <param name="body">The email text.</param> /// <param name="body">The email text.</param>
/// <param name="subject">Optional subject for the email.</param> /// <param name="subject">Optional subject for the email.</param>
public void SendAdminEmail(string body, string subject = "") { private void SendAdminEmail(string body, string subject = "") {
if (_config.SendAdminNotification == false) if (_config.SendAdminNotification == false)
return; return;
...@@ -117,7 +117,7 @@ namespace AutoTx ...@@ -117,7 +117,7 @@ namespace AutoTx
/// Send a notification about low drive space to the admin. /// Send a notification about low drive space to the admin.
/// </summary> /// </summary>
/// <param name="spaceDetails">String describing the drives being low on space.</param> /// <param name="spaceDetails">String describing the drives being low on space.</param>
public void SendLowSpaceMail(string spaceDetails) { private void SendLowSpaceMail(string spaceDetails) {
if (string.IsNullOrWhiteSpace(spaceDetails)) if (string.IsNullOrWhiteSpace(spaceDetails))
return; return;
...@@ -153,7 +153,7 @@ namespace AutoTx ...@@ -153,7 +153,7 @@ namespace AutoTx
/// Send a notification email to the file owner upon successful transfer. /// Send a notification email to the file owner upon successful transfer.
/// The recipient address is derived from the global variable CurrentTransferSrc. /// The recipient address is derived from the global variable CurrentTransferSrc.
/// </summary> /// </summary>
public void SendTransferCompletedMail() { private void SendTransferCompletedMail() {
if (_config.SendTransferNotification == false) if (_config.SendTransferNotification == false)
return; return;
...@@ -192,7 +192,7 @@ namespace AutoTx ...@@ -192,7 +192,7 @@ namespace AutoTx
/// Send a notification email when a transfer has been interrupted before completion. /// Send a notification email when a transfer has been interrupted before completion.
/// Recipient address is derived from the global variable CurrentTransferSrc. /// Recipient address is derived from the global variable CurrentTransferSrc.
/// </summary> /// </summary>
public void SendTransferInterruptedMail() { private void SendTransferInterruptedMail() {
if (_config.SendTransferNotification == false) if (_config.SendTransferNotification == false)
return; return;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment