public abstract class AbstractFormatter extends Object implements RSFormatter
| Modifier and Type | Field and Description |
|---|---|
protected ConnectionInfo |
conInfo |
protected int |
maxrows |
CONSOLE_LINES, CONSOLE_WIDTH| Modifier | Constructor and Description |
|---|---|
protected |
AbstractFormatter() |
protected |
AbstractFormatter(ConnectionInfo ci) |
| Modifier and Type | Method and Description |
|---|---|
String |
format(ResultSet rs) |
String |
format(ResultSet rs,
int rows) |
int |
format(ResultSet rs,
Writer writer) |
int |
format(ResultSet rs,
Writer writer,
int rows,
String sql,
String tablename) |
String |
header(String sql,
ResultSet rs) |
void |
set(String k,
Object v) |
void |
setConnectionInfo(ConnectionInfo conInfo) |
void |
setMaxRows(int m)
Sets the max number of rows to be processed, if
|
String |
toString() |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitformat, headerprotected ConnectionInfo conInfo
protected int maxrows
protected AbstractFormatter(ConnectionInfo ci)
protected AbstractFormatter()
public String format(ResultSet rs) throws SQLException, IOException
format in interface RSFormatterSQLExceptionIOExceptionpublic String format(ResultSet rs, int rows) throws SQLException, IOException
format in interface RSFormatterSQLExceptionIOExceptionpublic int format(ResultSet rs, Writer writer, int rows, String sql, String tablename) throws SQLException, IOException
format in interface RSFormatterSQLExceptionIOExceptionpublic String header(String sql, ResultSet rs) throws SQLException
header in interface RSFormatterSQLExceptionpublic int format(ResultSet rs, Writer writer) throws SQLException, IOException
format in interface RSFormatterSQLExceptionIOExceptionpublic void setConnectionInfo(ConnectionInfo conInfo)
setConnectionInfo in interface RSFormatterpublic void setMaxRows(int m)
RSFormattersetMaxRows in interface RSFormatterpublic void set(String k, Object v)
set in interface RSFormatterCopyright © 2015. All rights reserved.