Gumbo_Interface_List
List Interface, responsible for holding a List of some data
This is a typical set of common methods for accessing and manipulating a List of data. This is the general Interface for accessing many types of Lists. Some classes will extend this implementation, or use the interface to define ways of accessing private information.
Author(s): |
Michael Luster <mluster79@yahoo.com> |
License: | New BSD License |
Copyright: | Copyright (c) 2007, iBayou, Michael Luster |
Link: | http://sourceforge.net/projects/phpgumbo |
Version: | 0.0.1 |
Child classes:
Interface Methods
public void add ( mixed $data, [int|string $key] )
[line 76]
Adds a new Item to the List
Parameter(s):
- (mixed) $data
- (int|string) $key
[ Top ]
public bool exists ( [int|string $key] )
[line 129]
Returns if the Key exists, or if the List contains data
Parameter(s):
- (int|string) $key
[ Top ]
public mixed get ( int|string $key )
[line 104]
Returns a single Value
Parameter(s):
- (int|string) $key
[ Top ]
public void remove ( int|string $key )
[line 82]
Removes an Item from the List
Parameter(s):
- (int|string) $key
[ Top ]
public void removeValue ( mixed $data )
[line 88]
Removes a value from the List
Parameter(s):
- (mixed) $data
[ Top ]
public void reset ( )
[line 94]
Resets the List
- postcondition:
!size()
[ Top ]public mixed __get ( int|string $key ) [line 46]Returns Data (wrapper to get())
Parameter(s):
- (int|string) $key :: for integers, use $list->{$num}
[ Top ]public bool __isset ( int|string $key ) [line 60]Returns if key is set (wrapper to exists())
Parameter(s):
- (int|string) $key
[ Top ]public void __set ( int|string $key, mixed $data ) [line 53]Sets Data (wrapper to add())
Parameter(s):
- (int|string) $key
- (mixed) $data
[ Top ]