Class CellTypeRange
-
- All Implemented Interfaces:
Destroyable,GlobalInfoSupporter,LoggingLevelHandler,LoggingSupporter,OptionHandler,QuickInfoSupporter,SizeOfHandler,CellFinder,RowCellFinder,Serializable
public class CellTypeRange extends AbstractRowCellFinder
Locator that locates cells of a certain type using a rectangular range.
-logging-level <OFF|SEVERE|WARNING|INFO|CONFIG|FINE|FINER|FINEST> (property: loggingLevel) The logging level for outputting errors and debugging output. default: WARNING
-type <MISSING|STRING|BOOLEAN|LONG|DOUBLE|DATE|DATETIME|TIME|OBJECT> (property: type) The cell type to locate. default: STRING
-rows <adams.core.Range> (property: rows) The rows to locate. default: first-last example: A range is a comma-separated list of single 1-based indices or sub-ranges of indices ('start-end'); 'inv(...)' inverts the range '...'; the following placeholders can be used as well: first, second, third, last_2, last_1, last-columns <adams.data.spreadsheet.SpreadSheetColumnRange> (property: columns) The columns to locate. default: first-last example: A range is a comma-separated list of single 1-based indices or sub-ranges of indices ('start-end'); 'inv(...)' inverts the range '...'; apart from column names (case-sensitive), the following placeholders can be used as well: first, second, third, last_2, last_1, last- Author:
- fracpete (fracpete at waikato dot ac dot nz)
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description protected SpreadSheetColumnRangem_Columnsthe columns.protected Rangem_Rowsthe rows.protected Cell.ContentTypem_Typethe type to look for.-
Fields inherited from class adams.core.option.AbstractOptionHandler
m_OptionManager
-
Fields inherited from class adams.core.logging.LoggingObject
m_Logger, m_LoggingIsEnabled, m_LoggingLevel
-
-
Constructor Summary
Constructors Constructor Description CellTypeRange()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description StringcolumnsTipText()Returns the tip text for this property.voiddefineOptions()Adds options to the internal list of options.protected Iterator<CellLocation>doFindCells(Row row)Performs the actual locating.protected Iterator<CellLocation>doFindCells(SpreadSheet sheet)Performs the actual locating.SpreadSheetColumnRangegetColumns()Returns the columns to locate.StringgetQuickInfo()Returns a quick info about the object, which can be displayed in the GUI.RangegetRows()Returns the rows to locate.Cell.ContentTypegetType()Returns the cell type to locate.StringglobalInfo()Returns a string describing the object.StringrowsTipText()Returns the tip text for this property.voidsetColumns(SpreadSheetColumnRange value)Sets the columns to locate.voidsetRows(Range value)Sets the rows to locate.voidsetType(Cell.ContentType value)Sets the cell type to locate.StringtypeTipText()Returns the tip text for this property.-
Methods inherited from class adams.data.spreadsheet.cellfinder.AbstractRowCellFinder
check, findCells
-
Methods inherited from class adams.data.spreadsheet.cellfinder.AbstractCellFinder
check, findCells, forCommandLine, forName, getCellFinders, shallowCopy, shallowCopy
-
Methods inherited from class adams.core.option.AbstractOptionHandler
cleanUpOptions, destroy, finishInit, getDefaultLoggingLevel, getOptionManager, initialize, loggingLevelTipText, newOptionManager, reset, setLoggingLevel, toCommandLine, toString
-
Methods inherited from class adams.core.logging.LoggingObject
configureLogger, getLogger, getLoggingLevel, initializeLogging, isLoggingEnabled, sizeOf
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface adams.data.spreadsheet.cellfinder.CellFinder
findCells
-
Methods inherited from interface adams.core.logging.LoggingLevelHandler
getLoggingLevel
-
-
-
-
Field Detail
-
m_Type
protected Cell.ContentType m_Type
the type to look for.
-
m_Rows
protected Range m_Rows
the rows.
-
m_Columns
protected SpreadSheetColumnRange m_Columns
the columns.
-
-
Method Detail
-
globalInfo
public String globalInfo()
Returns a string describing the object.- Specified by:
globalInfoin interfaceGlobalInfoSupporter- Specified by:
globalInfoin classAbstractOptionHandler- Returns:
- a description suitable for displaying in the gui
-
defineOptions
public void defineOptions()
Adds options to the internal list of options.- Specified by:
defineOptionsin interfaceOptionHandler- Overrides:
defineOptionsin classAbstractOptionHandler
-
setType
public void setType(Cell.ContentType value)
Sets the cell type to locate.- Parameters:
value- the type
-
getType
public Cell.ContentType getType()
Returns the cell type to locate.- Returns:
- the type
-
typeTipText
public String typeTipText()
Returns the tip text for this property.- Returns:
- tip text for this property suitable for displaying in the gui
-
setRows
public void setRows(Range value)
Sets the rows to locate.- Parameters:
value- the rows
-
getRows
public Range getRows()
Returns the rows to locate.- Returns:
- the rows
-
rowsTipText
public String rowsTipText()
Returns the tip text for this property.- Returns:
- tip text for this property suitable for displaying in the gui
-
setColumns
public void setColumns(SpreadSheetColumnRange value)
Sets the columns to locate.- Parameters:
value- the columns
-
getColumns
public SpreadSheetColumnRange getColumns()
Returns the columns to locate.- Returns:
- the columns
-
columnsTipText
public String columnsTipText()
Returns the tip text for this property.- Returns:
- tip text for this property suitable for displaying in the gui
-
getQuickInfo
public String getQuickInfo()
Returns a quick info about the object, which can be displayed in the GUI.- Specified by:
getQuickInfoin interfaceQuickInfoSupporter- Overrides:
getQuickInfoin classAbstractCellFinder- Returns:
- null if no info available, otherwise short string
-
doFindCells
protected Iterator<CellLocation> doFindCells(SpreadSheet sheet)
Performs the actual locating.- Specified by:
doFindCellsin classAbstractCellFinder- Parameters:
sheet- the sheet to locate the cells in- Returns:
- the iterator over the locations
-
doFindCells
protected Iterator<CellLocation> doFindCells(Row row)
Performs the actual locating.- Specified by:
doFindCellsin classAbstractRowCellFinder- Parameters:
row- the row to locate the cells in- Returns:
- the iterator over the locations
-
-