|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectnet.sourceforge.squirrel_sql.plugins.smarttools.SmarttoolsHelper
public class SmarttoolsHelper
| Field Summary | |
|---|---|
static String |
CR
|
| Method Summary | |
|---|---|
static int |
checkColumnData(Statement stmt,
String sql)
Check the columns data and returns found record number |
static int |
convertStringToIntDef(String string,
int defaultValue)
Get the parsed string as int or defaultValue if an exception occured |
static void |
fillOperatorTypes(JComboBox cbOperator,
int usedGroup)
Filled the given JComboBox with operator values |
static String |
getDataTypeForDisplay(TableColumnInfo tableColumnInfo)
Returns the readable data type for the given tableColumnInfo |
static List<STDataType> |
getListSmarttoolsDataType(boolean withGroupNull)
Get s list of jdbc datatypes and names in SmarttoolsDataTypes |
static int |
getRowCount(Statement stmt,
String tableName)
Returns the row count of the given table |
static boolean |
isDataTypeDate(int dataType)
Returns true if dataType is a valid date data type |
static boolean |
isDataTypeInt(int dataType)
Returns true if dataType is a valid int data type |
static boolean |
isDataTypeNumeric(int dataType)
Returns true if dataType is a valid numeric data type |
static boolean |
isDataTypeString(int dataType)
Returns true if dataType is a valid string data type |
static ImageIcon |
loadIcon(String imageIconName)
Load an icon image with iconName from the sub package images to package of class FirebirdManagerPlugin |
static void |
markAllRows(JTable tbl,
int col,
boolean mark)
Mark or demark all rows in column col of table tbl |
static void |
printTable(JTable table,
String headerText,
String footerText)
Print the content of the given table |
static void |
setColumnWidth(JTable table,
int[] colWidth)
Set the widths for the columns of table |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final String CR
| Method Detail |
|---|
public static ImageIcon loadIcon(String imageIconName)
imageIconName - filename of the icon image
public static int convertStringToIntDef(String string,
int defaultValue)
string - string to convertdefaultValue - default value which will be returned on an exception
public static void printTable(JTable table,
String headerText,
String footerText)
table - tables content to printheaderText - header text for output pagefooterText - footer text for output pagepublic static List<STDataType> getListSmarttoolsDataType(boolean withGroupNull)
public static void fillOperatorTypes(JComboBox cbOperator,
int usedGroup)
cbOperator - JComboBox to fillusedGroup - data type group (@see STDataType)public static boolean isDataTypeString(int dataType)
dataType - data type to check
public static boolean isDataTypeInt(int dataType)
dataType - data type to check
public static boolean isDataTypeNumeric(int dataType)
dataType - data type to check
public static boolean isDataTypeDate(int dataType)
dataType - data type to check
public static String getDataTypeForDisplay(TableColumnInfo tableColumnInfo)
tableColumnInfo - data to generate the readable data type info
public static int checkColumnData(Statement stmt,
String sql)
throws SQLException
stmt - Statement to execute querysql - SQL-Statement for executeQuery
SQLException - SQLException
public static void markAllRows(JTable tbl,
int col,
boolean mark)
tbl - JTablecol - column to mark or demarkmark - true=mark; false=demark
public static void setColumnWidth(JTable table,
int[] colWidth)
table - table to set the column widthcolWidth - array with the new column width
public static int getRowCount(Statement stmt,
String tableName)
throws SQLException
stmt - Statement for sqltableName - table to check
SQLException - SQLException
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||