我想尝试显示关系图。
我有xml
<School>
<Class>
<Name>1st Grade</Name>
<StudentName>A</StudentName>
<StudentName>B</StudentName>
<StudentName>C</StudentName>
<StudentName>D</StudentName>
</Class>
<Class>
<Name>2nd Grade</Name>
<StudentName>E</StudentName>
<StudentName>F</StudentName>
<StudentName>G</StudentName>
<StudentName>H</StudentName>
<Class>
<TeacherDetails>
<Teacher>
<Name>AAAA</Name>
<Teaches>1st Grade</Teaches>
<Teacher>
<Teacher>
<Name>BBBB</Name>
<Teaches>1st Grade</Teaches>
<Teaches>2nd Grade</Teaches>
</Teacher>
</TeacherDetails>
<School>
任何帮助!!
答案 0 :(得分:0)
Mark Shepherd的SpringGraph是绘制图形的一个很好的实用工具。您必须在XML表示和图表中的节点之间编写图层,但这很容易。
您可以为节点重载itemRenderer,并在相应的鼠标事件上显示自定义图像和悬停提示。