-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy pathFee.java
More file actions
72 lines (54 loc) · 1.55 KB
/
Fee.java
File metadata and controls
72 lines (54 loc) · 1.55 KB
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
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
package com.tecacet.money.domain;
import org.hibernate.annotations.Columns;
import org.hibernate.annotations.CreationTimestamp;
import javax.money.MonetaryAmount;
import javax.persistence.*;
import javax.validation.constraints.NotNull;
import java.time.LocalDateTime;
import java.util.UUID;
@Entity
@Table(name = "fee")
public class Fee {
@Id
@GeneratedValue(strategy = GenerationType.AUTO)
private UUID id;
@NotNull(message = "Client ID is required")
private String clientId;
private String description;
@Columns(columns = {@Column(name = "amount"), @Column(name = "currency")})
@NotNull(message = "Amount is required")
private MonetaryAmount amount;
@Column(name = "created", nullable = false, updatable = false)
@CreationTimestamp
private LocalDateTime created;
public UUID getId() {
return id;
}
public void setId(UUID id) {
this.id = id;
}
public String getClientId() {
return clientId;
}
public void setClientId(String clientId) {
this.clientId = clientId;
}
public String getDescription() {
return description;
}
public void setDescription(String description) {
this.description = description;
}
public MonetaryAmount getAmount() {
return amount;
}
public void setAmount(MonetaryAmount amount) {
this.amount = amount;
}
public LocalDateTime getCreated() {
return created;
}
public void setCreated(LocalDateTime created) {
this.created = created;
}
}