1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16 package org.kuali.rice.kns.test.document.bo;
17
18 import java.util.LinkedHashMap;
19 import java.util.List;
20
21 import org.apache.commons.lang.ObjectUtils;
22 import org.apache.commons.lang.StringUtils;
23 import org.kuali.rice.kns.bo.PersistableBusinessObjectBase;
24
25
26
27
28
29 public class AccountManager extends PersistableBusinessObjectBase {
30
31 private String userName;
32 private Long amId;
33 private String defaultType;
34 private List<Account> accounts;
35
36 public void setUserName(String userId) {
37 userName = userId;
38 }
39
40 public String getUserName() {
41 return userName;
42 }
43
44 public String getDefaultType() {
45 return this.defaultType;
46 }
47
48 public void setDefaultType(String defaultType) {
49 this.defaultType = defaultType;
50 }
51
52 public final boolean equals(Object o) {
53 if (o == null) return false;
54 if (!(o instanceof AccountManager)) return false;
55 AccountManager am = (AccountManager) o;
56 return StringUtils.equals(userName, am.getUserName()) &&
57 ObjectUtils.equals(amId, am.getAmId());
58 }
59
60
61
62
63
64
65
66
67
68
69
70 public Long getAmId() {
71 return amId;
72 }
73
74 public void setAmId(Long id) {
75 this.amId = id;
76 }
77
78 public List<Account> getAccounts() {
79 return accounts;
80 }
81
82 public void setAccounts(List<Account> accounts) {
83 this.accounts = accounts;
84 }
85
86
87
88
89
90 public String toString() {
91 return "[FiscalOfficer: id=" + amId +
92 ", userName=" + userName +
93 "]";
94 }
95
96 @Override
97 protected LinkedHashMap toStringMapper() {
98 LinkedHashMap propMap = new LinkedHashMap();
99 propMap.put("id", getAmId());
100 propMap.put("userName", getUserName());
101 return propMap;
102 }
103
104 }