Package com.inductiveautomation.rm.base
Class RMCSVReader
java.lang.Object
com.inductiveautomation.rm.base.RMCSVReader
A class for reading file of comma separated values, or really any separated values.
- 
Constructor SummaryConstructors
- 
Method SummaryModifier and TypeMethodDescriptionReturns the entity generated from last readRecords.Returns the field delimiter.intReturns the number of field delimiters found in last readFormat.booleanReturns whether first row has field names.booleanReturns whether fields are quoted.Returns the record delimiter.intReturns the number of record delimeters found in last readFormat.getSourceName(Object aSource) Returns the source name.getSourceString(Object aSource) Creates the source string.voidreadFormat(String aString) Analyzes the given string and sets reader format attributes.readObject(Object aSource) Reads given source and returns list of maps.readObject(Object aSource, Entity anEntity) Reads given source and returns list of maps.readObject(Object aSource, String aName, boolean doReadFormat) Reads records from given string (and creates entity).voidsetFieldDelimiter(String aDelimiter) Sets the field delimiter.voidsetHasHeaderRow(boolean aFlag) Sets whether first row has field names.voidsetHasQuotedFields(boolean aFlag) Sets whether records are quoted.voidsetRecordDelimiter(String aDelimiter) Sets the record delimiter.
- 
Constructor Details- 
RMCSVReaderpublic RMCSVReader()
 
- 
- 
Method Details- 
getFieldDelimiterReturns the field delimiter.
- 
setFieldDelimiterSets the field delimiter.
- 
getRecordDelimiterReturns the record delimiter.
- 
setRecordDelimiterSets the record delimiter.
- 
getHasHeaderRowpublic boolean getHasHeaderRow()Returns whether first row has field names.
- 
setHasHeaderRowpublic void setHasHeaderRow(boolean aFlag) Sets whether first row has field names.
- 
getHasQuotedFieldspublic boolean getHasQuotedFields()Returns whether fields are quoted.
- 
setHasQuotedFieldspublic void setHasQuotedFields(boolean aFlag) Sets whether records are quoted.
- 
readObjectReads given source and returns list of maps.
- 
readObjectReads given source and returns list of maps.
- 
readObjectReads records from given string (and creates entity).
- 
readFormatAnalyzes the given string and sets reader format attributes.
- 
getFieldDelimiterCountpublic int getFieldDelimiterCount()Returns the number of field delimiters found in last readFormat.
- 
getEntityReturns the entity generated from last readRecords.
- 
getRecordDelimiterCountpublic int getRecordDelimiterCount()Returns the number of record delimeters found in last readFormat.
- 
getSourceNameReturns the source name.
- 
getSourceStringCreates the source string.
 
-