congrats Icon
New! Announcing Tabnine Chat Beta
Learn More
Tabnine Logo
IndexOrUniqueKeySecondPass.addConstraintToColumns
Code IndexAdd Tabnine to your IDE (free)

How to use
addConstraintToColumns
method
in
org.hibernate.cfg.IndexOrUniqueKeySecondPass

Best Java code snippets using org.hibernate.cfg.IndexOrUniqueKeySecondPass.addConstraintToColumns (Showing top 2 results out of 315)

origin: hibernate/hibernate-orm

addConstraintToColumns( columns );
origin: org.hibernate.orm/hibernate-core

@Override
public void doSecondPass(Map persistentClasses) throws MappingException {
  if ( columns != null ) {
    for ( int i = 0; i < columns.length; i++ ) {
      addConstraintToColumn( columns[i] );
    }
  }
  if ( column != null ) {
    this.table = column.getTable();
    final PropertyHolder propertyHolder = column.getPropertyHolder();
    String entityName = ( propertyHolder.isComponent() ) ?
        propertyHolder.getPersistentClass().getEntityName() :
        propertyHolder.getEntityName();
    final PersistentClass persistentClass = (PersistentClass) persistentClasses.get( entityName );
    final Property property = persistentClass.getProperty( column.getPropertyName() );
    if ( property.getValue() instanceof Component ) {
      final Component component = (Component) property.getValue();
      final List<Column> columns = component.getMappedColumns().stream()
          .filter( Column.class::isInstance )
          .map(Column.class::cast )
          .collect( Collectors.toList() );
      addConstraintToColumns( columns );
    }
    else {
      addConstraintToColumn(
           column.getMappingColumn().getQuotedName() )
      ;
    }
  }
}
org.hibernate.cfgIndexOrUniqueKeySecondPassaddConstraintToColumns

Popular methods of IndexOrUniqueKeySecondPass

  • <init>
    Build an index
  • addConstraintToColumn
  • doSecondPass

Popular in Java

  • Updating database using SQL prepared statement
  • scheduleAtFixedRate (Timer)
  • setScale (BigDecimal)
  • getContentResolver (Context)
  • ByteBuffer (java.nio)
    A buffer for bytes. A byte buffer can be created in either one of the following ways: * #allocate
  • Selector (java.nio.channels)
    A controller for the selection of SelectableChannel objects. Selectable channels can be registered w
  • Time (java.sql)
    Java representation of an SQL TIME value. Provides utilities to format and parse the time's represen
  • Queue (java.util)
    A collection designed for holding elements prior to processing. Besides basic java.util.Collection o
  • ServletException (javax.servlet)
    Defines a general exception a servlet can throw when it encounters difficulty.
  • JOptionPane (javax.swing)
  • Best IntelliJ plugins
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now