JGraphAddons
v1.0


org.jgraph.util
Class JGraphGXLCodec

java.lang.Object
  |
  +--org.jgraph.util.JGraphGXLCodec

public class JGraphGXLCodec
extends Object


Constructor Summary
JGraphGXLCodec()
           
 
Method Summary
static Map createDefaultAttributes(AttributeMap map)
          Returns an attributeMap for the specified position and color.
static void decode(InputStream inputStream, JGraph graph)
           
protected static void decodeCell(Node gnode, Map gnode_attrs)
          Extracts visual properties of the node from the child 'view' element Currently recognized properties: - font, attrs: name, size, style(plain, bold, italic) - color - background-color - autosize
protected static void decodeEdge(Node enode, Map enode_attrs)
           
static String encode(JGraph graph, Object[] cells)
           
static String encodeEdge(JGraph graph, Object id, Object edge)
           
static String encodeVertex(JGraph graph, Object id, Object vertex)
           
protected static String getLabel(Node node)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

JGraphGXLCodec

public JGraphGXLCodec()
Method Detail

encode

public static String encode(JGraph graph,
                            Object[] cells)

encodeVertex

public static String encodeVertex(JGraph graph,
                                  Object id,
                                  Object vertex)

encodeEdge

public static String encodeEdge(JGraph graph,
                                Object id,
                                Object edge)

decodeCell

protected static void decodeCell(Node gnode,
                                 Map gnode_attrs)
Extracts visual properties of the node from the child 'view' element Currently recognized properties: - font, attrs: name, size, style(plain, bold, italic) - color - background-color - autosize


decodeEdge

protected static void decodeEdge(Node enode,
                                 Map enode_attrs)

decode

public static void decode(InputStream inputStream,
                          JGraph graph)
                   throws Exception
Exception

createDefaultAttributes

public static Map createDefaultAttributes(AttributeMap map)
Returns an attributeMap for the specified position and color.


getLabel

protected static String getLabel(Node node)

JGraphAddons
v1.0


Copyright (C) 2003-2004 Gaudenz Alder. All rights reserved.