[求助]把这段java程序转换为xml文件
import java.lang.*;
class Person {
String name = "noname"; //姓名
int age = 0; //年龄
char sex = 'M'; //性别
public void sport(String item) {
System.out.println(name + "参加了" + item + "运动");
} // sport方法结束
} // 类Person结束
// 声明"学生"类
class Student extends Person {
int degree; //分数
int grade; //年级
Student(String name, int age, char sex, int grade, int degree) {
this.name = name;
this.age = age;
this.sex = sex;
this.grade = grade;
this.degree = degree;
} // 构造方法结束
public void learn(String knowledge) {
System.out.println(name + "学习了" + knowledge + "知识");
} // learn()方法结束
} // 类Student结束
[此贴子已经被作者于2006-10-30 8:38:36编辑过]