@ Override public void registerPersisterSpace ( String entityName , Tree aliasTree ) { String aliasText = aliasTree . getText ( ) ; String previous = aliasToEntityType . put ( aliasText , entityName ) ; if ( previous != null && ! previous . equalsIgnoreCase ( entityName ) ) { throw new UnsupportedOperationException ( "Alias reuse currently not supported: alias " + aliasText + " already assigned to type " + previous ) ; } if ( targetTypeName != null ) { throw new IllegalStateException ( "Can't target multiple types: " + targetTypeName + " already selected before " + entityName ) ; } targetTypeName = entityName ; targetEntityMetadata = propertyHelper . getEntityMetadata ( targetTypeName ) ; if ( targetEntityMetadata == null ) { throw log . getUnknownEntity ( targetTypeName ) ; } fieldIndexingMetadata = propertyHelper . getIndexedFieldProvider ( ) . get ( targetEntityMetadata ) ; whereBuilder . setEntityType ( targetEntityMetadata ) ; havingBuilder . setEntityType ( targetEntityMetadata ) ; }
See rule entityName