类 TypeDefinitionBean
- java.lang.Object
- org.springframework.orm.hibernate3.TypeDefinitionBean
- 所有已实现的接口:
Aware
,BeanNameAware
,InitializingBean
@Deprecated public class TypeDefinitionBean extends Object implements BeanNameAware, InitializingBean
已过时。as of Spring 4.3, in favor of Hibernate 4.x/5.xBean that encapsulates a Hibernate type definition.Typically defined as inner bean within a LocalSessionFactoryBean definition, as list element for the "typeDefinitions" bean property. For example:
<bean id="sessionFactory" class="org.springframework.orm.hibernate3.LocalSessionFactoryBean"> ... <property name="typeDefinitions"> <list> <bean class="org.springframework.orm.hibernate3.TypeDefinitionBean"> <property name="typeName" value="myType"/> <property name="typeClass" value="mypackage.MyTypeClass"/> </bean> </list> </property> ... </bean>
Alternatively, specify a bean id (or name) attribute for the inner bean, instead of the "typeName" property.- 从以下版本开始:
- 1.2
- 作者:
- Juergen Hoeller
- 另请参阅:
LocalSessionFactoryBean.setTypeDefinitions(TypeDefinitionBean[])
构造器概要
构造器 构造器 说明 TypeDefinitionBean()
已过时。
方法概要
所有方法 实例方法 具体方法 已过时的方法 修饰符和类型 方法 说明 void
afterPropertiesSet()
已过时。Invoked by the containingBeanFactory
after it has set all bean properties and satisfiedBeanFactoryAware
,ApplicationContextAware
etc.Properties
getParameters()
已过时。Return the default parameters for the type.String
getTypeClass()
已过时。Return the type implementation class.String
getTypeName()
已过时。Return the name of the type.void
setBeanName(String name)
已过时。If no explicit type name has been specified, the bean name of the TypeDefinitionBean will be used.void
setParameters(Properties parameters)
已过时。Specify default parameters for the type.void
setTypeClass(String typeClass)
已过时。Set the type implementation class.void
setTypeName(String typeName)
已过时。Set the name of the type.
构造器详细资料
TypeDefinitionBean
public TypeDefinitionBean()
已过时。
方法详细资料
setTypeName
public void setTypeName(String typeName)
已过时。Set the name of the type.
getTypeName
public String getTypeName()
已过时。Return the name of the type.
setTypeClass
public void setTypeClass(String typeClass)
已过时。Set the type implementation class.
getTypeClass
public String getTypeClass()
已过时。Return the type implementation class.
setParameters
public void setParameters(Properties parameters)
已过时。Specify default parameters for the type. This only applies to parameterized types.
getParameters
public Properties getParameters()
已过时。Return the default parameters for the type.
setBeanName
public void setBeanName(String name)
已过时。If no explicit type name has been specified, the bean name of the TypeDefinitionBean will be used.- 指定者:
setBeanName
在接口中BeanNameAware
- 参数:
name
- the name of the bean in the factory. Note that this name is the actual bean name used in the factory, which may differ from the originally specified name: in particular for inner bean names, the actual bean name might have been made unique through appending "#..." suffixes. Use theBeanFactoryUtils.originalBeanName(String)
method to extract the original bean name (without suffix), if desired.- 另请参阅:
setTypeName(java.lang.String)
afterPropertiesSet
public void afterPropertiesSet()
已过时。从接口复制的说明:InitializingBean
Invoked by the containingBeanFactory
after it has set all bean properties and satisfiedBeanFactoryAware
,ApplicationContextAware
etc.This method allows the bean instance to perform validation of its overall configuration and final initialization when all bean properties have been set.
- 指定者:
afterPropertiesSet
在接口中InitializingBean