Class StringTable
-
Field Summary
Fields inherited from class com.ibm.wala.util.tables.Table
columnHeadings, rows
-
Constructor Summary
ConstructorDescriptioncreate an empty tablecreate an empty table with the same column headings as tStringTable
(String[] columns) create an empty table with the given column headings -
Method Summary
Modifier and TypeMethodDescriptionclone()
static StringTable
readFromDirectTextFile
(String fileName, Character comment) read from a direct (native) text filestatic StringTable
readFromStream
(InputStream s, Character commentToken) static StringTable
readFromStream
(InputStream s, Character commentToken, @Nullable Character delimiter) static StringTable
readFromTextFile
(File f, Character comment) static String
readNextNonCommentLine
(LineNumberReader reader, Character commentToken) Methods inherited from class com.ibm.wala.util.tables.Table
addRow, computeColumnWidths, getColumnHeading, getElement, getNumberOfColumns, getNumberOfRows, padWithSpaces, removeRow, row2Map, toString
-
Constructor Details
-
StringTable
public StringTable()create an empty table -
StringTable
create an empty table with the same column headings as t -
StringTable
create an empty table with the given column headings
-
-
Method Details
-
readFromDirectTextFile
public static StringTable readFromDirectTextFile(String fileName, Character comment) throws FileNotFoundException, IOException read from a direct (native) text file- Throws:
IllegalArgumentException
- if fileName is nullFileNotFoundException
IOException
-
readFromTextFile
public static StringTable readFromTextFile(File f, Character comment) throws FileNotFoundException, IOException - Parameters:
f
- a file containing a table in text format, whitespace delimited- Throws:
FileNotFoundException
IOException
-
readFromStream
- Parameters:
s
- a stream containing a table in text format, whitespace delimited- Throws:
IllegalArgumentException
- if s is nullIOException
-
readFromStream
public static StringTable readFromStream(InputStream s, Character commentToken, @Nullable Character delimiter) throws IOException - Parameters:
s
- a stream containing a table in text format, whitespace delimited- Throws:
IllegalArgumentException
- if s is nullIOException
-
readNextNonCommentLine
public static String readNextNonCommentLine(LineNumberReader reader, Character commentToken) throws IOException - Throws:
IOException
-
clone
- Overrides:
clone
in classObject
- Throws:
CloneNotSupportedException
-