#include <vbl_sparse_array_2d.h>
Inheritance diagram for vbl_sparse_array_2d< T >:

Definition at line 30 of file vbl_sparse_array_2d.h.
Public Types | |
| typedef vbl_sparse_array_base< T, vcl_pair< unsigned, unsigned > >::const_iterator | const_iterator |
| The type of iterators into the efficient storage. | |
| typedef T | T_type |
| The type of values stored by the sparse array. | |
| typedef Map::value_type | sequence_value_type |
| The type of values of the controlled sequence. | |
Public Member Functions | |
| bool | put (unsigned i, unsigned j, const T &t) |
| Put a value into location (i,j). | |
| T & | operator() (unsigned i, unsigned j) |
| Return contents of location (i,j). | |
| const T & | operator() (unsigned i, unsigned j) const |
| Return contents of (i,j). Assertion failure if not yet filled. | |
| void | erase (unsigned i, unsigned j) |
| Erase element at location (i,j). Assertion failure if not yet filled. | |
| bool | fullp (unsigned i, unsigned j) const |
| Return true if location (i,j) has been filled. | |
| T * | get_addr (unsigned i, unsigned j) |
| Return the address of location (i,j). 0 if not yet filled. | |
| vcl_ostream & | print (vcl_ostream &out) const |
| Print the Array to a stream in "(i,j): value" format. | |
| T & | operator() (vcl_pair< unsigned, unsigned >i) |
| Return contents at (i). | |
| Tconst & | operator() (vcl_pair< unsigned, unsigned >i) const |
| Return contents at (i). Asserts if (i) empty. | |
| void | erase (vcl_pair< unsigned, unsigned >) |
| Erase element at location (i). Assertion failure if not yet filled. | |
| bool | fullp (vcl_pair< unsigned, unsigned >) const |
| Return true if location (i) has been filled. | |
| bool | put (vcl_pair< unsigned, unsigned >, const T &) |
| Put a value into location (i). | |
| T * | get_addr (vcl_pair< unsigned, unsigned >) |
| Return the address of location (i). 0 if not yet filled. | |
| void | clear () |
| Empty the sparse matrix. | |
| unsigned | count_nonempty () const |
| Return number of locations that have been assigned a value using "put". | |
| const_iterator | begin () const |
| A bidirectional iterator pointing at the first non-empty element. | |
| const_iterator | end () const |
| A bidirectional iterator pointing just beyond last non-empty element. | |
Protected Types | |
| typedef vcl_map< vcl_pair< unsigned, unsigned >, T, vcl_less< vcl_pair< unsigned, unsigned > > > | Map |
| The type of the storage. | |
Protected Attributes | |
| Map | storage_ |
| This stores a compact list of the values. | |
Private Types | |
| typedef vbl_sparse_array_base< T, vcl_pair< unsigned, unsigned > >::Index_type | Index_type |
| The type of objects used to index the sparse array. | |
|
|||||
|
The type of iterators into the efficient storage.
Reimplemented from vbl_sparse_array_base< T, vcl_pair< unsigned, unsigned > >. Definition at line 34 of file vbl_sparse_array_2d.h. |
|
|||||
|
The type of objects used to index the sparse array.
Reimplemented from vbl_sparse_array_base< T, vcl_pair< unsigned, unsigned > >. Definition at line 32 of file vbl_sparse_array_2d.h. |
|
|
The type of the storage.
Definition at line 41 of file vbl_sparse_array_base.h. |
|
|
The type of values of the controlled sequence. The value_type is a vcl_pair<Index_type, typename T_type> Definition at line 82 of file vbl_sparse_array_base.h. |
|
|
The type of values stored by the sparse array.
Definition at line 78 of file vbl_sparse_array_base.h. |
|
|
A bidirectional iterator pointing at the first non-empty element. If the array is empty it points just beyond the end. Definition at line 86 of file vbl_sparse_array_base.h. |
|
|
Empty the sparse matrix.
|
|
|
Return number of locations that have been assigned a value using "put".
Definition at line 72 of file vbl_sparse_array_base.h. |
|
|
A bidirectional iterator pointing just beyond last non-empty element.
Definition at line 89 of file vbl_sparse_array_base.h. |
|
|
Erase element at location (i). Assertion failure if not yet filled.
|
|
||||||||||||||||
|
Erase element at location (i,j). Assertion failure if not yet filled.
Definition at line 57 of file vbl_sparse_array_2d.h. |
|
|
Return true if location (i) has been filled.
|
|
||||||||||||||||
|
Return true if location (i,j) has been filled.
Definition at line 62 of file vbl_sparse_array_2d.h. |
|
|
Return the address of location (i). 0 if not yet filled.
|
|
||||||||||||||||
|
Return the address of location (i,j). 0 if not yet filled.
Definition at line 68 of file vbl_sparse_array_2d.h. |
|
|
Return contents at (i). Asserts if (i) empty.
|
|
|
Return contents at (i).
Definition at line 48 of file vbl_sparse_array_base.h. |
|
||||||||||||||||
|
Return contents of (i,j). Assertion failure if not yet filled.
Definition at line 51 of file vbl_sparse_array_2d.h. |
|
||||||||||||||||
|
Return contents of location (i,j). Returns an undefined value (in fact a T()) if location (i,j) has not been filled with a value. Definition at line 45 of file vbl_sparse_array_2d.h. |
|
||||||||||
|
Print the Array to a stream in "(i,j): value" format.
Definition at line 74 of file vbl_sparse_array_2d.h. |
|
||||||||||||
|
Put a value into location (i).
|
|
||||||||||||||||||||
|
Put a value into location (i,j).
Definition at line 37 of file vbl_sparse_array_2d.h. |
|
|
This stores a compact list of the values.
Definition at line 43 of file vbl_sparse_array_base.h. |
1.4.4