setterinjectionbean.java
来自「本工程是spring中IOC/AOP的编程」· Java 代码 · 共 35 行
JAVA
35 行
package com.injection.bean;
public class SetterInjectionBean {
private AnotherBean anotherBean;
private YetAnotherBean yetAnotherBean;
private int i;
public AnotherBean getAnotherBean() {
return anotherBean;
}
public void setAnotherBean(AnotherBean anotherBean) {
this.anotherBean = anotherBean;
}
public int getI() {
return i;
}
public void setI(int i) {
this.i = i;
}
public YetAnotherBean getYetAnotherBean() {
return yetAnotherBean;
}
public void setYetAnotherBean(YetAnotherBean yetAnotherBean) {
this.yetAnotherBean = yetAnotherBean;
}
public void display() {
System.out.println( "SetterInjectionBean:" );
System.out.println( this.anotherBean );
System.out.println( this.yetAnotherBean );
System.out.println( i );
}
}
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?