Client API. The Codename One framework your app is built on: this runs on the device, not in a backend.

package com.codename1.ui.graph

NodeGraph: a pannable, zoomable view of a com.codename1.graph.GraphModel where nodes are dragged, connected and grouped.

It serves two kinds of picture with one component. A diagram of a system, where boxes stand for services or ideas and edges join them, is made of nodes without ports; a node editor, where data flows from outputs to inputs of a matching type, is made of nodes with GraphPorts. Both can be laid out by hand or by a com.codename1.graph.arrange.GraphArrangement.

Nodes and edges are painted, with no component behind each, so a graph of thousands of nodes costs what is on screen. A node that needs a real control gets one from a NodeComponentFactory. Colours and fonts come from the NodeGraph* UIIDs.

Types

class DefaultGraphEdgeRendererPaints an edge as a line with an arrowhead on a directed edge and its label in a pill at the middle.
class DefaultGraphNodeRendererPaints a node as a rounded card: a coloured strip on the leading edge, the label, the description under it, and the ports on the sides with their labels inside the card.
class GraphAdapterA GraphListener that refuses nothing and ignores everything; override what you need.
interface GraphEdgeRendererPaints an edge along the path the graph computed for it.
interface GraphListenerWhat a NodeGraph tells an application about.
interface GraphNodeRendererPaints a node.
interface NodeComponentFactoryMakes a real component for a node’s body, such as a slider in a node editor.
class NodeGraphA pannable, zoomable view of a GraphModel where nodes are dragged, connected and grouped: a system diagram, a mind map, or a node editor.