Example usage for org.hibernate.mapping IndexedCollection DEFAULT_INDEX_COLUMN_NAME

List of usage examples for org.hibernate.mapping IndexedCollection DEFAULT_INDEX_COLUMN_NAME

Introduction

In this page you can find the example usage for org.hibernate.mapping IndexedCollection DEFAULT_INDEX_COLUMN_NAME.

Prototype

String DEFAULT_INDEX_COLUMN_NAME

To view the source code for org.hibernate.mapping IndexedCollection DEFAULT_INDEX_COLUMN_NAME.

Click Source Link

Usage

From source file:org.codehaus.groovy.grails.orm.hibernate.cfg.AbstractGrailsDomainBinder.java

License:Apache License

protected String getIndexColumnName(GrailsDomainClassProperty property, String sessionFactoryBeanName) {
    PropertyConfig pc = getPropertyConfig(property);
    if (pc != null && pc.getIndexColumn() != null && pc.getIndexColumn().getColumn() != null) {
        return pc.getIndexColumn().getColumn();
    }//from  w  w  w  .j av  a2 s .com
    NamingStrategy namingStrategy = getNamingStrategy(sessionFactoryBeanName);
    return namingStrategy.propertyToColumnName(property.getName()) + UNDERSCORE
            + IndexedCollection.DEFAULT_INDEX_COLUMN_NAME;
}

From source file:org.codehaus.groovy.grails.orm.hibernate.cfg.GrailsDomainBinder.java

License:Apache License

private static String getIndexColumnName(GrailsDomainClassProperty property, String sessionFactoryBeanName) {
    PropertyConfig pc = getPropertyConfig(property);
    if (pc != null && pc.getIndexColumn() != null && pc.getIndexColumn().getColumn() != null) {
        return pc.getIndexColumn().getColumn();
    }/*from w  w  w  .  j av  a  2s .co m*/
    NamingStrategy namingStrategy = getNamingStrategy(sessionFactoryBeanName);
    return namingStrategy.propertyToColumnName(property.getName()) + UNDERSCORE
            + IndexedCollection.DEFAULT_INDEX_COLUMN_NAME;
}

From source file:org.grails.orm.hibernate.cfg.AbstractGrailsDomainBinder.java

License:Apache License

protected String getIndexColumnName(PersistentProperty property, String sessionFactoryBeanName) {
    PropertyConfig pc = getPropertyConfig(property);
    if (pc != null && pc.getIndexColumn() != null && pc.getIndexColumn().getColumn() != null) {
        return pc.getIndexColumn().getColumn();
    }//from w  ww  .  j  ava 2  s .co m
    NamingStrategy namingStrategy = getNamingStrategy(sessionFactoryBeanName);
    return namingStrategy.propertyToColumnName(property.getName()) + UNDERSCORE
            + IndexedCollection.DEFAULT_INDEX_COLUMN_NAME;
}