1 /*
2 * Copyright 2006 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 package org.kuali.ole.gl.batch.service.impl;
17
18 import org.kuali.ole.gl.batch.service.SufficientFundsFullRebuildService;
19 import org.kuali.ole.gl.dataaccess.SufficientFundRebuildDao;
20 import org.springframework.transaction.annotation.Transactional;
21
22 /**
23 * The base implementation of SufficientFundsFullRebuildService
24 */
25 @Transactional
26 public class SufficientFundsFullRebuildServiceImpl implements SufficientFundsFullRebuildService {
27 private static org.apache.log4j.Logger LOG = org.apache.log4j.Logger.getLogger(SufficientFundsFullRebuildServiceImpl.class);
28
29 private SufficientFundRebuildDao sufficientFundRebuildDao;
30
31 /**
32 * Goes through all accounts in the database, and generates a sufficient fund rebuild record for each one!
33 * @see org.kuali.ole.gl.batch.service.SufficientFundsFullRebuildService#syncSufficientFunds()
34 */
35 public void syncSufficientFunds() {
36 LOG.debug("syncSufficientFunds() started");
37
38 sufficientFundRebuildDao.purgeSufficientFundRebuild();
39
40 sufficientFundRebuildDao.populateSufficientFundRebuild();
41
42 }
43
44 public void setSufficientFundRebuildDao(SufficientFundRebuildDao sfd) {
45 sufficientFundRebuildDao = sfd;
46 }
47
48 }