org.gcube.portlets.user.tdw.server.datasource.jdbc.dialect
Class MySQL_5_x_x_SQLDialect

java.lang.Object
  extended by org.gcube.portlets.user.tdw.server.datasource.jdbc.dialect.AbstractSQLDialect
      extended by org.gcube.portlets.user.tdw.server.datasource.jdbc.dialect.MySQL_5_x_x_SQLDialect
All Implemented Interfaces:
SQLDialect

public class MySQL_5_x_x_SQLDialect
extends AbstractSQLDialect

Author:
"Federico De Faveri defaveri@isti.cnr.it"

Field Summary
 
Fields inherited from class org.gcube.portlets.user.tdw.server.datasource.jdbc.dialect.AbstractSQLDialect
logger
 
Constructor Summary
MySQL_5_x_x_SQLDialect()
           
 
Method Summary
 String getDataQuery(String tableName, String sortingColumn, Direction sortingDirection)
          Returns a query for table data selection.
 String getName()
           
 String getTableSizeQuery(String tableName)
          Returns a query for table size retrieving.
 void setDataPreparedStatementParameters(PreparedStatement preparedStatement, String tableName, String sortingColumn, Direction sortingDirection, int start, int limit)
          
 boolean supportDataBase(String databaseProductName, int databaseMajorVersion, int databaseMinorVersion)
          Checks if the specified database system is compatible with this dialect.
 
Methods inherited from class org.gcube.portlets.user.tdw.server.datasource.jdbc.dialect.AbstractSQLDialect
createDataPreparedStatement
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

MySQL_5_x_x_SQLDialect

public MySQL_5_x_x_SQLDialect()
Method Detail

getName

public String getName()

supportDataBase

public boolean supportDataBase(String databaseProductName,
                               int databaseMajorVersion,
                               int databaseMinorVersion)
Checks if the specified database system is compatible with this dialect.

Returns:

getTableSizeQuery

public String getTableSizeQuery(String tableName)
Returns a query for table size retrieving.

Returns:

setDataPreparedStatementParameters

public void setDataPreparedStatementParameters(PreparedStatement preparedStatement,
                                               String tableName,
                                               String sortingColumn,
                                               Direction sortingDirection,
                                               int start,
                                               int limit)
                                        throws SQLException

Specified by:
setDataPreparedStatementParameters in interface SQLDialect
Overrides:
setDataPreparedStatementParameters in class AbstractSQLDialect
Throws:
SQLException

getDataQuery

public String getDataQuery(String tableName,
                           String sortingColumn,
                           Direction sortingDirection)
Returns a query for table data selection.

Specified by:
getDataQuery in class AbstractSQLDialect
sortingColumn - the sorting column, can be null.
sortingDirection - the sorting direction, can be null.
Returns:


Copyright © 2013. All Rights Reserved.