com.atlassian.confluence.upgrade
Class UpgradeUtils

java.lang.Object
  extended by com.atlassian.confluence.upgrade.UpgradeUtils

Deprecated. since 3.5.9 Use HibernateDdlExecutor and associated DdlCommands, or HibernateConfig if your code still needs to know which DB type its using.

@Deprecated
public class UpgradeUtils
extends Object


Constructor Summary
UpgradeUtils()
          Deprecated.  
 
Method Summary
static void createIndex(net.sf.hibernate.Session session, String indexName, String tableName, String columns, org.slf4j.Logger log)
          Deprecated.  
static void dropIndex(net.sf.hibernate.Session session, String indexName, String tableName, org.slf4j.Logger log)
          Deprecated.  
static void executeDdl(net.sf.hibernate.Session session, String sql, org.slf4j.Logger log)
          Deprecated.  
static boolean getExistingBooleanValue(String key)
          Deprecated.  
static int getExistingIntegerValue(String key)
          Deprecated.  
static String getExistingStringValue(String key)
          Deprecated.  
static net.sf.hibernate.Session getSession()
          Deprecated.  
static boolean isDB2()
          Deprecated.  
static boolean isHSQLDB()
          Deprecated.  
static boolean isMSSQL()
          Deprecated. since 3.5.8 because it is too close to isMySQL. Use isSqlServer() instead
static boolean isMySQL()
          Deprecated.  
static boolean isOracle()
          Deprecated.  
static boolean isSqlServer()
          Deprecated.  
static boolean isSybase()
          Deprecated.  
static String substituteBoolean(String sqlString)
          Deprecated. Returns the converted SQL string with booleans converted from True or false to 1 or 0 respectively based on the isSubstituteBoolean() method that looks for databases which require the boolean values as 1 or 0.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

UpgradeUtils

public UpgradeUtils()
Deprecated. 
Method Detail

createIndex

public static void createIndex(net.sf.hibernate.Session session,
                               String indexName,
                               String tableName,
                               String columns,
                               org.slf4j.Logger log)
                        throws net.sf.hibernate.HibernateException,
                               SQLException
Deprecated. 
Throws:
net.sf.hibernate.HibernateException
SQLException

executeDdl

public static void executeDdl(net.sf.hibernate.Session session,
                              String sql,
                              org.slf4j.Logger log)
                       throws net.sf.hibernate.HibernateException
Deprecated. 
Throws:
net.sf.hibernate.HibernateException

getSession

public static net.sf.hibernate.Session getSession()
Deprecated. 

dropIndex

public static void dropIndex(net.sf.hibernate.Session session,
                             String indexName,
                             String tableName,
                             org.slf4j.Logger log)
                      throws net.sf.hibernate.HibernateException
Deprecated. 
Throws:
net.sf.hibernate.HibernateException

isMySQL

public static boolean isMySQL()
Deprecated. 

isMSSQL

@Deprecated
public static boolean isMSSQL()
Deprecated. since 3.5.8 because it is too close to isMySQL. Use isSqlServer() instead


isSqlServer

public static boolean isSqlServer()
Deprecated. 

isSybase

public static boolean isSybase()
Deprecated. 

isOracle

public static boolean isOracle()
Deprecated. 

isDB2

public static boolean isDB2()
Deprecated. 

isHSQLDB

public static boolean isHSQLDB()
Deprecated. 

getExistingStringValue

public static String getExistingStringValue(String key)
Deprecated. 

getExistingBooleanValue

public static boolean getExistingBooleanValue(String key)
Deprecated. 

getExistingIntegerValue

public static int getExistingIntegerValue(String key)
Deprecated. 

substituteBoolean

public static String substituteBoolean(String sqlString)
Deprecated. 
Returns the converted SQL string with booleans converted from True or false to 1 or 0 respectively based on the isSubstituteBoolean() method that looks for databases which require the boolean values as 1 or 0.

If the database requires does not require boolean substitution, then the original sql string will be returned unmodified.

Parameters:
sqlString - the raw sql query string
Returns:
the converted sql string. (unmodified if the database supports true false boolean values).
See Also:
substituteBoolean(String)


Copyright © 2003-2013 Atlassian. All Rights Reserved.