Kenmegne
7 days ago 1bc8864f134272c4bf23a9b05831803a423a4771
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
package com.megatim.apifdxweb.model.tmp;
 
import java.io.Serializable;
import java.time.LocalDateTime;
import javax.persistence.Entity;
import javax.persistence.EnumType;
import javax.persistence.Enumerated;
import javax.persistence.Id;
import javax.persistence.Transient;
import javax.validation.constraints.Min;
import javax.validation.constraints.NotEmpty;
import javax.validation.constraints.NotNull;
import lombok.Getter;
import lombok.Setter;
 
/**
 *
 * @author ASUS
 */
@Getter
@Setter
@Entity
public class TokenTmp implements Serializable {
 
    @Id
    private String token;
 
    @NotNull(message = "Le statut est obligatoire")
    @Enumerated(EnumType.STRING)
    private StatutTmp statutTmp = StatutTmp.EN_COURS;
 
    @Transient
    private int validite;
 
    @NotEmpty(message = "Le typefichier est obligatoire")
    private String codeTypeFichier;
 
    @NotEmpty(message = "Le participant est obligatoire")
    private String codeParticipant;
 
    @Min(value = 1, message = "Le nombre de lots est obligatoire")
    private int nbBatchs;
 
    @Min(value = 1, message = "Le nombre d'éléments par lots est obligatoire")
    private int nbEltsPerBatch;
 
    private int nbOfBatchsReceived;
 
    @NotNull(message = "La date de création est obligatoire")
    private LocalDateTime dateCreation = LocalDateTime.now();
 
    @NotNull(message = "La date d'expiration est obligatoire")
    private LocalDateTime dateExpiration;
 
}