Skip to content

Attach a branch to a node #80

@Ziggizag

Description

@Ziggizag

Hi!

I like your code very much - the quick question is:

Can you please enhance your brilliant code implementing (pseudocode) as follows:

  1. $branch = $node->getBranch($childNode)

This should return an array defining $childNode (what is a child node of $node) with all its children.

  1. $branch = $node->detatchBranch($childNode)

This should behave as (1) but also remove $childNode and all it's children from $node

  1. $node->attachBranch($branch)

This should attach $childNode with all its children to $node

Having this functionality this library would be really great as it would enable complex manipulation on the tree structure.

Metadata

Metadata

Assignees

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions