public class CSVFileStoreConnector extends BasicFileStoreConnector implements CSVFileStore
ConnectorBase.ProtectedConnectionfileStoreNameconnectedAssetProperties, connectionBean, connectionProperties, connectorInstanceId, securedProperties| Constructor and Description |
|---|
CSVFileStoreConnector() |
| Modifier and Type | Method and Description |
|---|---|
void |
disconnect()
Close the file
|
List<String> |
getColumnNames()
Return the list of column names associated with this structured file.
|
String |
getFileName()
Return the name of the file to read.
|
Date |
getLastUpdateDate()
Return the last update data for the file.
|
long |
getRecordCount()
Return the number of records in the file.
|
void |
initialize(String connectorInstanceId,
ConnectionProperties connectionProperties)
Initialize the connector.
|
List<String> |
readRecord(int dataRecordNumber)
Return the requested data record.
|
getFile, getFileequals, getConnectedAssetProperties, getConnection, getConnectorInstanceId, hashCode, initializeConnectedAssetProperties, isActive, start, toStringclone, finalize, getClass, notify, notifyAll, wait, wait, waitgetFilepublic void initialize(String connectorInstanceId, ConnectionProperties connectionProperties)
initialize in class BasicFileStoreConnectorconnectorInstanceId - - unique id for the connector instance - useful for messages etcconnectionProperties - - POJO for the configuration used to create the connector.public String getFileName() throws FileException
getFileName in interface CSVFileStoreFileException - problem accessing the filepublic Date getLastUpdateDate() throws FileException
getLastUpdateDate in interface CSVFileStoreFileException - problem accessing the filepublic long getRecordCount()
throws FileException,
FileReadException
getRecordCount in interface CSVFileStoreFileException - problem accessing the fileFileReadException - unable to find, open or scan the file.public List<String> getColumnNames() throws FileException, FileReadException
getColumnNames in interface CSVFileStoreFileException - problem accessing the fileFileReadException - unable to retrieve the column namespublic List<String> readRecord(int dataRecordNumber) throws FileException, FileReadException
readRecord in interface CSVFileStoredataRecordNumber - longFileException - problem accessing the fileFileReadException - unable to find, open or read the file, or the file does not include the requested record.public void disconnect()
disconnect in class BasicFileStoreConnectorCopyright © 2018–2021 LF AI & Data Foundation. All rights reserved.