mirror of
https://github.com/9ParsonsB/Pulsar.git
synced 2025-07-01 08:23:42 -04:00
JournalService setup work in progress
This commit is contained in:
@ -278,7 +278,7 @@ using Travel;
|
||||
[JsonDerivedType(typeof(ShipyardFile))]
|
||||
[JsonDerivedType(typeof(Status))]
|
||||
[JsonDerivedType(typeof(JournalBase))]
|
||||
public interface IJournal
|
||||
public class JournalBase
|
||||
{
|
||||
[JsonPropertyName("timestamp")]
|
||||
public DateTimeOffset Timestamp { get; init; }
|
||||
@ -289,10 +289,3 @@ public interface IJournal
|
||||
[JsonExtensionData]
|
||||
public Dictionary<string, object> AdditionalProperties { get; init; }
|
||||
}
|
||||
|
||||
public abstract class JournalBase : IJournal
|
||||
{
|
||||
public DateTimeOffset Timestamp { get; init; }
|
||||
public string Event { get; init; }
|
||||
public Dictionary<string, object> AdditionalProperties { get; init; }
|
||||
}
|
@ -54,7 +54,7 @@ public interface IObservatoryWorker : IObservatoryPlugin
|
||||
/// <param name="journal"><para>Elite Dangerous journal event, deserialized into a .NET object.</para>
|
||||
/// <para>Unhandled json values within a journal entry type will be contained in member property:<br/>Dictionary<string, object> AdditionalProperties.</para>
|
||||
/// <para>Unhandled journal event types will be type JournalBase with all values contained in AdditionalProperties.</para></param>
|
||||
public void JournalEvent<TJournal>(TJournal journal) where TJournal : IJournal;
|
||||
public void JournalEvent<TJournal>(TJournal journal) where TJournal : JournalBase;
|
||||
|
||||
/// <summary>
|
||||
/// Method called when status.json content is updated.<br/>
|
||||
|
Reference in New Issue
Block a user