Hibernate ORM IdentifierGeneratorFactory - top ranked examples from Open Source projects

These code examples were ranked by Codota’s semantic indexing as the best open source examples for Hibernate ORM IdentifierGeneratorFactory class.

This code example shows how to use the following methods:createIdentifierGenerator, getDialect

5
CodeRank
Connect your IDE to all the code out there  Get Codota for Java
This code example shows how to use the following methods:createIdentifierGenerator, getDialect
		//} 
 
		//init the table here instead of earlier, so that we can get a quoted table name 
		//TODO: would it be better to simply pass the qualified table name, instead of 
		//      splitting it up into schema/catalog/table names 
		String tableName = getValue().getTable().getQualifiedName( identifierGeneratorFactory.getDialect() );
		params.setProperty( PersistentIdentifierGenerator.TABLE, tableName );
 
		//pass the column name (a generated id almost always has a single column) 
		if ( getSimpleValueSpan() > 1 ) { 
			throw new MappingException(
					"A SimpleAttributeBinding used for an identifier has more than 1 Value: " + getAttribute().getName() 
			); 
		} 
		SimpleValue simpleValue = (SimpleValue) getValue();
		if ( !Column.class.isInstance( simpleValue ) ) {
			throw new MappingException(
					"Cannot create an IdentifierGenerator because the value is not a column: " + 
							simpleValue.toLoggableString()
			); 

5
CodeRank
Connect your IDE to all the code out there  Get Codota for Java
See Code Examples for Hibernate ORM IdentifierGeneratorFactory Methods: