public boolean isInsertable() { // if the property mapping consists of all formulas, // make it non-insertable final boolean[] columnInsertability = value.getColumnInsertability(); return insertable && ( columnInsertability.length==0 || !ArrayHelper.isAllFalse( columnInsertability ) ); }
@Override public boolean[] getColumnInsertability() { boolean[] result = new boolean[ getColumnSpan() ]; Iterator iter = getPropertyIterator(); int i=0; while ( iter.hasNext() ) { Property prop = (Property) iter.next(); boolean[] chunk = prop.getValue().getColumnInsertability(); if ( prop.isInsertable() ) { System.arraycopy(chunk, 0, result, i, chunk.length); } i+=chunk.length; } return result; }
private void checkColumnDuplication(java.util.Set distinctColumns, Value value) throws MappingException { final boolean[] insertability = value.getColumnInsertability(); final boolean[] updatability = value.getColumnUpdateability(); final Iterator<Selectable> iterator = value.getColumnIterator(); int i = 0; while ( iterator.hasNext() ) { Selectable s = iterator.next(); // exclude formulas and coluns that are not insertable or updatable // since these values can be be repeated (HHH-5393) if ( !s.isFormula() && ( insertability[i] || updatability[i] ) ) { Column col = (Column) s; if ( !distinctColumns.add( col.getName() ) ) { throw new MappingException( "Repeated column in mapping for collection: " + getRole() + " column: " + col.getName() ); } } i++; } }
propertyColumnInsertable[i] = prop.getValue().getColumnInsertability();
indexType = indexedCollection.getIndex().getType(); int indexSpan = indexedCollection.getIndex().getColumnSpan(); boolean[] indexColumnInsertability = indexedCollection.getIndex().getColumnInsertability(); boolean[] indexColumnUpdatability = indexedCollection.getIndex().getColumnUpdateability(); iter = indexedCollection.getIndex().getColumnIterator();
public boolean isInsertable() { // if the property mapping consists of all formulas, // make it insertable final boolean[] columnInsertability = value.getColumnInsertability(); return insertable && ( columnInsertability.length==0 || !ArrayHelper.isAllFalse(columnInsertability) ); }
public boolean isInsertable() { // if the property mapping consists of all formulas, // make it insertable final boolean[] columnInsertability = value.getColumnInsertability(); return insertable && ( columnInsertability.length==0 || !ArrayHelper.isAllFalse(columnInsertability) ); }
public boolean isInsertable() { // if the property mapping consists of all formulas, // make it non-insertable final boolean[] columnInsertability = value.getColumnInsertability(); return insertable && ( columnInsertability.length==0 || !ArrayHelper.isAllFalse( columnInsertability ) ); }
public boolean isInsertable() { // if the property mapping consists of all formulas, // make it non-insertable final boolean[] columnInsertability = value.getColumnInsertability(); return insertable && ( columnInsertability.length==0 || !ArrayHelper.isAllFalse( columnInsertability ) ); }
@Override public boolean isInsertable() { // if the property mapping consists of all formulas, // make it non-insertable final boolean[] columnInsertability = value.getColumnInsertability(); return insertable && ( columnInsertability.length==0 || !ArrayHelper.isAllFalse( columnInsertability ) ); }
public boolean[] getColumnInsertability() { boolean[] result = new boolean[ getColumnSpan() ]; Iterator iter = getPropertyIterator(); int i=0; while ( iter.hasNext() ) { Property prop = (Property) iter.next(); boolean[] chunk = prop.getValue().getColumnInsertability(); if ( prop.isInsertable() ) { System.arraycopy(chunk, 0, result, i, chunk.length); } i+=chunk.length; } return result; }
public boolean[] getColumnInsertability() { boolean[] result = new boolean[ getColumnSpan() ]; Iterator iter = getPropertyIterator(); int i=0; while ( iter.hasNext() ) { Property prop = (Property) iter.next(); boolean[] chunk = prop.getValue().getColumnInsertability(); if ( prop.isInsertable() ) { System.arraycopy(chunk, 0, result, i, chunk.length); } i+=chunk.length; } return result; }
public boolean[] getColumnInsertability() { boolean[] result = new boolean[ getColumnSpan() ]; Iterator iter = getPropertyIterator(); int i=0; while ( iter.hasNext() ) { Property prop = (Property) iter.next(); boolean[] chunk = prop.getValue().getColumnInsertability(); if ( prop.isInsertable() ) { System.arraycopy(chunk, 0, result, i, chunk.length); } i+=chunk.length; } return result; }
@Override public boolean[] getColumnInsertability() { boolean[] result = new boolean[getColumnSpan()]; final List<PersistentAttributeMapping> declaredPersistentAttributes = getDeclaredPersistentAttributes(); for ( int i = 0; i < declaredPersistentAttributes.size(); i++ ) { final PersistentAttributeMapping prop = declaredPersistentAttributes.get( i ); boolean[] chunk = ( (Property) prop ).getValue().getColumnInsertability(); if ( prop.isInsertable() ) { System.arraycopy( chunk, 0, result, i, chunk.length ); } i += chunk.length; } return result; }
public boolean[] getColumnInsertability() { boolean[] result = new boolean[ getColumnSpan() ]; Iterator iter = getPropertyIterator(); int i=0; while ( iter.hasNext() ) { Property prop = (Property) iter.next(); boolean[] chunk = prop.getValue().getColumnInsertability(); if ( prop.isInsertable() ) { System.arraycopy(chunk, 0, result, i, chunk.length); } i+=chunk.length; } return result; }
private void checkColumnDuplication(java.util.Set distinctColumns, Value value) throws MappingException { final boolean[] insertability = value.getColumnInsertability(); final boolean[] updatability = value.getColumnUpdateability(); List<MappedColumn> mappedColumns = value.getMappedColumns(); for ( int i = 0; i < mappedColumns.size(); i++ ) { MappedColumn s = mappedColumns.get( i ); // exclude formulas and coluns that are not insertable or updatable // since these values can be be repeated (HHH-5393) if ( !s.isFormula() && ( insertability[i] || updatability[i] ) ) { Column col = (Column) s; if ( !distinctColumns.add( col.getName() ) ) { throw new MappingException( "Repeated column in mapping for collection: " + getRole() + " column: " + col.getName() ); } } } }
propertyColumnInsertable[i] = prop.getValue().getColumnInsertability();
propertyColumnInsertable[i] = prop.getValue().getColumnInsertability();
propertyColumnInsertable[i] = prop.getValue().getColumnInsertability();
propertyColumnInsertable[i] = prop.getValue().getColumnInsertability();