NAME
Text::Editor::Vip::Buffer::List - lines container
SYNOPSIS
use Text::Editor::Vip::Buffer::List
DESCRIPTION
Container class used by Text::Editor::Vip::Buffer to hold the buffers text. Elements aer accessed by index.
MEMBER FUNCTIONS
new
Create an empty container. Takes no arguments.
GetNumberOfNodes
Returns the number of contained elements.
Push
Adds an element at the end of the the container. Returns it's index.
GetNodeData
Returns an element or undef if the element doesn't exist.
$list = new Text::Editor::Vip::Buffer::List() ;
$list->Push(['some_element']) ;
my $element = $list->GetNodeData(0) ;
SetNodeData
Sets the element at the given index. The element must exist.
my $index = 0 ;
my $element = [] ;
$list->SetNodeData($index, $element) ;
DeleteNode
Removes the lement at the given index. all elements after the given index are shifted up in the list. The element must exist.
$list->DeleteNode($index) ;
InsertAfter
Creates and inserts an element in the list after the given index. The element at the given index must exist.
$list->InsertAfter($index, $element_data) ;
InsertBefore
Creates and inserts an element in the list before the given index. The element at the given index must exist.
$list->InsertBefore($index, $element_data) ;
AUTHOR
Khemir Nadim ibn Hamouda
CPAN ID: NKH
mailto:nadim@khemir.net
http:// no web site
COPYRIGHT
This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
The full text of the license can be found in the LICENSE file included with this module.