很奇怪,
private FundBuy fb;
public FundBuy getFb() {
return fb;
} public void setFb(FundBuy fb) {
this.fb = fb;
}
然后
fb.setFundname(tobj.getFundName());tobj.getFundName()是有值的,能打印出来,FundBuy 这个实体里德属性也全部都get/set了,可是却不能把值设置到fb.setFundname,一直提示空指针以前我也都这么设置的,都能成功,可是这次却空指针,各位大侠帮帮忙啊,能造成这样的情况有哪些?我是在action中写的
private FundBuy fb;
public FundBuy getFb() {
return fb;
} public void setFb(FundBuy fb) {
this.fb = fb;
}
然后
fb.setFundname(tobj.getFundName());tobj.getFundName()是有值的,能打印出来,FundBuy 这个实体里德属性也全部都get/set了,可是却不能把值设置到fb.setFundname,一直提示空指针以前我也都这么设置的,都能成功,可是这次却空指针,各位大侠帮帮忙啊,能造成这样的情况有哪些?我是在action中写的
解决方案 »
免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货