请帮我调试一下(很小的) public background(){ 这里少}号public void setBackgroundColor(String backgroundColor){ 解决方案 » 免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货 各位这么自信,有没有这样去试一下呀:javac background.java提示:illegal start of expressionpublic void setBackgroundColor(String backgroundColor){^an error hehe ,真惭愧,我没有仔细看你的代码,你怎么方法套方法啊?这样可以了。但是不知道你要干吗?只是一个bean吗?通过:public class background{ private String backgroundColor=""; private String textColor=""; private int size=1; public background(){} public void setBackgroundColor(String backgroundColor){ this.backgroundColor=backgroundColor; } public String getBackgroundColor(){ return this.backgroundColor; } public void setTextColor(String textColor){ this.textColor=textColor; } public String getTextColor(){ return this.textColor; } public void setSizse(int size){ this.size=size; } public int getSize(){ return this.size; } } jsp+servelet编码问题请教 prepareStatement事务处理的方法 ssh整合问题 商企通 字符串的语法错误 在查询表达 的奇怪问题 ajax与用的浏览器、ie版本有关吗 菜鸟提问,请各位高手指教,急!!! 如何获得表单中名字相同的text控件的值,在线等.... 高分求救:如何解决有多个web server的session问题 急问JavaBean apache 用mod_jk 连接tomcat, 怎样发布servlet? 在win2k 或 Unix 上。 哪里有《JSP从入门到精通》 电子工业出版社出版 书中源代码下载??
javac background.java
提示:
illegal start of expression
public void setBackgroundColor(String backgroundColor){
^
an error
这样可以了。但是不知道你要干吗?只是一个bean吗?
通过:public class background{
private String backgroundColor="";
private String textColor="";
private int size=1;
public background(){}
public void setBackgroundColor(String backgroundColor){
this.backgroundColor=backgroundColor;
}
public String getBackgroundColor(){
return this.backgroundColor;
}
public void setTextColor(String textColor){
this.textColor=textColor;
}
public String getTextColor(){
return this.textColor;
}
public void setSizse(int size){
this.size=size;
}
public int getSize(){
return this.size;
}
}