In UniForM we need ways of displaying typed directed graphs. In the original UniForM, it was only possible to use the DaVinci encapsulation for displaying directed graphs. While this is very good, in the new UniForM it is intended to factor out this encapsulation so that it will not be too difficult to replace DaVinci by other graph-drawing package (or variants of DaVinci) for particular graphs. Example alternatives that might be considered: (1) some sort of text-only interface. (2) Windows-style displaying of a tree structure using clickable folders. In this module we present the classes that any such "graph-drawing package" is supposed to implement.
This module is in two parts.
The first part contains the "user-friendly" versions of the functions. For these, it is assumed (as will usually be the case) that there is only one node/nodeType/arc/arcType around for a particular graph. The whole lot is indexed by the GraphAll, which contains ALL the functionality required for accessing the graphs (apart from configuration options). For example, the only daVinci-specific thing you should need to use to write a program which calls daVinci will be the daVinciSort variable.
The second part contains the "user-hateful" versions. All the user-hateful functions have names ending in "Prim". Graph display implementations only have to implement the user-hateful versions. The user-hateful versions should only be of interest to other people if the graph display provides more than one implementation of the NodeClass, NodeTypeClass (or whatever) implementation. One disadvantage to the user of using the user-hateful versions of the functions is that because of all the overloading, you have to put in lots of explicit types, or else get the most hideous type errors.
Configuring things like graph titles, shape of node boxes, menus, and so on should also be implemented, where possible, by graph display interfaces. The various options are documented in GraphConfigure.hs. They should be applied using the Computation.HasConfig interface.
The types which are supposed in various combinations to be instances of the classes are as follows:
graph. This corresponds to one graph display. graphConfig. This is configuration information for a graph. This might be a window title or size for example. graphParms. This is a collection of graphConfig's used to construct a graph.
Nodes and arcs carry values. Thus all the following carry
a type parameter. But, for ease of implementation with, for example,
DaVinci, the type parameter is required to be an instance of Typeable
.
- node. A value of this type is an actual node in a graph.
(Will be an instance of
Typeable
viaTypeable1
.) - nodeType. Nodes are created with a particular UniForM "type" which is a Haskell value of type nodetype. In fact a graph might conceivably have multiply Haskell types corresponding to node and nodeType, meaning that nodes, or their UniForM types, will be distinguished additionally by the Haskell type system.
- nodeTypeConfig. Configuration information for a nodeType. This might include how a node with this type is to be displayed graphically. This also includes information on what to do when the node is clicked.
- nodeTypeParms. A collection of nodeTypeConfig's used to construct a nodeType
Similar constructions for arcs . . . arc. arcType. arcTypeConfig. arcTypeParms.
There are quite a lot of classes. This is partly because of the need to have a separate class for each subset of the type variables which is actually used in the type of a function.
This file is fairly repetitive, mainly because of the need to repeat the configuration machinery over and over again.
The functionality provided in this file is inspired by that provided by DaVinci. However we extend it by allowing nodes to have labels.
This file should be read in conjunction with GraphConfigure, which contains various configuration options to be used for graph objects.
Additional Notes ----------------
- At the end of a program using a GraphDisp instance,
shutdown
should be called. For example, in the case of the DaVinci instance this is required to get rid of the DaVinci and HTk processes. - It is more cumbersome writing the Graph Editor than I would like because the menu code doesn't give you direct access to the node or arc type. Unfortunately doing this would make the classes in this file even more complicated than they are now.
- newtype GraphAll graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms => Graph graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms = Graph graph
- newGraph :: GraphAll graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms => Graph graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms -> graphParms -> IO (Graph graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms)
- redraw :: GraphAll graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms => Graph graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms -> IO ()
- getMultipleNodes :: GraphAll graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms => Graph graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms -> (Event (WrappedNode node) -> IO a) -> IO a
- class GraphParms graphParms where
- emptyGraphParms :: graphParms
- newNode :: (GraphAll graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms, Typeable value) => Graph graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms -> nodeType value -> value -> IO (node value)
- setNodeType :: (GraphAll graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms, Typeable value) => Graph graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms -> node value -> nodeType value -> IO ()
- deleteNode :: (GraphAll graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms, Typeable value) => Graph graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms -> node value -> IO ()
- setNodeFocus :: (GraphAll graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms, Typeable value) => Graph graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms -> node value -> IO ()
- getNodeValue :: (GraphAll graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms, Typeable value) => Graph graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms -> node value -> IO value
- setNodeValue :: (GraphAll graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms, Typeable value) => Graph graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms -> node value -> value -> IO ()
- newNodeType :: (GraphAll graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms, Typeable value) => Graph graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms -> nodeTypeParms value -> IO (nodeType value)
- class NodeTypeParms nodeTypeParms where
- emptyNodeTypeParms :: Typeable value => nodeTypeParms value
- coMapNodeTypeParms :: (Typeable value1, Typeable value2) => (value2 -> value1) -> nodeTypeParms value1 -> nodeTypeParms value2
- newArc :: (GraphAll graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms, Typeable value, Typeable nodeFromValue, Typeable nodeToValue) => Graph graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms -> arcType value -> value -> node nodeFromValue -> node nodeToValue -> IO (arc value)
- data WrappedNode node = forall value . Typeable value => WrappedNode (node value)
- newArcListDrawer :: (GraphAll graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms, Typeable value, Typeable nodeFromValue) => Graph graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms -> node nodeFromValue -> ListDrawer (arcType value, value, WrappedNode node) (arc value)
- deleteArc :: (GraphAll graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms, Typeable value) => Graph graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms -> arc value -> IO ()
- setArcValue :: (GraphAll graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms, Typeable value) => Graph graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms -> arc value -> value -> IO ()
- setArcType :: (GraphAll graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms, Typeable value) => Graph graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms -> arc value -> arcType value -> IO ()
- getArcValue :: (GraphAll graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms, Typeable value) => Graph graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms -> arc value -> IO value
- newArcType :: (GraphAll graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms, Typeable value) => Graph graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms -> arcTypeParms value -> IO (arcType value)
- class ArcTypeParms arcTypeParms where
- emptyArcTypeParms :: Typeable value => arcTypeParms value
- invisibleArcTypeParms :: Typeable value => arcTypeParms value
- coMapArcTypeParms :: (Typeable value1, Typeable value2) => (value2 -> value1) -> arcTypeParms value1 -> arcTypeParms value2
- class Eq1 takesParm where
- class Eq1 takesParm => Ord1 takesParm where
- class (GraphClass graph, NewGraph graph graphParms, GraphParms graphParms, NewNode graph node nodeType, DeleteNode graph node, SetNodeFocus graph node, NodeClass node, Typeable1 node, NodeTypeClass nodeType, NewNodeType graph nodeType nodeTypeParms, NodeTypeParms nodeTypeParms, NewArc graph node node arc arcType, SetArcType graph arc arcType, DeleteArc graph arc, ArcClass arc, Typeable1 arc, ArcTypeClass arcType, NewArcType graph arcType arcTypeParms) => GraphAll graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms where
- displaySort :: Graph graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms
- class (Destructible graph, Ord graph, Typeable graph, HasDelayer graph) => GraphClass graph where
- redrawPrim :: graph -> IO ()
- class (GraphClass graph, GraphParms graphParms) => NewGraph graph graphParms where
- newGraphPrim :: graphParms -> IO graph
- class GraphConfig graphConfig
- class (GraphClass graph, NodeClass node, NodeTypeClass nodeType) => NewNode graph node nodeType where
- newNodePrim :: Typeable value => graph -> nodeType value -> value -> IO (node value)
- setNodeTypePrim :: Typeable value => graph -> node value -> nodeType value -> IO ()
- class (GraphClass graph, NodeClass node) => DeleteNode graph node where
- deleteNodePrim :: Typeable value => graph -> node value -> IO ()
- getNodeValuePrim :: Typeable value => graph -> node value -> IO value
- setNodeValuePrim :: Typeable value => graph -> node value -> value -> IO ()
- getMultipleNodesPrim :: graph -> (Event (WrappedNode node) -> IO a) -> IO a
- class (GraphClass graph, NodeClass node) => SetNodeFocus graph node where
- setNodeFocusPrim :: Typeable value => graph -> node value -> IO ()
- class (Typeable1 node, Ord1 node) => NodeClass node
- class Typeable1 nodeType => NodeTypeClass nodeType
- class (GraphClass graph, NodeTypeClass nodeType, NodeTypeParms nodeTypeParms) => NewNodeType graph nodeType nodeTypeParms where
- newNodeTypePrim :: Typeable value => graph -> nodeTypeParms value -> IO (nodeType value)
- class Kind1 nodeTypeConfig => NodeTypeConfig nodeTypeConfig
- class (GraphClass graph, NodeClass nodeFrom, NodeClass nodeTo, ArcClass arc, ArcTypeClass arcType) => NewArc graph nodeFrom nodeTo arc arcType where
- newArcPrim :: (Typeable value, Typeable nodeFromValue, Typeable nodeToValue) => graph -> arcType value -> value -> nodeFrom nodeFromValue -> nodeTo nodeToValue -> IO (arc value)
- newArcListDrawerPrim :: (Typeable value, Typeable nodeFromValue) => graph -> nodeFrom nodeFromValue -> ListDrawer (arcType value, value, WrappedNode nodeTo) (arc value)
- class (ArcClass arc, ArcTypeClass arcType) => SetArcType graph arc arcType where
- setArcTypePrim :: Typeable value => graph -> arc value -> arcType value -> IO ()
- class (GraphClass graph, ArcClass arc) => DeleteArc graph arc where
- deleteArcPrim :: Typeable value => graph -> arc value -> IO ()
- setArcValuePrim :: Typeable value => graph -> arc value -> value -> IO ()
- getArcValuePrim :: Typeable value => graph -> arc value -> IO value
- class (Typeable1 arc, Ord1 arc) => ArcClass arc
- class (Typeable1 arcType, Ord1 arcType) => ArcTypeClass arcType where
- invisibleArcType :: Typeable value => arcType value
- class (GraphClass graph, ArcTypeClass arcType, ArcTypeParms arcTypeParms) => NewArcType graph arcType arcTypeParms where
- newArcTypePrim :: Typeable value => graph -> arcTypeParms value -> IO (arcType value)
- class Kind1 arcTypeConfig => ArcTypeConfig arcTypeConfig
User-Friendly Interface.
You should not need any more than this for drawing graphs.
newtype GraphAll graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms => Graph graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms Source
The graph implementation will provide a value of this type to
get you started. For example, for daVinci this is called daVinciSort
.
However you then need to use it as an argument to newGraph
to construct
the actual graph.
Graph graph |
Eq graph => Eq (Graph graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms) | |
Ord graph => Ord (Graph graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms) | |
GraphAll graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms => Destroyable (Graph graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms) | |
GraphAll graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms => Destructible (Graph graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms) | |
GraphAll graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms => HasDelayer (Graph graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms) |
newGraph :: GraphAll graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms => Graph graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms -> graphParms -> IO (Graph graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms)Source
Construct a new graph. The input value will be something like
DaVinciGraph's value daVinciSort
; the resulting graph will be
returned.
redraw :: GraphAll graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms => Graph graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms -> IO ()Source
Redraw the graph. This is needed when you want to show updates.
getMultipleNodes :: GraphAll graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms => Graph graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms -> (Event (WrappedNode node) -> IO a) -> IO aSource
Take over all interaction on the graph, and perform the given action, supplying it with an event which is activated when the user double-clicks a node. This is helpful when you need an interaction selecting several nodes.
class GraphParms graphParms whereSource
emptyGraphParms :: graphParmsSource
GraphParms EmptyGraphParms |
newNode :: (GraphAll graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms, Typeable value) => Graph graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms -> nodeType value -> value -> IO (node value)Source
construct a new node.
setNodeType :: (GraphAll graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms, Typeable value) => Graph graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms -> node value -> nodeType value -> IO ()Source
set a node's type
deleteNode :: (GraphAll graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms, Typeable value) => Graph graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms -> node value -> IO ()Source
delete a node
setNodeFocus :: (GraphAll graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms, Typeable value) => Graph graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms -> node value -> IO ()Source
getNodeValue :: (GraphAll graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms, Typeable value) => Graph graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms -> node value -> IO valueSource
get the value associated with a node
setNodeValue :: (GraphAll graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms, Typeable value) => Graph graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms -> node value -> value -> IO ()Source
set the value associated with a node.
newNodeType :: (GraphAll graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms, Typeable value) => Graph graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms -> nodeTypeParms value -> IO (nodeType value)Source
construct a node type.
class NodeTypeParms nodeTypeParms whereSource
emptyNodeTypeParms :: Typeable value => nodeTypeParms valueSource
coMapNodeTypeParms :: (Typeable value1, Typeable value2) => (value2 -> value1) -> nodeTypeParms value1 -> nodeTypeParms value2Source
NodeTypeParms EmptyNodeTypeParms |
newArc :: (GraphAll graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms, Typeable value, Typeable nodeFromValue, Typeable nodeToValue) => Graph graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms -> arcType value -> value -> node nodeFromValue -> node nodeToValue -> IO (arc value)Source
construct a new arc.
data WrappedNode node Source
forall value . Typeable value => WrappedNode (node value) |
newArcListDrawer :: (GraphAll graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms, Typeable value, Typeable nodeFromValue) => Graph graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms -> node nodeFromValue -> ListDrawer (arcType value, value, WrappedNode node) (arc value)Source
Given a node, construct a ListDrawer
which can be used as a way
of drawing ordered sets of out-arcs from that node.
(NB. At the moment daVinci does not do this properly, but that is
daVinci's fault, not mine.)
deleteArc :: (GraphAll graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms, Typeable value) => Graph graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms -> arc value -> IO ()Source
delete an arc
setArcValue :: (GraphAll graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms, Typeable value) => Graph graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms -> arc value -> value -> IO ()Source
set the value associated with an arc
setArcType :: (GraphAll graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms, Typeable value) => Graph graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms -> arc value -> arcType value -> IO ()Source
getArcValue :: (GraphAll graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms, Typeable value) => Graph graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms -> arc value -> IO valueSource
get the value associated with an arc
newArcType :: (GraphAll graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms, Typeable value) => Graph graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms -> arcTypeParms value -> IO (arcType value)Source
create a new arc type
class ArcTypeParms arcTypeParms whereSource
emptyArcTypeParms :: Typeable value => arcTypeParms valueSource
invisibleArcTypeParms :: Typeable value => arcTypeParms valueSource
coMapArcTypeParms :: (Typeable value1, Typeable value2) => (value2 -> value1) -> arcTypeParms value1 -> arcTypeParms value2Source
ArcTypeParms EmptyArcTypeParms |
User-Hateful Interface
This is only needed by people wanting to implement new implementations of the interface.
class (GraphClass graph, NewGraph graph graphParms, GraphParms graphParms, NewNode graph node nodeType, DeleteNode graph node, SetNodeFocus graph node, NodeClass node, Typeable1 node, NodeTypeClass nodeType, NewNodeType graph nodeType nodeTypeParms, NodeTypeParms nodeTypeParms, NewArc graph node node arc arcType, SetArcType graph arc arcType, DeleteArc graph arc, ArcClass arc, Typeable1 arc, ArcTypeClass arcType, NewArcType graph arcType arcTypeParms) => GraphAll graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms whereSource
displaySort :: Graph graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParmsSource
(GraphClass graph, NewGraph graph graphParms, GraphParms graphParms, NewNode graph node nodeType, DeleteNode graph node, SetNodeFocus graph node, NodeClass node, NodeTypeClass nodeType, NewNodeType graph nodeType nodeTypeParms, NodeTypeParms nodeTypeParms, NewArc graph node node arc arcType, SetArcType graph arc arcType, DeleteArc graph arc, ArcClass arc, ArcTypeClass arcType, NewArcType graph arcType arcTypeParms) => GraphAll graph graphParms node nodeType nodeTypeParms arc arcType arcTypeParms |
class (Destructible graph, Ord graph, Typeable graph, HasDelayer graph) => GraphClass graph whereSource
redrawPrim :: graph -> IO ()Source
GraphClass EmptyGraph |
class (GraphClass graph, GraphParms graphParms) => NewGraph graph graphParms whereSource
newGraphPrim :: graphParms -> IO graphSource
NewGraph EmptyGraph EmptyGraphParms |
class GraphConfig graphConfig Source
GraphConfig Delayer | Allows the user to specify a |
GraphConfig ActionWrapper | |
GraphConfig Orientation | |
GraphConfig FileMenuAct | |
GraphConfig AllowClose | |
GraphConfig AllowDragging | |
GraphConfig SurveyView | |
GraphConfig OptimiseLayout | |
GraphConfig GraphGesture | |
GraphConfig GraphTitle | |
GraphConfig GlobalMenu | |
GraphConfig (SimpleSource GraphTitle) |
class (GraphClass graph, NodeClass node, NodeTypeClass nodeType) => NewNode graph node nodeType whereSource
newNodePrim :: Typeable value => graph -> nodeType value -> value -> IO (node value)Source
setNodeTypePrim :: Typeable value => graph -> node value -> nodeType value -> IO ()Source
NewNode EmptyGraph EmptyNode EmptyNodeType |
class (GraphClass graph, NodeClass node) => DeleteNode graph node whereSource
deleteNodePrim :: Typeable value => graph -> node value -> IO ()Source
getNodeValuePrim :: Typeable value => graph -> node value -> IO valueSource
setNodeValuePrim :: Typeable value => graph -> node value -> value -> IO ()Source
getMultipleNodesPrim :: graph -> (Event (WrappedNode node) -> IO a) -> IO aSource
DeleteNode EmptyGraph EmptyNode |
class (GraphClass graph, NodeClass node) => SetNodeFocus graph node whereSource
setNodeFocusPrim :: Typeable value => graph -> node value -> IO ()Source
SetNodeFocus EmptyGraph EmptyNode |
class Typeable1 nodeType => NodeTypeClass nodeType Source
NodeTypeClass EmptyNodeType |
class (GraphClass graph, NodeTypeClass nodeType, NodeTypeParms nodeTypeParms) => NewNodeType graph nodeType nodeTypeParms whereSource
newNodeTypePrim :: Typeable value => graph -> nodeTypeParms value -> IO (nodeType value)Source
NewNodeType EmptyGraph EmptyNodeType EmptyNodeTypeParms |
class Kind1 nodeTypeConfig => NodeTypeConfig nodeTypeConfig Source
class (GraphClass graph, NodeClass nodeFrom, NodeClass nodeTo, ArcClass arc, ArcTypeClass arcType) => NewArc graph nodeFrom nodeTo arc arcType whereSource
newArcPrim :: (Typeable value, Typeable nodeFromValue, Typeable nodeToValue) => graph -> arcType value -> value -> nodeFrom nodeFromValue -> nodeTo nodeToValue -> IO (arc value)Source
newArcListDrawerPrim :: (Typeable value, Typeable nodeFromValue) => graph -> nodeFrom nodeFromValue -> ListDrawer (arcType value, value, WrappedNode nodeTo) (arc value)Source
NewArc EmptyGraph EmptyNode EmptyNode EmptyArc EmptyArcType |
class (ArcClass arc, ArcTypeClass arcType) => SetArcType graph arc arcType whereSource
setArcTypePrim :: Typeable value => graph -> arc value -> arcType value -> IO ()Source
SetArcType EmptyGraph EmptyArc EmptyArcType |
class (GraphClass graph, ArcClass arc) => DeleteArc graph arc whereSource
deleteArcPrim :: Typeable value => graph -> arc value -> IO ()Source
setArcValuePrim :: Typeable value => graph -> arc value -> value -> IO ()Source
getArcValuePrim :: Typeable value => graph -> arc value -> IO valueSource
DeleteArc EmptyGraph EmptyArc |
class (Typeable1 arcType, Ord1 arcType) => ArcTypeClass arcType whereSource
invisibleArcType :: Typeable value => arcType valueSource
ArcTypeClass EmptyArcType |
class (GraphClass graph, ArcTypeClass arcType, ArcTypeParms arcTypeParms) => NewArcType graph arcType arcTypeParms whereSource
newArcTypePrim :: Typeable value => graph -> arcTypeParms value -> IO (arcType value)Source
NewArcType EmptyGraph EmptyArcType EmptyArcTypeParms |
class Kind1 arcTypeConfig => ArcTypeConfig arcTypeConfig Source