01: /*
02: * Copyright 2006-2007 The Kuali Foundation.
03: *
04: * Licensed under the Educational Community License, Version 1.0 (the "License");
05: * you may not use this file except in compliance with the License.
06: * You may obtain a copy of the License at
07: *
08: * http://www.opensource.org/licenses/ecl1.php
09: *
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.module.financial.service;
18:
19: import java.io.OutputStream;
20:
21: import org.kuali.module.financial.document.CashReceiptDocument;
22:
23: /**
24: * Service for handling creation of the cover sheet of the <code>{@link CashReceiptDocument}</code>
25: *
26: */
27: public interface CashReceiptCoverSheetService {
28:
29: /**
30: * This method determines whether or not cover sheet printing is allowed for the provided cash receipt document.
31: *
32: * @param crDoc The document that the cover sheet will be printed for.
33: * @return True if coverSheet printing is allowed for the given CashReceiptDocument, false otherwise.
34: */
35: public boolean isCoverSheetPrintingAllowed(CashReceiptDocument crDoc);
36:
37: /**
38: * Generate a cover sheet for the <code>{@link CashReceiptDocument}</code>. An <code>{@link OutputStream}</code> is written
39: * to for the coversheet.
40: *
41: * @param document The <code>{@link CashReceiptDocument}</code> the cover sheet is being generated for.
42: * @param searchPath A directory path used to identify the path to the template that will be used for creating this cover sheet.
43: * @param OutputStream The output stream that the printable cover sheet will be piped to.
44: * @exception Exception Thrown if there are any problems generating the cover sheet.
45: */
46: public void generateCoverSheet(CashReceiptDocument document,
47: String searchPath, OutputStream outputStream)
48: throws Exception;
49: }
|