Refactoring et amélioration de la création et l'affichage d'un évènement.

This commit is contained in:
DahoudG
2024-09-02 03:04:40 +00:00
parent b8d7cfcb8d
commit 7bc7761591
9 changed files with 226 additions and 95 deletions

View File

@@ -1,4 +1,11 @@
class ServerException implements Exception {}
class ServerException implements Exception {
final String message;
ServerException([this.message = 'Une erreur serveur est survenue']);
@override
String toString() => 'ServerException: $message';
}
class CacheException implements Exception {}
@@ -10,3 +17,13 @@ class AuthenticationException implements Exception {
@override
String toString() => 'AuthenticationException: $message';
}
class ServerExceptionWithMessage implements Exception {
final String message;
ServerExceptionWithMessage(this.message);
@override
String toString() => 'ServerException: $message';
}