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


Java MySQL5Dialect类代码示例

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


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

示例1: hibernateDatabaseDialectClass

import org.hibernate.dialect.MySQL5Dialect; //导入依赖的package包/类
private static Class<?> hibernateDatabaseDialectClass(DatabasePlatform database) {
	switch (database) {
	case DB2:
		return DB2Dialect.class;
	case DB2_AS400:
		return DB2400Dialect.class;
	case DERBY:
		return DerbyTenSevenDialect.class;
	case H2:
		return H2Dialect.class;
	case HSQL:
		return HSQLDialect.class;
	case INFORMIX:
		return InformixDialect.class;
	case MYSQL:
		return MySQL5Dialect.class;
	case ORACLE:
		return Oracle10gDialect.class;
	case POSTGRESQL:
		return PostgreSQL82Dialect.class;
	case SQL_SERVER:
		return SQLServerDialect.class;
	case MARIADB:
		return MySQL5Dialect.class;
	case HANA:
		return HANARowStoreDialect.class;
	case SQLITE:
	case NONE:
	default:
		break;
	}
	return null;
}
 
开发者ID:holon-platform,项目名称:holon-datastore-jpa,代码行数:34,代码来源:EntityManagerFactoryConfigurator.java

示例2: main

import org.hibernate.dialect.MySQL5Dialect; //导入依赖的package包/类
public static void main(String[] args) {
        Configuration hello =new Configuration();

        Properties properties = new Properties();
        properties.setProperty(Environment.DIALECT, MySQL5Dialect.class.getName());
        hello.setProperties(properties);
        hello.addAnnotatedClass(Hello.class);
        hello.addAnnotatedClass(Hello1.class);
        SchemaExport schemaExport = new SchemaExport(hello);
        schemaExport.setDelimiter(";");
//        schemaExport.setOutputFile(String.format("%s_%s.%s ", new Object[] {"ddl", dialect.name().toLowerCase(), "sql" }));
         boolean consolePrint = true;
         boolean exportInDatabase = false;
//         schemaExport.create(consolePrint, exportInDatabase);
        schemaExport.create(Target.SCRIPT);

    }
 
开发者ID:PkayJava,项目名称:pluggable,代码行数:18,代码来源:Hello.java

示例3: jpaProperties

import org.hibernate.dialect.MySQL5Dialect; //导入依赖的package包/类
@Bean
public Map<String, Object> jpaProperties() {
	Map<String, Object> props = new HashMap<String, Object>();
	props.put("hibernate.dialect", MySQL5Dialect.class.getName());
	props.put("hibernate.hbm2ddl.auto", "update");
	props.put("hibernate.show_sql", "true");
	props.put("hibernate.format_sql", "true");
	props.put("hibernate.connection.charSet", "UTF-8");
	return props;
}
 
开发者ID:baichenhong,项目名称:spring-project-template,代码行数:11,代码来源:AppConfig.java

示例4: addDialects

import org.hibernate.dialect.MySQL5Dialect; //导入依赖的package包/类
private void addDialects(StrategySelectorImpl strategySelector) {
	addDialect( strategySelector, Cache71Dialect.class );
	addDialect( strategySelector, CUBRIDDialect.class );
	addDialect( strategySelector, DB2Dialect.class );
	addDialect( strategySelector, DB2390Dialect.class );
	addDialect( strategySelector, DB2400Dialect.class );
	addDialect( strategySelector, DerbyTenFiveDialect.class );
	addDialect( strategySelector, DerbyTenSixDialect.class );
	addDialect( strategySelector, DerbyTenSevenDialect.class );
	addDialect( strategySelector, FirebirdDialect.class );
	addDialect( strategySelector, FrontBaseDialect.class );
	addDialect( strategySelector, H2Dialect.class );
	addDialect( strategySelector, HSQLDialect.class );
	addDialect( strategySelector, InformixDialect.class );
	addDialect( strategySelector, IngresDialect.class );
	addDialect( strategySelector, Ingres9Dialect.class );
	addDialect( strategySelector, Ingres10Dialect.class );
	addDialect( strategySelector, InterbaseDialect.class );
	addDialect( strategySelector, JDataStoreDialect.class );
	addDialect( strategySelector, MckoiDialect.class );
	addDialect( strategySelector, MimerSQLDialect.class );
	addDialect( strategySelector, MySQL5Dialect.class );
	addDialect( strategySelector, MySQL5InnoDBDialect.class );
	addDialect( strategySelector, MySQL5Dialect.class );
	addDialect( strategySelector, MySQL5InnoDBDialect.class );
	addDialect( strategySelector, Oracle8iDialect.class );
	addDialect( strategySelector, Oracle9iDialect.class );
	addDialect( strategySelector, Oracle10gDialect.class );
	addDialect( strategySelector, PointbaseDialect.class );
	addDialect( strategySelector, PostgresPlusDialect.class );
	addDialect( strategySelector, PostgreSQL81Dialect.class );
	addDialect( strategySelector, PostgreSQL82Dialect.class );
	addDialect( strategySelector, PostgreSQL9Dialect.class );
	addDialect( strategySelector, ProgressDialect.class );
	addDialect( strategySelector, SAPDBDialect.class );
	addDialect( strategySelector, SQLServerDialect.class );
	addDialect( strategySelector, SQLServer2005Dialect.class );
	addDialect( strategySelector, SQLServer2008Dialect.class );
	addDialect( strategySelector, Sybase11Dialect.class );
	addDialect( strategySelector, SybaseAnywhereDialect.class );
	addDialect( strategySelector, SybaseASE15Dialect.class );
	addDialect( strategySelector, SybaseASE157Dialect.class );
	addDialect( strategySelector, TeradataDialect.class );
	addDialect( strategySelector, TimesTenDialect.class );
}
 
开发者ID:lamsfoundation,项目名称:lams,代码行数:46,代码来源:StrategySelectorBuilder.java

示例5: getHibernateDialect

import org.hibernate.dialect.MySQL5Dialect; //导入依赖的package包/类
protected String getHibernateDialect() {
    return MySQL5Dialect.class.getName();
}
 
开发者ID:pivotalservices,项目名称:concourse-spring-music,代码行数:4,代码来源:MySqlRepositoryConfig.java

示例6: setUp

import org.hibernate.dialect.MySQL5Dialect; //导入依赖的package包/类
@Before
public void setUp() throws Exception {
	entityManagerFactory = Persistence.createEntityManagerFactory("increment");
	conventions = DDLConventions.create(entityManagerFactory, new MySQL5Dialect());
}
 
开发者ID:andreluiznsilva,项目名称:hibernate-conventions,代码行数:6,代码来源:DDLConventionsForMySQLDialectIT.java


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