Projektdateien hinzufügen.

This commit is contained in:
mr_sc
2026-08-19 19:27:41 +02:00
parent 0889f1f6c7
commit 7fe54c0785
32 changed files with 2406 additions and 0 deletions

View File

@@ -0,0 +1,69 @@
using System;
using System.Collections.Generic;
namespace FileInterface.Scheduler
{
public sealed class CronJobConfig
{
public string Id { get; set; }
public string Name { get; set; }
public bool Enabled { get; set; }
public string Cron { get; set; }
// File processing. If CallOnceWithoutFile=true, SourceDirectory/SearchPattern are ignored.
public bool CallOnceWithoutFile { get; set; }
public string SourceDirectory { get; set; }
public string SearchPattern { get; set; }
public bool IncludeSubdirectories { get; set; }
// Existing FileInterface-style preprocessing.
public bool RemoveEmptyLines { get; set; }
public string JoinSeparator { get; set; }
// iTAC CustomFunction.
public string CustomFunction { get; set; }
public List<string> InArgs { get; set; }
// File handling after successful CF call.
public bool MoveFileAfterSuccess { get; set; }
public string MoveTargetDirectory { get; set; }
public bool OverwriteTargetFile { get; set; }
public CronJobConfig()
{
Id = Guid.NewGuid().ToString("N");
Name = "New job";
Enabled = true;
Cron = "*/5 * * * *";
CallOnceWithoutFile = false;
SourceDirectory = "";
SearchPattern = "*.*";
IncludeSubdirectories = false;
RemoveEmptyLines = true;
JoinSeparator = ";";
CustomFunction = "";
InArgs = new List<string>();
MoveFileAfterSuccess = false;
MoveTargetDirectory = "";
OverwriteTargetFile = false;
}
}
public sealed class SchedulerOptions
{
public string ConfigFile { get; set; }
public string WatcherConfigFile { get; set; }
public string WebPrefix { get; set; }
public string WebUser { get; set; }
public string WebPassword { get; set; }
public SchedulerOptions()
{
ConfigFile = "cronjobs.json";
WatcherConfigFile = "watcherjobs.json";
WebPrefix = "http://127.0.0.1:8095/";
WebUser = "";
WebPassword = "";
}
}
}