-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
35399 Move AgentRoles from transaction-api to dina-base (#478)
- Loading branch information
Showing
1 changed file
with
30 additions
and
0 deletions.
There are no files selected for viewing
30 changes: 30 additions & 0 deletions
30
dina-base-api/src/main/java/ca/gc/aafc/dina/entity/AgentRoles.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
package ca.gc.aafc.dina.entity; | ||
|
||
import java.util.List; | ||
import java.util.UUID; | ||
import javax.validation.constraints.Size; | ||
|
||
import javax.validation.constraints.NotBlank; | ||
import javax.validation.constraints.NotEmpty; | ||
import javax.validation.constraints.NotNull; | ||
import lombok.Builder; | ||
import lombok.Data; | ||
|
||
/** | ||
* Generic representation of an agent with one or multiple roles. | ||
* The agent must have at least 1 role. | ||
*/ | ||
@Data | ||
@Builder | ||
public class AgentRoles { | ||
|
||
@NotNull | ||
private UUID agent; | ||
|
||
@NotEmpty | ||
private List<@NotBlank String> roles; | ||
|
||
@Size(max = 1000) | ||
private String remarks; | ||
|
||
} |