View Javadoc
1   /*
2    * Copyright 2006-2008 The Kuali Foundation
3    * 
4    * Licensed under the Educational Community License, Version 2.0 (the "License");
5    * you may not use this file except in compliance with the License.
6    * You may obtain a copy of the License at
7    * 
8    * http://www.opensource.org/licenses/ecl2.php
9    * 
10   * Unless required by applicable law or agreed to in writing, software
11   * distributed under the License is distributed on an "AS IS" BASIS,
12   * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13   * See the License for the specific language governing permissions and
14   * limitations under the License.
15   */
16  
17  package org.kuali.ole.module.purap.businessobject;
18  
19  import org.kuali.ole.coa.businessobject.AccountingPeriod;
20  import org.kuali.ole.module.purap.util.PurApObjectUtils;
21  import org.kuali.ole.sys.context.SpringContext;
22  import org.kuali.rice.core.api.datetime.DateTimeService;
23  
24  import java.sql.Timestamp;
25  import java.util.HashMap;
26  import java.util.HashSet;
27  
28  /**
29   * Payment Request Account Revision Business Object.
30   */
31  public class PaymentRequestAccountRevision extends PaymentRequestAccount {
32  
33      protected Integer accountRevisionIdentifier;
34      private Timestamp accountRevisionTimestamp;
35  
36      private AccountingPeriod accountingPeriod;
37  
38      public AccountingPeriod getAccountingPeriod() {
39          return accountingPeriod;
40      }
41  
42      public void setAccountingPeriod(AccountingPeriod accountingPeriod) {
43          this.accountingPeriod = accountingPeriod;
44      }
45  
46      /**
47       * Default constructor.
48       */
49      public PaymentRequestAccountRevision() {
50  
51      }
52  
53      /**
54       * Constructor.
55       *
56       * @param account - payment request account
57       */
58      public PaymentRequestAccountRevision(PaymentRequestAccount pra, Integer postingYear, String postingPeriodCode) {
59          // copy base attributes
60          PurApObjectUtils.populateFromBaseWithSuper(pra, this, new HashMap<String, Class<?>>(), new HashSet<Class>());
61          this.setAccountRevisionTimestamp(SpringContext.getBean(DateTimeService.class).getCurrentTimestamp());
62          this.setPostingYear(postingYear);
63          this.setPostingPeriodCode(postingPeriodCode);
64      }
65  
66      public Integer getAccountRevisionIdentifier() {
67          return accountRevisionIdentifier;
68      }
69  
70      public void setAccountRevisionIdentifier(Integer accountRevisionIdentifier) {
71          this.accountRevisionIdentifier = accountRevisionIdentifier;
72      }
73  
74      public Timestamp getAccountRevisionTimestamp() {
75          return accountRevisionTimestamp;
76      }
77  
78      public void setAccountRevisionTimestamp(Timestamp accountRevisionTimestamp) {
79          this.accountRevisionTimestamp = accountRevisionTimestamp;
80      }
81  
82  }