public class ReplaceValueTable
extends uk.ac.starlink.table.WrapperStarTable
Constructor | Description |
---|---|
ReplaceValueTable(uk.ac.starlink.table.StarTable baseTable,
boolean[] colFlags,
java.lang.String oldStr,
java.lang.String newStr) |
Constructs a new ReplaceValueTable with the same replacement
taking place in zero or more of the base table's columns,
as described by an array of flags.
|
ReplaceValueTable(uk.ac.starlink.table.StarTable baseTable,
int[] icols,
java.lang.String[] oldStrs,
java.lang.String[] newStrs) |
Constructs a new ReplaceValueTable from parallel arrays describing
the columns to change and the old and new values.
|
Modifier and Type | Method | Description |
---|---|---|
java.lang.Object |
getCell(long irow,
int icol) |
|
uk.ac.starlink.table.ColumnInfo |
getColumnInfo(int icol) |
|
java.lang.Object[] |
getRow(long irow) |
|
uk.ac.starlink.table.RowSequence |
getRowSequence() |
public ReplaceValueTable(uk.ac.starlink.table.StarTable baseTable, boolean[] colFlags, java.lang.String oldStr, java.lang.String newStr) throws java.io.IOException
baseTable
- base tablecolFlags
- array of flags for each column of the table,
true only for those columns which should be modifiedoldStr
- value to be replacednewStr
- replacement valuejava.io.IOException
public ReplaceValueTable(uk.ac.starlink.table.StarTable baseTable, int[] icols, java.lang.String[] oldStrs, java.lang.String[] newStrs) throws java.io.IOException
icols
, oldStrs
and
newStrs
must have the same number of elements.
Indices in icols
ought not to be repeated.baseTable
- base tableicols
- array of column indices in which replacements
will occuroldStrs
- array of strings to be replaced,
one for each of the columns in icols
newStrs
- array of strings to furnish replacement values,
one for each of the columns in icols
java.io.IOException
public uk.ac.starlink.table.ColumnInfo getColumnInfo(int icol)
getColumnInfo
in class uk.ac.starlink.table.WrapperStarTable
public java.lang.Object getCell(long irow, int icol) throws java.io.IOException
getCell
in class uk.ac.starlink.table.WrapperStarTable
java.io.IOException
public java.lang.Object[] getRow(long irow) throws java.io.IOException
getRow
in class uk.ac.starlink.table.WrapperStarTable
java.io.IOException
public uk.ac.starlink.table.RowSequence getRowSequence() throws java.io.IOException
getRowSequence
in class uk.ac.starlink.table.WrapperStarTable
java.io.IOException
Copyright © 2018 Central Laboratory of the Research Councils. All Rights Reserved.