pub enum EtatDateError {
EmptyField(&'static str),
InvalidNotaryEmail,
QuotaOutOfRange(&'static str),
NegativeAmount(&'static str),
InvalidTransition {
from: EtatDateStatus,
to: &'static str,
},
EmptyPdfPath,
AdditionalDataNotObject,
}Expand description
Domain-typed validation error for États Datés (Art. 577-2 CC).
Pure domain type — no infra/application dependency (hexagonal purity).
Suit le précédent JournalEntryError (journal_entry.rs) : l’entité
renvoie son erreur typée, l’application la mappe vers AppError
(#433 / WP-A5 EXP-007) → 400 validation, jamais 500 Internal.
Variants§
EmptyField(&'static str)
Un champ texte obligatoire est vide (nom/email notaire, immeuble…).
InvalidNotaryEmail
Email notaire syntaxiquement invalide.
QuotaOutOfRange(&'static str)
Quote-part hors bornes [0, 100] %.
NegativeAmount(&'static str)
Montant monétaire négatif là où c’est interdit (arriérés, provisions, travaux non payés ≥ 0).
InvalidTransition
Transition de workflow interdite depuis le statut courant.
EmptyPdfPath
Chemin du PDF généré vide.
AdditionalDataNotObject
additional_data n’est pas un objet JSON.
Trait Implementations§
Source§impl Clone for EtatDateError
impl Clone for EtatDateError
Source§fn clone(&self) -> EtatDateError
fn clone(&self) -> EtatDateError
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for EtatDateError
impl Debug for EtatDateError
Source§impl Display for EtatDateError
impl Display for EtatDateError
Source§impl Error for EtatDateError
impl Error for EtatDateError
1.30.0 · Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
use the Display impl or to_string()
Source§impl From<EtatDateError> for AppError
impl From<EtatDateError> for AppError
Source§fn from(e: EtatDateError) -> Self
fn from(e: EtatDateError) -> Self
Un état daté malformé (quote-part hors bornes, montant négatif
interdit, transition workflow invalide, champ obligatoire vide) est
une erreur d’entrée client → 400 validation, jamais 500 Internal
(le From<String> générique mappait à tort vers Internal) —
#433 / WP-A5 EXP-007.
Source§impl From<EtatDateError> for String
Bridge : les use-cases/ports Result<_, String> compilent inchangés
pendant que l’entité est typée (cascade String→AppError = slice plus
large, hors scope WP-A5 — précédent WP-A3/A4). Pur, std-only.
impl From<EtatDateError> for String
Bridge : les use-cases/ports Result<_, String> compilent inchangés
pendant que l’entité est typée (cascade String→AppError = slice plus
large, hors scope WP-A5 — précédent WP-A3/A4). Pur, std-only.
Source§fn from(e: EtatDateError) -> String
fn from(e: EtatDateError) -> String
Source§impl PartialEq for EtatDateError
impl PartialEq for EtatDateError
Source§fn eq(&self, other: &EtatDateError) -> bool
fn eq(&self, other: &EtatDateError) -> bool
self and other values to be equal, and is used by ==.impl StructuralPartialEq for EtatDateError
Auto Trait Implementations§
impl Freeze for EtatDateError
impl RefUnwindSafe for EtatDateError
impl Send for EtatDateError
impl Sync for EtatDateError
impl Unpin for EtatDateError
impl UnsafeUnpin for EtatDateError
impl UnwindSafe for EtatDateError
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<T> Fake for T
impl<T> Fake for T
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more