Code example for TableGenerator

Methods: getIncrementSizegetSegmentValue

0
 
    public synchronized Serializable generate(final SessionImplementor session,
            Object obj) { 
 
        if (hiValue < 0 || value >= hiValue) {
            hiValue = sql.nextValue(getSegmentValue(), getIncrementSize());
            if (log.isDebugEnabled()) { 
                log.debug("Loaded new hiValue " + hiValue + " for "
                        + getSegmentValue());
            } 
            value = hiValue - getIncrementSize();
        } 
        value++;
        return value;
    } 
 
} 
Contextual code suggestions in your IDE  Get Codota for Java