2024-07-26 08:11:29 +00:00
|
|
|
|
namespace CodexPlugin.OverwatchSupport
|
2024-07-25 13:12:25 +00:00
|
|
|
|
{
|
|
|
|
|
[Serializable]
|
|
|
|
|
public class OverwatchCodexHeader
|
|
|
|
|
{
|
|
|
|
|
public int TotalNumberOfNodes { get; set; }
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
[Serializable]
|
|
|
|
|
public class OverwatchCodexEvent
|
|
|
|
|
{
|
2024-07-26 06:39:27 +00:00
|
|
|
|
public string PeerId { get; set; } = string.Empty;
|
2024-07-25 14:00:51 +00:00
|
|
|
|
public ScenarioFinishedEvent? ScenarioFinished { get; set; }
|
2024-07-29 08:16:37 +00:00
|
|
|
|
public NodeStartingEvent? NodeStarting { get; set; }
|
2024-07-25 13:12:25 +00:00
|
|
|
|
public NodeStartedEvent? NodeStarted { get; set; }
|
|
|
|
|
public NodeStoppedEvent? NodeStopped { get; set; }
|
2024-07-29 08:16:37 +00:00
|
|
|
|
public BootstrapConfigEvent? BootstrapConfig { get; set; }
|
2024-07-25 13:12:25 +00:00
|
|
|
|
public FileUploadedEvent? FileUploaded { get; set; }
|
|
|
|
|
public FileDownloadedEvent? FileDownloaded { get; set; }
|
|
|
|
|
public BlockReceivedEvent? BlockReceived { get; set; }
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
#region Scenario Generated Events
|
|
|
|
|
|
2024-07-25 14:00:51 +00:00
|
|
|
|
[Serializable]
|
|
|
|
|
public class ScenarioFinishedEvent
|
|
|
|
|
{
|
|
|
|
|
public bool Success { get; set; }
|
|
|
|
|
public string Result { get; set; } = string.Empty;
|
|
|
|
|
}
|
|
|
|
|
|
2024-07-25 13:12:25 +00:00
|
|
|
|
[Serializable]
|
2024-07-29 08:16:37 +00:00
|
|
|
|
public class NodeStartingEvent
|
2024-07-25 13:12:25 +00:00
|
|
|
|
{
|
|
|
|
|
public string Name { get; set; } = string.Empty;
|
|
|
|
|
public string Image { get; set; } = string.Empty;
|
2024-07-29 08:16:37 +00:00
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
[Serializable]
|
|
|
|
|
public class NodeStartedEvent
|
|
|
|
|
{
|
2024-07-25 13:12:25 +00:00
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
[Serializable]
|
|
|
|
|
public class NodeStoppedEvent
|
|
|
|
|
{
|
|
|
|
|
public string Name { get; set; } = string.Empty;
|
|
|
|
|
}
|
|
|
|
|
|
2024-07-29 08:16:37 +00:00
|
|
|
|
[Serializable]
|
|
|
|
|
public class BootstrapConfigEvent
|
|
|
|
|
{
|
|
|
|
|
public string BootstrapPeerId { get; set; } = string.Empty;
|
|
|
|
|
}
|
|
|
|
|
|
2024-07-25 13:12:25 +00:00
|
|
|
|
[Serializable]
|
|
|
|
|
public class FileUploadedEvent
|
|
|
|
|
{
|
|
|
|
|
public ulong ByteSize { get; set; }
|
|
|
|
|
public string Cid { get; set; } = string.Empty;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
[Serializable]
|
|
|
|
|
public class FileDownloadedEvent
|
|
|
|
|
{
|
|
|
|
|
public string Cid { get; set; } = string.Empty;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
#endregion
|
|
|
|
|
|
|
|
|
|
#region Codex Generated Events
|
|
|
|
|
|
|
|
|
|
[Serializable]
|
|
|
|
|
public class BlockReceivedEvent
|
|
|
|
|
{
|
|
|
|
|
public string BlockAddress { get; set; } = string.Empty;
|
2024-07-26 08:11:29 +00:00
|
|
|
|
public string SenderPeerId { get; set; } = string.Empty;
|
2024-07-25 13:12:25 +00:00
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
#endregion
|
|
|
|
|
}
|