-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy pathData.cs
More file actions
22 lines (14 loc) · 691 Bytes
/
Data.cs
File metadata and controls
22 lines (14 loc) · 691 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
using FreeAwait;
using System.Collections.Generic;
namespace TodoBackend
{
public record Todo(int Id, string Title, bool Completed, int? Order = default, string? Url = default);
public record Create(string Title, int? Order): IStep<Create, Todo>;
public record Read(int Id): IStep<Read, Todo?>;
public record ReadAll(): IStep<ReadAll, IEnumerable<Todo>>;
public record Delete(int Id): IStep<Delete, Todo?>;
public record DeleteAll(): IStep<DeleteAll, Void>;
public record Locate(Todo Item): IStep<Locate, Todo>;
public record Patch(string? Title, bool? Completed, int? Order);
public record Update(int Id, Patch patch): IStep<Update, Todo?>;
}