Man kann jetzt einen Offset eingeben
This commit is contained in:
@@ -12,12 +12,17 @@ namespace KlassenBIB
|
||||
DateTime datum = new DateTime();
|
||||
bool fertig = false;
|
||||
string verzeichnispfad;
|
||||
/// <summary>
|
||||
/// Dient zum Überschreiben
|
||||
/// </summary>
|
||||
DateTime offset;
|
||||
|
||||
#region getSeters
|
||||
public string Besatzung { get; set; }
|
||||
public DateTime Datum { get => datum; set => datum = value; }
|
||||
public bool Fertig { get => fertig; set => fertig = value; }
|
||||
public string Verzeichnispfad { get => verzeichnispfad; protected set => verzeichnispfad = value; }
|
||||
public DateTime Offset { get => offset; set => offset = value; }
|
||||
#endregion
|
||||
}
|
||||
}
|
||||
|
||||
@@ -56,8 +56,8 @@ namespace KlassenBIB
|
||||
|
||||
return path;
|
||||
}
|
||||
|
||||
public Hashtable MakeProtokoll(string destinationPath, IProjekt projekt)
|
||||
|
||||
public Hashtable MakeProtokoll(string destinationPath, IProjekt projekt, DateTime offset)
|
||||
{
|
||||
IEnumerable<string> files = Directory.EnumerateFiles(destinationPath, "*.csv", SearchOption.AllDirectories);
|
||||
|
||||
@@ -82,6 +82,12 @@ namespace KlassenBIB
|
||||
|
||||
this.AnfangAushaertung = struktures.Select(x => x.Zeitstempel).Min();
|
||||
this.EndeAushaertung = struktures.Select(x => x.Zeitstempel).Max();
|
||||
if (!(offset == DateTime.MinValue))
|
||||
{
|
||||
TimeSpan duration = EndeAushaertung.Subtract(AnfangAushaertung);
|
||||
AnfangAushaertung = offset;
|
||||
EndeAushaertung = AnfangAushaertung.Add(duration);
|
||||
}
|
||||
this.Rueckholgeschwindigkeit = 0;
|
||||
}
|
||||
catch (FileNotFoundException ex)
|
||||
|
||||
Reference in New Issue
Block a user