本文整理了Java中org.springframework.beans.factory.support.AbstractBeanDefinition.setInitMethodNam
本文整理了Java中org.springframework.beans.factory.support.AbstractBeanDefinition.setInitMethodName()
方法的一些代码示例,展示了AbstractBeanDefinition.setInitMethodName()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。AbstractBeanDefinition.setInitMethodName()
方法的具体详情如下:
包路径:org.springframework.beans.factory.support.AbstractBeanDefinition
类名称:AbstractBeanDefinition
方法名:setInitMethodName
AbstractBeanDefinition.setInitMethodName介绍
[英]Set the name of the initializer method. The default is null
in which case there is no initializer method.
[中]设置初始值设定项方法的名称。默认值为null
,在这种情况下,没有初始值设定方法。
代码示例
代码示例来源:origin: spring-projects/spring-framework
/**
* Set the init method for this definition.
*/
public BeanDefinitionBuilder setInitMethodName(@Nullable String methodName) {
this.beanDefinition.setInitMethodName(methodName);
return this;
}
代码示例来源:origin: org.springframework/spring-beans
/**
* Set the init method for this definition.
*/
public BeanDefinitionBuilder setInitMethodName(@Nullable String methodName) {
this.beanDefinition.setInitMethodName(methodName);
return this;
}
代码示例来源:origin: spring-projects/spring-framework
bd.setInitMethodName(initMethodName);
bd.setInitMethodName(this.defaults.getInitMethod());
bd.setEnforceInitMethod(false);
代码示例来源:origin: spring-projects/spring-framework
bd.setInitMethodName(newValue.toString());
代码示例来源:origin: jenkinsci/jenkins
bd.setInitMethodName(newValue.toString());
代码示例来源:origin: org.springframework/spring-beans
bd.setInitMethodName(newValue.toString());
代码示例来源:origin: org.springframework/spring-beans
bd.setInitMethodName(initMethodName);
bd.setInitMethodName(this.defaults.getInitMethod());
bd.setEnforceInitMethod(false);
代码示例来源:origin: spring-projects/spring-framework
/**
* Apply the provided default values to this bean.
* @param defaults the defaults to apply
*/
public void applyDefaults(BeanDefinitionDefaults defaults) {
setLazyInit(defaults.isLazyInit());
setAutowireMode(defaults.getAutowireMode());
setDependencyCheck(defaults.getDependencyCheck());
setInitMethodName(defaults.getInitMethodName());
setEnforceInitMethod(false);
setDestroyMethodName(defaults.getDestroyMethodName());
setEnforceDestroyMethod(false);
}
代码示例来源:origin: camunda/camunda-bpm-platform
/**
* Set the init method for this definition.
*/
public BeanDefinitionBuilder setInitMethodName(String methodName) {
this.beanDefinition.setInitMethodName(methodName);
return this;
}
代码示例来源:origin: org.springframework/spring-beans
/**
* Apply the provided default values to this bean.
* @param defaults the defaults to apply
*/
public void applyDefaults(BeanDefinitionDefaults defaults) {
setLazyInit(defaults.isLazyInit());
setAutowireMode(defaults.getAutowireMode());
setDependencyCheck(defaults.getDependencyCheck());
setInitMethodName(defaults.getInitMethodName());
setEnforceInitMethod(false);
setDestroyMethodName(defaults.getDestroyMethodName());
setEnforceDestroyMethod(false);
}
代码示例来源:origin: spring-projects/spring-framework
setLenientConstructorResolution(otherAbd.isLenientConstructorResolution());
if (otherAbd.getInitMethodName() != null) {
setInitMethodName(otherAbd.getInitMethodName());
setEnforceInitMethod(otherAbd.isEnforceInitMethod());
代码示例来源:origin: org.springframework/spring-beans
setLenientConstructorResolution(otherAbd.isLenientConstructorResolution());
if (otherAbd.getInitMethodName() != null) {
setInitMethodName(otherAbd.getInitMethodName());
setEnforceInitMethod(otherAbd.isEnforceInitMethod());
代码示例来源:origin: spring-projects/spring-framework
setNonPublicAccessAllowed(originalAbd.isNonPublicAccessAllowed());
setLenientConstructorResolution(originalAbd.isLenientConstructorResolution());
setInitMethodName(originalAbd.getInitMethodName());
setEnforceInitMethod(originalAbd.isEnforceInitMethod());
setDestroyMethodName(originalAbd.getDestroyMethodName());
代码示例来源:origin: spring-projects/spring-framework
private void setBaseProperties(AbstractBeanDefinition definition) {
definition.setAbstract(true);
definition.setAttribute("foo", "bar");
definition.setAutowireCandidate(false);
definition.setAutowireMode(AbstractBeanDefinition.AUTOWIRE_BY_TYPE);
// definition.getConstructorArgumentValues().addGenericArgumentValue("foo");
definition.setDependencyCheck(AbstractBeanDefinition.DEPENDENCY_CHECK_OBJECTS);
definition.setDependsOn(new String[] { "foo", "bar" });
definition.setDestroyMethodName("destroy");
definition.setEnforceDestroyMethod(false);
definition.setEnforceInitMethod(true);
definition.setFactoryBeanName("factoryBean");
definition.setFactoryMethodName("factoryMethod");
definition.setInitMethodName("init");
definition.setLazyInit(true);
definition.getMethodOverrides().addOverride(new LookupOverride("foo", "bar"));
definition.getMethodOverrides().addOverride(new ReplaceOverride("foo", "bar"));
definition.getPropertyValues().add("foo", "bar");
definition.setResourceDescription("desc");
definition.setRole(BeanDefinition.ROLE_APPLICATION);
definition.setScope(BeanDefinition.SCOPE_PROTOTYPE);
definition.setSource("foo");
}
代码示例来源:origin: org.springframework/spring-beans
setNonPublicAccessAllowed(originalAbd.isNonPublicAccessAllowed());
setLenientConstructorResolution(originalAbd.isLenientConstructorResolution());
setInitMethodName(originalAbd.getInitMethodName());
setEnforceInitMethod(originalAbd.isEnforceInitMethod());
setDestroyMethodName(originalAbd.getDestroyMethodName());
代码示例来源:origin: camunda/camunda-bpm-platform
String initMethodName = ele.getAttribute(INIT_METHOD_ATTRIBUTE);
if (!"".equals(initMethodName)) {
bd.setInitMethodName(initMethodName);
bd.setInitMethodName(this.defaults.getInitMethod());
bd.setEnforceInitMethod(false);
代码示例来源:origin: camunda/camunda-bpm-platform
/**
* Apply the provided default values to this bean.
* @param defaults the defaults to apply
*/
public void applyDefaults(BeanDefinitionDefaults defaults) {
setLazyInit(defaults.isLazyInit());
setAutowireMode(defaults.getAutowireMode());
setDependencyCheck(defaults.getDependencyCheck());
setInitMethodName(defaults.getInitMethodName());
setEnforceInitMethod(false);
setDestroyMethodName(defaults.getDestroyMethodName());
setEnforceDestroyMethod(false);
}
代码示例来源:origin: org.mule.modules/mule-module-cxf
@Override
protected AbstractBeanDefinition parseInternal(Element element, ParserContext parserContext)
{
// We don't want spring managing lifecycle anymore, but since this module
// is going to be rewritten, it doesn't make sense to spend time in removing this
// init method
AbstractBeanDefinition beanDefinition = super.parseInternal(element, parserContext);
beanDefinition.setInitMethodName(Initialisable.PHASE_NAME);
return beanDefinition;
}
};
代码示例来源:origin: camunda/camunda-bpm-platform
setLenientConstructorResolution(otherAbd.isLenientConstructorResolution());
if (StringUtils.hasLength(otherAbd.getInitMethodName())) {
setInitMethodName(otherAbd.getInitMethodName());
setEnforceInitMethod(otherAbd.isEnforceInitMethod());
代码示例来源:origin: camunda/camunda-bpm-platform
setNonPublicAccessAllowed(originalAbd.isNonPublicAccessAllowed());
setLenientConstructorResolution(originalAbd.isLenientConstructorResolution());
setInitMethodName(originalAbd.getInitMethodName());
setEnforceInitMethod(originalAbd.isEnforceInitMethod());
setDestroyMethodName(originalAbd.getDestroyMethodName());