subspace model

This commit is contained in:
hannathkadher
2025-01-05 11:45:05 +04:00
parent 944b981ee0
commit 90e5499f92
16 changed files with 346 additions and 148 deletions

View File

@ -0,0 +1,31 @@
enum Action {
update,
add,
delete,
}
extension ActionExtension on Action {
String get value {
switch (this) {
case Action.update:
return 'update';
case Action.add:
return 'add';
case Action.delete:
return 'delete';
}
}
static Action fromValue(String value) {
switch (value) {
case 'update':
return Action.update;
case 'add':
return Action.add;
case 'delete':
return Action.delete;
default:
throw ArgumentError('Invalid action: $value');
}
}
}