Michael G Schwern > Test-Simple-1.005000_002 > TB2::StackBuilder

Download:
Test-Simple-1.005000_002.tar.gz

Dependencies

Annotate this POD

Website

View/Report Bugs
Module Version: 1.005000_002   Source   Latest Release: Test-Simple-1.005000_005

NAME ^

TB2::StackBuilder - A stack builder

SYNOPSIS ^

    # TODO

    use TB2::StackBuilder;
    buildstack items => 'Int';

    # is the same as having said:

    has items => (
        is => 'rw',
        isa => 'ArrayRef[Int]',
        default => sub{[]},
    );
    sub items_push { ... }
    sub items_pop  { ... }
    sub items_count{ ... }

DESCRIPTION ^

Exports a keyword buildstack to build up an Attribute array and methods consistanly.

EXPORTED FUNCTIONS ^

buildstack

  buildstack $name; # stack is just an ArrayRef
  buildstack $name => $subtype; # ArrayRef[$subtype]
syntax highlighting: