Project

path_tree

0.0
No commit activity in last 3 years
No release in over 3 years
Module that defines a tree data structure based on a path.
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
 Dependencies

Development

~> 2.0
~> 1.7
~> 10.0
~> 2.99

Runtime

< 4.3, >= 3.2.0
 Project Readme

PathTree¶ ↑

This gem provides support for creating tree data structures. The structure of the tree is defined with dot delimited paths on each node. This has a couple of advantages over the acts_as_tree plugin.

  1. Each node gets a unique character identifier that has semantic qualities and indicates the structure in the tree.

  2. Queries for all ancestors or all descendants are far more efficient.

  3. Out of the box the code works with ActiveRecord, but it can easily be made to work with other ORM’s if they implement just a few methods.

See PathTree for more details.