Class ReconciliationFile
- java.lang.Object
-
- com.avoka.fc.core.service.payment.reconciliation.ReconciliationFile
-
public class ReconciliationFile extends Object
Provides a payment Reconciliation File class.- Since:
- 4.0.0
-
-
Constructor Summary
Constructors Constructor Description ReconciliationFile(Client client, String fileName, byte[] contents, Date fileDate, Map<String,Object> csvConfig)
Create a ReconciliationFile object from the specified byte array.ReconciliationFile(Client client, String fileName, String contents, Date fileDate, Map<String,Object> csvConfig)
Create a ReconciliationFile object from the specified content.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description ReconciliationItem
findMatchingItem(String reference1, String reference2)
Attempt to find a entry for the submission in the filestatic String
formatKey(Client client, Date dateStamp)
format a file key to identify the file in the file cacheMap<Date,Long>
getAdditionalDays()
return any additional days.Date
getExpectedStartTimestamp()
return the expected start timestamp.Date
getExpectedStopTimestamp()
return the expected stop timestamp.Date
getFileDate()
Return the file dateString
getFileName()
Return the file nameMap<String,ReconciliationItem>
getReconciliationItems()
Return a map of the reconciliation items and keys contained within the file
-
-
-
Constructor Detail
-
ReconciliationFile
public ReconciliationFile(Client client, String fileName, byte[] contents, Date fileDate, Map<String,Object> csvConfig) throws IOException, ParseException
Create a ReconciliationFile object from the specified byte array.- Parameters:
client
- the client the file is associated withfileName
- the file name of the filecontents
- the contents of the filefileDate
- the date for the filecsvConfig
- the file format configuration- Throws:
IOException
- Signals that an I/O exception has occurred.ParseException
- the parse exception
-
ReconciliationFile
public ReconciliationFile(Client client, String fileName, String contents, Date fileDate, Map<String,Object> csvConfig) throws IOException, ParseException
Create a ReconciliationFile object from the specified content.- Parameters:
client
- the client the file is associated withfileName
- the file name of the filecontents
- the contents of the filefileDate
- the date for the filecsvConfig
- the file format configuration- Throws:
IOException
- Signals that an I/O exception has occurred.ParseException
- the parse exception
-
-
Method Detail
-
getReconciliationItems
public Map<String,ReconciliationItem> getReconciliationItems()
Return a map of the reconciliation items and keys contained within the file- Returns:
- the map of reconciliation items and keys
-
getFileDate
public Date getFileDate()
Return the file date- Returns:
- the file date
-
getFileName
public String getFileName()
Return the file name- Returns:
- the file name
-
findMatchingItem
public ReconciliationItem findMatchingItem(String reference1, String reference2)
Attempt to find a entry for the submission in the file- Parameters:
reference1
- a reference string to look forreference2
- a second reference to look for if the first is not found- Returns:
- the found line item, null if not found
-
formatKey
public static String formatKey(Client client, Date dateStamp)
format a file key to identify the file in the file cache- Parameters:
client
- the client the file is related todateStamp
- the datestamp for the file- Returns:
- the file key
-
getExpectedStartTimestamp
public Date getExpectedStartTimestamp()
return the expected start timestamp.- Returns:
- the expected start timestamp
-
getExpectedStopTimestamp
public Date getExpectedStopTimestamp()
return the expected stop timestamp.- Returns:
- the expected stop timestamp
-
-