ChinaUnix.net
相关文章推荐:

jgraph教程

Java Graph Visualization and Layout jgraph is a member of the fastest growing breed of software products: professional open source software. jgraph is able to combine the best of each open source software and traditional software development to form a uniquely powerful offering. jgraph : The free Swing-style component with source code, 140k in size, feature-rich, fully documented and commerc...

by linxh - Java文档中心 - 2008-06-10 23:09:22 阅读(1373) 回复(0)

相关讨论

从最简单的jgraph程序我们可以发现创建jgraph程序的框架。 1. 首先创建GraphModel, GraphModel model = new DefaultGraphModel(); 2.创建GraphLayoutCache, GraphLayoutCache cache = new GraphLayoutCache(model, new DefaultCellViewFactory()); 3.创建jgraph jgraph g = new jgraph(model, cache); 4.创建图上的元素,包括节点,边,port,以及分组等。 DefaultGraphCell[] cells = new Default...

by minixer - Java文档中心 - 2007-03-13 14:52:54 阅读(784) 回复(0)

现在来看一看addSampleData(model)。 public static void addSampleData(GraphModel model) { ConnectionSet cs = new ConnectionSet(); Map attributes = new Hashtable(); // Styles For Implement/Extend/Aggregation //设置implementStyle AttributeMap implementStyle = new AttributeMap(); GraphConstants.setLineBegin(implementStyle, GraphConstants.ARROW_TECHNICAL...

by minixer - Java文档中心 - 2007-03-13 14:52:05 阅读(853) 回复(0)

首先来看jgraph的默认构造函数。 public jgraph() { this((GraphModel) null); } 可以看到,默认构造函数仅仅传递null值,调用了另一个构造函数,让我们来看看这个构造函数。 public jgraph(GraphModel model) { this(model, (GraphLayoutCache) null); } 可以看到,这个构造函数也只是调用了另一个构造函数,我们接着往下走。 public jgraph(GraphModel model, GraphLayoutCache cache) { this(model, cach...

by minixer - Java文档中心 - 2007-03-13 14:51:07 阅读(801) 回复(0)

最简单的jgraph程序分析。 import javax.swing.*; import org.jgraph.*; public class Example1 { /** * @param args */ public static void main(String[] args) { // TODO Auto-generated method stub JFrame frame = new JFrame("Example1"); jgraph graph = new jgraph(); frame.getContentPane().add(new JScrollPane(graph)); frame.se...

by minixer - Java文档中心 - 2007-03-13 14:49:32 阅读(927) 回复(0)

在Unix下,使用带有jgraph的程序,在X环境下运行,可以正常使用,在远端浏览界面的时候可以看到调用jgraph生成map图,但是在用telnet形式的终端登录到Unix模式启动带有jgraph的应用,在远端访问的时候就无法看到调用JGrap生成的map图。有哪位高手知道如何解决谢谢

by oakingtk - Java - 2009-05-27 09:39:40 阅读(1889) 回复(1)

使用jgraph实现GraphCell的拷贝,剪切和粘贴功能时,发现了一个问题。我用DefaultGraphCell的user object来保存自定义信息,当进行Cell的拷贝粘贴后,发现当修改修改前或修改后的Cell时,另一个也随着变化。不过修改Cell的图像等显示信息时,两者是不会一起变化的。推断是两者指向了同一个UserObject。 如何在拷贝的时候将User Object也拷贝一份呢?首先实现了UserObject的clone方法,后发现无效。又在DefaultGraphCell中发现了cl...

by yolaiyoqu - Java文档中心 - 2007-06-21 16:33:07 阅读(1004) 回复(0)

我们这有个用到jgraph的一个应用,是在HP-UX上的Apach服务器调用的一个web应用,生成图形的的一个应用,当我们以 Xwindows登录启动应用的时候,在浏览页面时可以看到生成的图形,而当我们用telnet方式登录并启动应用后,在浏览页面时无法看到图形,并且后台报错为 StandardWrapperValve[showImage]: Servlet.service() for servlet showImage threw e xception AxisFault faultCode: {http://schemas.xmlsoap.org/soap/envelope/}S...

by oakingtk - Java - 2009-06-03 13:00:01 阅读(1654) 回复(4)