1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16 package org.kuali.ole.module.purap.businessobject;
17
18 import org.kuali.ole.sys.context.SpringContext;
19 import org.kuali.rice.core.api.datetime.DateTimeService;
20 import org.kuali.rice.krad.bo.PersistableBusinessObjectBase;
21
22 import java.util.ArrayList;
23 import java.util.Date;
24 import java.util.LinkedHashMap;
25 import java.util.List;
26
27 public class SensitiveDataAssignment extends PersistableBusinessObjectBase {
28
29 private Integer sensitiveDataAssignmentIdentifier;
30 private Integer purapDocumentIdentifier;
31 private String sensitiveDataAssignmentReasonText;
32 private String sensitiveDataAssignmentPersonIdentifier;
33 private Date sensitiveDataAssignmentChangeDate;
34
35 private List<SensitiveDataAssignmentDetail> sensitiveDataAssignmentDetails;
36
37 public SensitiveDataAssignment() {
38 super();
39 }
40
41 public SensitiveDataAssignment(Integer poId, String sensitiveDataAssignmentReasonText, String sensitiveDataAssignmentPersonIdentifier, List<SensitiveData> sensitiveDataToAssign) {
42 super();
43 setPurapDocumentIdentifier(poId);
44 setSensitiveDataAssignmentReasonText(sensitiveDataAssignmentReasonText);
45 setSensitiveDataAssignmentPersonIdentifier(sensitiveDataAssignmentPersonIdentifier);
46 setSensitiveDataAssignmentChangeDate(SpringContext.getBean(DateTimeService.class).getCurrentSqlDate());
47
48 sensitiveDataAssignmentDetails = new ArrayList<SensitiveDataAssignmentDetail>();
49 for (SensitiveData sd : sensitiveDataToAssign) {
50 sensitiveDataAssignmentDetails.add(new SensitiveDataAssignmentDetail(sd.getSensitiveDataCode(), this));
51 }
52 }
53
54
55 public Integer getPurapDocumentIdentifier() {
56 return purapDocumentIdentifier;
57 }
58
59 public void setPurapDocumentIdentifier(Integer purapDocumentIdentifier) {
60 this.purapDocumentIdentifier = purapDocumentIdentifier;
61 }
62
63 public Date getSensitiveDataAssignmentChangeDate() {
64 return sensitiveDataAssignmentChangeDate;
65 }
66
67 public void setSensitiveDataAssignmentChangeDate(Date sensitiveDataAssignmentChangeDate) {
68 this.sensitiveDataAssignmentChangeDate = sensitiveDataAssignmentChangeDate;
69 }
70
71 public Integer getSensitiveDataAssignmentIdentifier() {
72 return sensitiveDataAssignmentIdentifier;
73 }
74
75 public void setSensitiveDataAssignmentIdentifier(Integer sensitiveDataAssignmentIdentifier) {
76 this.sensitiveDataAssignmentIdentifier = sensitiveDataAssignmentIdentifier;
77 }
78
79 public String getSensitiveDataAssignmentPersonIdentifier() {
80 return sensitiveDataAssignmentPersonIdentifier;
81 }
82
83 public void setSensitiveDataAssignmentPersonIdentifier(String sensitiveDataAssignmentPersonIdentifier) {
84 this.sensitiveDataAssignmentPersonIdentifier = sensitiveDataAssignmentPersonIdentifier;
85 }
86
87 public String getSensitiveDataAssignmentReasonText() {
88 return sensitiveDataAssignmentReasonText;
89 }
90
91
92 public void setSensitiveDataAssignmentReasonText(String sensitiveDataAssignmentReasonText) {
93 this.sensitiveDataAssignmentReasonText = sensitiveDataAssignmentReasonText;
94 }
95
96 protected LinkedHashMap toStringMapper_RICE20_REFACTORME() {
97 LinkedHashMap m = new LinkedHashMap();
98 m.put("sensitiveDataAssignmentIdentifier", this.sensitiveDataAssignmentIdentifier);
99 return m;
100 }
101
102 public List<SensitiveDataAssignmentDetail> getSensitiveDataAssignmentDetails() {
103 return sensitiveDataAssignmentDetails;
104 }
105
106 public void setSensitiveDataAssignmentDetails(List<SensitiveDataAssignmentDetail> sensitiveDataAssignmentDetails) {
107 this.sensitiveDataAssignmentDetails = sensitiveDataAssignmentDetails;
108 }
109 }