summaryrefslogtreecommitdiff
path: root/CommandLineWrapper/JsonResults/Implements/StatusResult.cs
diff options
context:
space:
mode:
Diffstat (limited to 'CommandLineWrapper/JsonResults/Implements/StatusResult.cs')
-rw-r--r--CommandLineWrapper/JsonResults/Implements/StatusResult.cs36
1 files changed, 36 insertions, 0 deletions
diff --git a/CommandLineWrapper/JsonResults/Implements/StatusResult.cs b/CommandLineWrapper/JsonResults/Implements/StatusResult.cs
new file mode 100644
index 0000000..aba2c25
--- /dev/null
+++ b/CommandLineWrapper/JsonResults/Implements/StatusResult.cs
@@ -0,0 +1,36 @@
+using CommandLineWrapper;
+using CommandLineWrapper.JsonResults;
+
+public class StatusResultGetter : JsonResultGetter<StatusResult>
+{
+ protected override Task<JVCSCommandInvoker.InvokeResult> ExecCommand(JVCSWorkspace workspace)
+ => workspace.Status();
+}
+
+public struct StatusResult
+{
+ public List<string> Created { get; set; }
+ public List<string> Lost { get; set; }
+ public List<string> Erased { get; set; }
+ public List<MovedItem> Moved { get; set; }
+ public List<ModifiedItem> Modified { get; set; }
+}
+
+public enum ModifiedType
+{
+ Modified,
+ ModifiedButBaseVersionMismatch,
+ ModifiedButNotHeld,
+}
+
+public struct MovedItem
+{
+ public string From { get; set; }
+ public string To { get; set; }
+}
+
+public struct ModifiedItem
+{
+ public string Path { get; set; }
+ public ModifiedType ModificationType { get; set; }
+}