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.integration.cg; 017 018 import java.util.List; 019 020 import org.kuali.kfs.coa.businessobject.Account; 021 import org.kuali.rice.kim.bo.Person; 022 023 public interface ContractsAndGrantsModuleService { 024 025 public Person getProjectDirectorForAccount(String chartOfAccountsCode, String accountNumber); 026 027 public Person getProjectDirectorForAccount(Account account); 028 029 /** 030 * determine if the given account is awarded by a federal agency 031 * 032 * @param chartOfAccountsCode the given account's chart of accounts code 033 * @param accountNumber the given account's account number 034 * @param federalAgencyTypeCodes the given federal agency type code 035 * @return true if the given account is funded by a federal agency or associated with federal pass through indicator; otherwise, 036 * false 037 */ 038 public boolean isAwardedByFederalAgency(String chartOfAccountsCode, String accountNumber, List<String> federalAgencyTypeCodes); 039 040 /** 041 * get all possible account responsibility ids on contracts & grants Accounts 042 * 043 * @return all possible account responsibility ids on contracts & grants Accounts 044 */ 045 public List<Integer> getAllAccountReponsiblityIds(); 046 047 /** 048 * determine whether the given account has a valid responsibility id if its responsibility id is not null 049 * 050 * @param account the given account 051 * @return true if the given account is a contracts & grants account with a valid responsibility id; otherwise, return false 052 */ 053 public boolean hasValidAccountReponsiblityIdIfNotNull(Account account); 054 055 public List<String> getParentUnits(String unitNumber); 056 057 /** 058 * Returns the proposal number for an award associated with an account and project director 059 * 060 * @param chartOfAccountsCode 061 * @param accountNumber 062 * @return 063 */ 064 public String getProposalNumberForAccountAndProjectDirector(String chartOfAccountsCode, String accountNumber, String projectDirectorId); 065 } 066