Forest::Tree::Builder::SimpleTextFile(3pm)

Forest::Tree::Builder::SimpleTextFile3pm

Parse trees from indented ascii files

Usage

    use Path::Class;
    my $file = file($path);
    my $builder = Forest::Tree::Builder::SimpleTextFile->new(
        fh => $file->openr,
    );
    my $tree = $builder->tree;

Overview

This module replaces Forest::Tree::Reader::SimpleTextFile with a declarative api instead of an imperative one.

Attributes

fh

The filehandle to read from.

Required.

parser

A coderef that parses a single line from "fh" and returns the node depth and its value.

Defaults to space indented text. See also "tab_width".

tab_width

The indentation level for the default parser. Defaults to 4, which means that four spaces equate to one level of nesting.

Releases

8 releases since Debian 6.0 (Squeeze); the text changed 4 times.

  1. 6.0
  2. 7
  3. 8–10
  4. 11
  5. 12–13

Bugs

All complex software has bugs lurking in it, and this module is no exception. If you find a bug please either email me, or add the bug to cpan-RT.

Author

Yuval Kogman

From libforest-perl 0.10-2 in Debian 13 (Trixie). Parsed by carta from the page's man source.