WalkerTreeLayout

class WalkerTreeLayout<T>(adapter: TreeAdapter<T>, configuration: WalkerLayoutConfiguration = WalkerLayoutConfiguration(), nodeExtentProvider: NodeExtentProvider<T> = UniformNodeExtentProvider())

Computes a tidy tree layout using the Walker algorithm (Buchheim variant). Runs in O(n) time complexity.

This is a pure, platform-agnostic implementation with no JVM dependencies.

Parameters

adapter

Adapter providing tree traversal over the external structure.

configuration

Layout spacing parameters.

nodeExtentProvider

Provides node dimensions. Defaults to dimensionless points (0×0).

Type Parameters

T

The node type of the external tree.

Constructors

Link copied to clipboard
constructor(adapter: TreeAdapter<T>, configuration: WalkerLayoutConfiguration = WalkerLayoutConfiguration(), nodeExtentProvider: NodeExtentProvider<T> = UniformNodeExtentProvider())

Functions

Link copied to clipboard

Executes the layout algorithm and returns the result.