1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20 package org.kuali.ole.module.purap.businessobject;
21
22 import org.kuali.ole.module.purap.document.ElectronicInvoiceRejectDocument;
23
24 import java.io.File;
25 import java.util.ArrayList;
26 import java.util.HashMap;
27 import java.util.List;
28 import java.util.Map;
29
30 public class ElectronicInvoiceLoad {
31
32 private static org.apache.log4j.Logger LOG = org.apache.log4j.Logger.getLogger(ElectronicInvoiceLoad.class);
33
34 private Map invoiceLoadSummaries;
35 private Map rejectFilesToMove;
36 private List rejectDocumentList;
37
38 public ElectronicInvoiceLoad() {
39 invoiceLoadSummaries = new HashMap();
40 rejectFilesToMove = new HashMap();
41 rejectDocumentList = new ArrayList();
42 }
43
44 public void insertInvoiceLoadSummary(ElectronicInvoiceLoadSummary eils) {
45 invoiceLoadSummaries.put(eils.getVendorDunsNumber(), eils);
46 }
47
48 public void addRejectFileToMove(File file, String directory) {
49 rejectFilesToMove.put(file, directory);
50 }
51
52 public void addInvoiceReject(ElectronicInvoiceRejectDocument eir) {
53 rejectDocumentList.add(eir);
54 }
55
56 public List getRejectDocuments() {
57 return rejectDocumentList;
58 }
59
60 public Map getInvoiceLoadSummaries() {
61 return invoiceLoadSummaries;
62 }
63
64 public void setInvoiceLoadSummaries(Map invoiceLoadSummaries) {
65 this.invoiceLoadSummaries = invoiceLoadSummaries;
66 }
67
68 public Map getRejectFilesToMove() {
69 return rejectFilesToMove;
70 }
71
72 public boolean containsRejects() {
73 return !rejectDocumentList.isEmpty();
74 }
75
76 }