From 23a46b4be35277e06ec89f48730eeb694e686be8 Mon Sep 17 00:00:00 2001
From: Kenmegne <stephanie.kenmegne@gmail.com>
Date: Thu, 18 Jun 2026 15:40:06 +0000
Subject: [PATCH] add fdx-commons and fdx-consultation

---
 fdx-commons/fdxcommons-model/src/main/java/com/megatim/fdxcommons/model/referentiel/ValidateurFichier.java |   99 +++++++++++++++++++++++++++++++++++++++++++++++++
 1 files changed, 99 insertions(+), 0 deletions(-)

diff --git a/fdx-commons/fdxcommons-model/src/main/java/com/megatim/fdxcommons/model/referentiel/ValidateurFichier.java b/fdx-commons/fdxcommons-model/src/main/java/com/megatim/fdxcommons/model/referentiel/ValidateurFichier.java
new file mode 100644
index 0000000..ac59c89
--- /dev/null
+++ b/fdx-commons/fdxcommons-model/src/main/java/com/megatim/fdxcommons/model/referentiel/ValidateurFichier.java
@@ -0,0 +1,99 @@
+/*
+ * Click nbfs://nbhost/SystemFileSystem/Templates/Licenses/license-default.txt to change this license
+ * Click nbfs://nbhost/SystemFileSystem/Templates/Classes/Class.java to edit this template
+ */
+package com.megatim.fdxcommons.model.referentiel;
+
+import com.fasterxml.jackson.annotation.JsonIgnore;
+import java.io.Serializable;
+import java.time.LocalDateTime;
+import java.util.HashSet;
+import java.util.Objects;
+import java.util.Set;
+import javax.persistence.CascadeType;
+import javax.persistence.Entity;
+import javax.persistence.Id;
+import javax.persistence.ManyToOne;
+import javax.persistence.OneToMany;
+import javax.validation.constraints.NotNull;
+import javax.xml.bind.annotation.XmlAccessType;
+import javax.xml.bind.annotation.XmlAccessorType;
+import javax.xml.bind.annotation.XmlRootElement;
+import javax.xml.bind.annotation.XmlTransient;
+import javax.xml.bind.annotation.adapters.XmlJavaTypeAdapter;
+import lombok.Getter;
+import lombok.NoArgsConstructor;
+import lombok.Setter;
+import org.hibernate.validator.constraints.Range;
+
+/**
+ *
+ * @author ASUS
+ */
+@Entity
+@Getter
+@Setter
+@NoArgsConstructor
+@XmlRootElement
+@XmlAccessorType(XmlAccessType.FIELD)
+public class ValidateurFichier implements Serializable {
+
+    @Id
+    @NotNull(message = "Aucun identifiant spécifié")
+    private String id;
+
+    @Range(min = 1, message = "Le nombre de position doit être supérieure à 0")
+    private int nombrePosition;
+
+    @NotNull(message = "Le type de fichier est obligatoire")
+    @ManyToOne
+    private TypeFichier typeFichier;
+
+    @OneToMany(mappedBy = "validateurFichier", cascade = CascadeType.ALL)
+    @XmlTransient
+    @JsonIgnore
+    private Set<StructureLigne> structureLignes = new HashSet<>();
+
+    @XmlJavaTypeAdapter(LocalDateTimeAdapter.class)
+    private LocalDateTime dateCreation;
+
+    @XmlJavaTypeAdapter(LocalDateTimeAdapter.class)
+    private LocalDateTime dateMiseAjour;
+
+    private String createBy;
+
+    private String lastModifiedBy;
+
+//    @Enumerated(EnumType.STRING)
+//    private EtatIntegration etatIntegration = EtatIntegration.NOUVEAU;
+    @Override
+    public String toString() {
+        return this.typeFichier.toString();
+    }
+
+    @Override
+    public boolean equals(Object obj) {
+        if (this == obj) {
+            return true;
+        }
+        if (obj == null) {
+            return false;
+        }
+        if (!(obj instanceof ValidateurFichier)) {
+            return false;
+        }
+        final ValidateurFichier other = (ValidateurFichier) obj;
+        if (this.getTypeFichier() != null && !this.getTypeFichier().equals(other.getTypeFichier())) {
+            return false;
+        }
+        return true;
+    }
+
+    @Override
+    public int hashCode() {
+        int hash = 3;
+        hash = 53 * hash + Objects.hashCode(this.typeFichier);
+        return hash;
+    }
+
+}

--
Gitblit v1.10.0