abstract container class that throws an exception if an unknown key is accessed
More...
#include <SqlUtil.qm.dox.h>
|
|
| add (auto val) |
| | adds the given value to the list
|
| |
|
| constructor (softlist nl) |
| | creates the object with the list<auto> argument passed
|
| |
|
bool | empty () |
| | returns True if the container is empty, False if not
|
| |
| abstract auto | get (softint i) |
| | returns the value of the given element in the contained list if it exists, otherwise throws an ELEMENT-ERROR exception More...
|
| |
|
abstract string | getElementName () |
| | must return the name of the contained element
|
| |
|
list< auto > | getList () |
| | returns the list contained by this object
|
| |
| Qore::ListIterator | iterator () |
| | Returns a ListIterator object for the contained list. More...
|
| |
| int | size () |
| | Returns the number of elements in the contained list. More...
|
| |
|
auto | take (int i) |
| | removes the given element from the contained list and returns the value
|
| |
| bool | val () |
| | Returns False if the contained list is empty, True if not. More...
|
| |
abstract container class that throws an exception if an unknown key is accessed
◆ get()
| abstract auto SqlUtil::AbstractListContainer::get |
( |
softint |
i | ) |
|
|
pure virtual |
returns the value of the given element in the contained list if it exists, otherwise throws an ELEMENT-ERROR exception
- Example:
- Parameters
-
| i | the index of the element to access |
- Returns
- the value of the given index in the contained list if it exists
- Exceptions
-
| ELEMENT-ERROR | the given element does not exist in the contained list |
◆ iterator()
Returns a ListIterator object for the contained list.
- Example:
map printf("+ %s: %y\n", $1), h.iterator();
- Returns
- a HashIterator object for the contained hash
◆ size()
| int SqlUtil::AbstractListContainer::size |
( |
| ) |
|
Returns the number of elements in the contained list.
- Example:
- Returns
- the number of elements in the contained list
◆ val()
| bool SqlUtil::AbstractListContainer::val |
( |
| ) |
|
Returns False if the contained list is empty, True if not.
- Example:
The opposite of empty()
- Returns
- False if the contained list is empty, True if not