public class JaxbMarshaller {
@Test
public void student2xml() throws JAXBException{
JAXBContext context=JAXBContext.newInstance(Student.class);
Student student=new Student("admin", 18, "��������", new ClassRoom("classroom", "�������"));
Marshaller marshaller = context.createMarshaller();
//�O�ò�ݔ��<?xml version="1.0" encoding="UTF-8" standalone="yes"?>��Ϣ
//marshaller.setProperty(Marshaller.JAXB_FRAGMENT, true);
marshaller.marshal(student, System.out);
}