本文整理汇总了Java中org.hibernate.EntityMode.MAP属性的典型用法代码示例。如果您正苦于以下问题:Java EntityMode.MAP属性的具体用法?Java EntityMode.MAP怎么用?Java EntityMode.MAP使用的例子?那么, 这里精选的属性代码示例或许可以为您提供帮助。您也可以进一步了解该属性所在类org.hibernate.EntityMode
的用法示例。
在下文中一共展示了EntityMode.MAP属性的6个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: ComponentMetamodel
public ComponentMetamodel(Component component) {
// this.sessionFactory = sessionFactory;
this.role = component.getRoleName();
this.isKey = component.isKey();
propertySpan = component.getPropertySpan();
properties = new StandardProperty[propertySpan];
Iterator itr = component.getPropertyIterator();
int i = 0;
while ( itr.hasNext() ) {
Property property = ( Property ) itr.next();
properties[i] = PropertyFactory.buildStandardProperty( property, false );
propertyIndexes.put( property.getName(), i );
i++;
}
entityMode = component.hasPojoRepresentation() ? EntityMode.POJO : EntityMode.MAP;
// todo : move this to SF per HHH-3517; also see HHH-1907 and ComponentMetamodel
final ComponentTuplizerFactory componentTuplizerFactory = new ComponentTuplizerFactory();
final String tuplizerClassName = component.getTuplizerImplClassName( entityMode );
this.componentTuplizer = tuplizerClassName == null ? componentTuplizerFactory.constructDefaultTuplizer(
entityMode,
component
) : componentTuplizerFactory.constructTuplizer( tuplizerClassName, component );
}
示例2: getExplicitTuplizerClassName
@Override
public String getExplicitTuplizerClassName() {
if ( componentElement.getTuplizer() == null ) {
return null;
}
final EntityMode entityMode = StringHelper.isEmpty( componentElement.getClazz() ) ? EntityMode.MAP : EntityMode.POJO;
for ( JaxbTuplizerElement tuplizerElement : componentElement.getTuplizer() ) {
if ( entityMode == EntityMode.parse( tuplizerElement.getEntityMode() ) ) {
return tuplizerElement.getClazz();
}
}
return null;
}
示例3: getExplicitTuplizerClassName
@Override
public String getExplicitTuplizerClassName() {
if ( compositeElement.getTuplizer() == null ) {
return null;
}
final EntityMode entityMode = StringHelper.isEmpty( compositeElement.getClazz() ) ? EntityMode.MAP : EntityMode.POJO;
for ( JaxbTuplizerElement tuplizerElement : compositeElement.getTuplizer() ) {
if ( entityMode == EntityMode.parse( tuplizerElement.getEntityMode() ) ) {
return tuplizerElement.getClazz();
}
}
return null;
}
示例4: determineEntityMode
protected EntityMode determineEntityMode() {
return StringHelper.isNotEmpty( getClassName() ) ? EntityMode.POJO : EntityMode.MAP;
}
示例5: getEntityMode
@Override
public EntityMode getEntityMode() {
return EntityMode.MAP;
}
示例6: getEntityMode
public EntityMode getEntityMode() {
return EntityMode.MAP;
}