当前位置: 首页>>代码示例>>Java>>正文


Java DerbyDialect类代码示例

本文整理汇总了Java中org.hibernate.dialect.DerbyDialect的典型用法代码示例。如果您正苦于以下问题:Java DerbyDialect类的具体用法?Java DerbyDialect怎么用?Java DerbyDialect使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。


DerbyDialect类属于org.hibernate.dialect包,在下文中一共展示了DerbyDialect类的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: onShutdown

import org.hibernate.dialect.DerbyDialect; //导入依赖的package包/类
@Override
protected void onShutdown(ApplicationEvent event)
{
    // Shut down DB, if required
    Class<?> dialectClazz = this.dialect.getClass();
    if (dialectClazz.equals(DerbyDialect.class))
    {
        try
        {
            DriverManager.getConnection("jdbc:derby:;shutdown=true");
        }
        // Derby shutdown always triggers an exception, even when clean
        catch (Throwable e) 
        {
        }
    }
}
 
开发者ID:Alfresco,项目名称:alfresco-repository,代码行数:18,代码来源:SchemaBootstrap.java

示例2: determineDatabaseDialectClass

import org.hibernate.dialect.DerbyDialect; //导入依赖的package包/类
/**
 * Determine the Hibernate database dialect class for the given target database.
 * @param database the target database
 * @return the Hibernate database dialect class, or {@code null} if none found
 */
@SuppressWarnings("deprecation")
protected Class<?> determineDatabaseDialectClass(Database database) {
	switch (database) {
		case DB2: return DB2Dialect.class;
		case DERBY: return DerbyDialect.class;  // DerbyDialect deprecated in 4.x
		case H2: return H2Dialect.class;
		case HSQL: return HSQLDialect.class;
		case INFORMIX: return InformixDialect.class;
		case MYSQL: return MySQLDialect.class;
		case ORACLE: return Oracle9iDialect.class;
		case POSTGRESQL: return PostgreSQLDialect.class;  // PostgreSQLDialect deprecated in 4.x
		case SQL_SERVER: return SQLServerDialect.class;
		case SYBASE: return org.hibernate.dialect.SybaseDialect.class;  // SybaseDialect deprecated in 3.6 but not 4.x
		default: return null;
	}
}
 
开发者ID:lamsfoundation,项目名称:lams,代码行数:22,代码来源:HibernateJpaVendorAdapter.java

示例3: determineDatabaseDialectClass

import org.hibernate.dialect.DerbyDialect; //导入依赖的package包/类
/**
 * Determine the Hibernate database dialect class for the given target database.
 * @param database the target database
 * @return the Hibernate database dialect class, or {@code null} if none found
 */
protected Class determineDatabaseDialectClass(Database database) {
	switch (database) {
		case DB2: return DB2Dialect.class;
		case DERBY: return DerbyDialect.class;
		case H2: return H2Dialect.class;
		case HSQL: return HSQLDialect.class;
		case INFORMIX: return InformixDialect.class;
		case MYSQL: return MySQLDialect.class;
		case ORACLE: return Oracle9iDialect.class;
		case POSTGRESQL: return PostgreSQLDialect.class;
		case SQL_SERVER: return SQLServerDialect.class;
		case SYBASE: return SybaseDialect.class;
		default: return null;
	}
}
 
开发者ID:deathspeeder,项目名称:class-guard,代码行数:21,代码来源:HibernateJpaVendorAdapter.java

示例4: allowsPhysicalColumnNameInHaving

import org.hibernate.dialect.DerbyDialect; //导入依赖的package包/类
/**
 * Does the db/dialect support using a column's physical name in the having clause
 * even after it has been aliased in the select/group-by clause.  This is not actually
 * required by the SQL spec, although virtually ever DB in the world supports this.
 *
 * @param testDescription description of the scenario being tested.
 * @return true if is allowed
 */
protected boolean allowsPhysicalColumnNameInHaving(String testDescription) {
	// I only *know* of this being a limitation on Derby, although I highly suspect
	// it is a limitation on any IBM/DB2 variant
	if ( DerbyDialect.class.isInstance( getDialect() ) ) {
		// https://issues.apache.org/jira/browse/DERBY-1624
		reportSkip( "Dialect does not support physical column name in having clause after it is aliased", testDescription );
		return false;
	}
	return true;
}
 
开发者ID:cacheonix,项目名称:cacheonix-core,代码行数:19,代码来源:FunctionalTestCase.java

示例5: createHibernateDialect

import org.hibernate.dialect.DerbyDialect; //导入依赖的package包/类
@Override
protected Dialect createHibernateDialect() {
  return new DerbyDialect();
}
 
开发者ID:DevStreet,项目名称:FinanceAnalytics,代码行数:5,代码来源:DerbyDbDialect.java


注:本文中的org.hibernate.dialect.DerbyDialect类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。