O'Reilly logo

ActionScript Graphing Cookbook by Peter Backx, Dominic Gélineau

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Arranging and linking the nodes

Now we are going to take the nodes created in the previous recipe and arrange them to show a level of the tree (a parent with its children). We are going to place the parent in the middle and arrange the children around it with lines showing the relationship.

Arranging and linking the nodes

Getting ready

Open the files downloaded from the Packt Publishing website for Chapter 8 | Recipe 3 to follow along.

How to do it...

The following are the steps necessary to put the nodes together to make a relational network:

  1. Create the class RelationalNetwork.as.
  2. Instantiate a NodeVisual object with the data provided; this is going to be our parent:
    _centerNode ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required