本文整理汇总了Java中org.hibernate.mapping.Property.isBasicPropertyAccessor方法的典型用法代码示例。如果您正苦于以下问题:Java Property.isBasicPropertyAccessor方法的具体用法?Java Property.isBasicPropertyAccessor怎么用?Java Property.isBasicPropertyAccessor使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类org.hibernate.mapping.Property
的用法示例。
在下文中一共展示了Property.isBasicPropertyAccessor方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: AbstractComponentTuplizer
import org.hibernate.mapping.Property; //导入方法依赖的package包/类
protected AbstractComponentTuplizer(Component component) {
propertySpan = component.getPropertySpan();
getters = new Getter[propertySpan];
setters = new Setter[propertySpan];
Iterator iter = component.getPropertyIterator();
boolean foundCustomAccessor=false;
int i = 0;
while ( iter.hasNext() ) {
Property prop = ( Property ) iter.next();
getters[i] = buildGetter( component, prop );
setters[i] = buildSetter( component, prop );
if ( !prop.isBasicPropertyAccessor() ) {
foundCustomAccessor = true;
}
i++;
}
hasCustomAccessors = foundCustomAccessor;
instantiator = buildInstantiator( component );
}
示例2: AbstractComponentTuplizer
import org.hibernate.mapping.Property; //导入方法依赖的package包/类
protected AbstractComponentTuplizer(Component component) {
propertySpan = component.getPropertySpan();
getters = new Getter[propertySpan];
setters = new Setter[propertySpan];
Iterator iter = component.getPropertyIterator();
boolean foundCustomAccessor=false;
int i = 0;
while ( iter.hasNext() ) {
Property prop = ( Property ) iter.next();
getters[i] = buildGetter( component, prop );
setters[i] = buildSetter( component, prop );
if ( !prop.isBasicPropertyAccessor() ) {
foundCustomAccessor = true;
}
i++;
}
hasCustomAccessors = foundCustomAccessor;
String[] getterNames = new String[propertySpan];
String[] setterNames = new String[propertySpan];
Class[] propTypes = new Class[propertySpan];
for ( int j = 0; j < propertySpan; j++ ) {
getterNames[j] = getters[j].getMethodName();
setterNames[j] = setters[j].getMethodName();
propTypes[j] = getters[j].getReturnType();
}
instantiator = buildInstantiator( component );
}
示例3: AbstractEntityTuplizer
import org.hibernate.mapping.Property; //导入方法依赖的package包/类
/**
* Constructs a new AbstractEntityTuplizer instance.
*
* @param entityMetamodel The "interpreted" information relating to the mapped entity.
* @param mappingInfo The parsed "raw" mapping data relating to the given entity.
*/
public AbstractEntityTuplizer(EntityMetamodel entityMetamodel, PersistentClass mappingInfo) {
this.entityMetamodel = entityMetamodel;
if ( !entityMetamodel.getIdentifierProperty().isVirtual() ) {
idGetter = buildPropertyGetter( mappingInfo.getIdentifierProperty(), mappingInfo );
idSetter = buildPropertySetter( mappingInfo.getIdentifierProperty(), mappingInfo );
}
else {
idGetter = null;
idSetter = null;
}
propertySpan = entityMetamodel.getPropertySpan();
getters = new Getter[propertySpan];
setters = new Setter[propertySpan];
Iterator iter = mappingInfo.getPropertyClosureIterator();
boolean foundCustomAccessor=false;
int i=0;
while ( iter.hasNext() ) {
//TODO: redesign how PropertyAccessors are acquired...
Property property = (Property) iter.next();
getters[i] = buildPropertyGetter(property, mappingInfo);
setters[i] = buildPropertySetter(property, mappingInfo);
if ( !property.isBasicPropertyAccessor() ) foundCustomAccessor = true;
i++;
}
hasCustomAccessors = foundCustomAccessor;
instantiator = buildInstantiator( mappingInfo );
if ( entityMetamodel.isLazy() ) {
proxyFactory = buildProxyFactory( mappingInfo, idGetter, idSetter );
if (proxyFactory == null) {
entityMetamodel.setLazy( false );
}
}
else {
proxyFactory = null;
}
Component mapper = mappingInfo.getIdentifierMapper();
identifierMapperType = mapper==null ? null : (AbstractComponentType) mapper.getType();
}