001 /* 002 * Copyright 2011 The Kuali Foundation. 003 * 004 * Licensed under the Educational Community License, Version 2.0 (the "License"); 005 * you may not use this file except in compliance with the License. 006 * You may obtain a copy of the License at 007 * 008 * http://www.opensource.org/licenses/ecl2.php 009 * 010 * Unless required by applicable law or agreed to in writing, software 011 * distributed under the License is distributed on an "AS IS" BASIS, 012 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 013 * See the License for the specific language governing permissions and 014 * limitations under the License. 015 */ 016 package org.kuali.kfs.module.endow.businessobject; 017 018 import java.math.BigDecimal; 019 import java.util.LinkedHashMap; 020 021 import org.kuali.kfs.module.endow.EndowConstants; 022 import org.kuali.kfs.module.endow.EndowPropertyConstants; 023 import org.kuali.rice.kns.bo.PersistableBusinessObjectBase; 024 import org.kuali.rice.kns.util.KualiInteger; 025 026 /** 027 * Business Object for KEMID Historical Balance Detail View. 028 */ 029 public class KEMIDHistoricalBalanceDetail extends PersistableBusinessObjectBase { 030 031 private String kemid; 032 033 private KualiInteger historyBalanceDateId; 034 private String incomePrincipalIndicator; 035 private String reportingGroupCode; 036 private BigDecimal valueAtMarket; 037 private BigDecimal annualEstimatedIncome; // next 12 months estimated income 038 private BigDecimal remainderOfFYEstimatedIncome; 039 private BigDecimal nextFYEstimatedIncome; 040 041 private KEMID kemidObj; 042 private MonthEndDate historyBalanceDate; 043 private SecurityReportingGroup reportingGroup; 044 private IncomePrincipalIndicator ipIndicator; 045 046 /** 047 * @see org.kuali.rice.kns.bo.BusinessObjectBase#toStringMapper() 048 */ 049 @Override 050 protected LinkedHashMap toStringMapper() { 051 LinkedHashMap m = new LinkedHashMap(); 052 m.put(EndowPropertyConstants.KEMID, this.kemid); 053 return m; 054 } 055 056 /** 057 * Gets the incomeAtMarket. If icome principal indicator is 'I' then the valueAtMarket represents the incomeAtMarket. Otherwise 058 * the incomeAtMarket will be zero. 059 * 060 * @return incomeAtMarket 061 */ 062 public BigDecimal getIncomeAtMarket() { 063 BigDecimal incomeAtMarket = BigDecimal.ZERO; 064 if (EndowConstants.IncomePrincipalIndicator.INCOME.equalsIgnoreCase(incomePrincipalIndicator)) { 065 incomeAtMarket = valueAtMarket; 066 } 067 return incomeAtMarket; 068 } 069 070 /** 071 * Gets the principalAtMarket. If icome principal indicator is 'P' then the valueAtMarket represents the principalAtMarket. 072 * Otherwise the principalAtMarket will be zero. 073 * 074 * @return 075 */ 076 public BigDecimal getPrincipalAtMarket() { 077 BigDecimal principalAtMarket = BigDecimal.ZERO; 078 if (EndowConstants.IncomePrincipalIndicator.PRINCIPAL.equalsIgnoreCase(incomePrincipalIndicator)) { 079 principalAtMarket = valueAtMarket; 080 } 081 return principalAtMarket; 082 } 083 084 /** 085 * Gets the annualEstimatedIncome. 086 * 087 * @return annualEstimatedIncome 088 */ 089 public BigDecimal getAnnualEstimatedIncome() { 090 return annualEstimatedIncome; 091 } 092 093 /** 094 * Sets the annualEstimatedIncome. 095 * 096 * @param annualEstimatedIncome 097 */ 098 public void setAnnualEstimatedIncome(BigDecimal annualEstimatedIncome) { 099 this.annualEstimatedIncome = annualEstimatedIncome; 100 } 101 102 /** 103 * Gets the historyBalanceDate. 104 * 105 * @return historyBalanceDate 106 */ 107 public MonthEndDate getHistoryBalanceDate() { 108 return historyBalanceDate; 109 } 110 111 /** 112 * Sets the historyBalanceDate. 113 * 114 * @param historyBalanceDate 115 */ 116 public void setHistoryBalanceDate(MonthEndDate historyBalanceDate) { 117 this.historyBalanceDate = historyBalanceDate; 118 } 119 120 /** 121 * Gets the historyBalanceDateId. 122 * 123 * @return historyBalanceDateId 124 */ 125 public KualiInteger getHistoryBalanceDateId() { 126 return historyBalanceDateId; 127 } 128 129 /** 130 * Sets the historyBalanceDateId. 131 * 132 * @param historyBalanceDateId 133 */ 134 public void setHistoryBalanceDateId(KualiInteger historyBalanceDateId) { 135 this.historyBalanceDateId = historyBalanceDateId; 136 } 137 138 /** 139 * Gets the incomePrincipalIndicator. 140 * 141 * @return incomePrincipalIndicator 142 */ 143 public String getIncomePrincipalIndicator() { 144 return incomePrincipalIndicator; 145 } 146 147 /** 148 * Sets the incomePrincipalIndicator. 149 * 150 * @param incomePrincipalIndicator 151 */ 152 public void setIncomePrincipalIndicator(String incomePrincipalIndicator) { 153 this.incomePrincipalIndicator = incomePrincipalIndicator; 154 } 155 156 /** 157 * Gets the ipIndicator. 158 * 159 * @return ipIndicator 160 */ 161 public IncomePrincipalIndicator getIpIndicator() { 162 return ipIndicator; 163 } 164 165 /** 166 * Sets the ipIndicator. 167 * 168 * @param ipIndicator 169 */ 170 public void setIpIndicator(IncomePrincipalIndicator ipIndicator) { 171 this.ipIndicator = ipIndicator; 172 } 173 174 /** 175 * Gets the kemid. 176 * 177 * @return kemid 178 */ 179 public String getKemid() { 180 return kemid; 181 } 182 183 /** 184 * Sets the kemid. 185 * 186 * @param kemid 187 */ 188 public void setKemid(String kemid) { 189 this.kemid = kemid; 190 } 191 192 /** 193 * Gets the kemidObj. 194 * 195 * @return kemidObj 196 */ 197 public KEMID getKemidObj() { 198 return kemidObj; 199 } 200 201 /** 202 * Sets the kemidObj. 203 * 204 * @param kemidObj 205 */ 206 public void setKemidObj(KEMID kemidObj) { 207 this.kemidObj = kemidObj; 208 } 209 210 /** 211 * Gets the nextFYEstimatedIncome. 212 * 213 * @return nextFYEstimatedIncome 214 */ 215 public BigDecimal getNextFYEstimatedIncome() { 216 return nextFYEstimatedIncome; 217 } 218 219 /** 220 * Sets the nextFYEstimatedIncome. 221 * 222 * @param nextFYEstimatedIncome 223 */ 224 public void setNextFYEstimatedIncome(BigDecimal nextFYEstimatedIncome) { 225 this.nextFYEstimatedIncome = nextFYEstimatedIncome; 226 } 227 228 /** 229 * Gets the remainderOfFYEstimatedIncome. 230 * 231 * @return remainderOfFYEstimatedIncome 232 */ 233 public BigDecimal getRemainderOfFYEstimatedIncome() { 234 return remainderOfFYEstimatedIncome; 235 } 236 237 /** 238 * Sets the remainderOfFYEstimatedIncome. 239 * 240 * @param remainderOfFYEstimatedIncome 241 */ 242 public void setRemainderOfFYEstimatedIncome(BigDecimal remainderOfFYEstimatedIncome) { 243 this.remainderOfFYEstimatedIncome = remainderOfFYEstimatedIncome; 244 } 245 246 /** 247 * Gets the reportingGroup. 248 * 249 * @return reportingGroup 250 */ 251 public SecurityReportingGroup getReportingGroup() { 252 return reportingGroup; 253 } 254 255 /** 256 * Sets the reportingGroup. 257 * 258 * @param reportingGroup 259 */ 260 public void setReportingGroup(SecurityReportingGroup reportingGroup) { 261 this.reportingGroup = reportingGroup; 262 } 263 264 /** 265 * Gets the reportingGroupCode. 266 * 267 * @return reportingGroupCode 268 */ 269 public String getReportingGroupCode() { 270 return reportingGroupCode; 271 } 272 273 /** 274 * Sets the reportingGroupCode. 275 * 276 * @param reportingGroupCode 277 */ 278 public void setReportingGroupCode(String reportingGroupCode) { 279 this.reportingGroupCode = reportingGroupCode; 280 } 281 282 /** 283 * Gets the valueAtMarket. 284 * 285 * @return valueAtMarket 286 */ 287 public BigDecimal getValueAtMarket() { 288 return valueAtMarket; 289 } 290 291 /** 292 * Sets the valueAtMarket. 293 * 294 * @param valueAtMarket 295 */ 296 public void setValueAtMarket(BigDecimal valueAtMarket) { 297 this.valueAtMarket = valueAtMarket; 298 } 299 300 301 }