Public Member Functions | |
| template<class Derived> | |
| tag_collection (context< Derived > *ctxt, bool preserveTags=false) | |
| constructor which registers collection with given context | |
| void | put (const Tag &t) |
| prescribe the associated step. If we are preserving tags for this collection, make a copy of the tag and store it in the collection. | |
| const_iterator | begin () const |
| returns begin() as in STL containers | |
| const_iterator | end () const |
| returns end() as in STL containers | |
| void | reset () |
| removes all of the tag instances from the collection | |
| size_t | size () |
| returns number of elements in collection | |
| bool | empty () |
| returns true if size()==0, false otherwise | |
Tag must provide copy and default constructors and the assigment operator.
If Tag is not convertable into size_t, a suitable hash_compare class must be provided which satisifies the requirements for tbb::concurrent_hash_map. The default cnc_tag_hash_compare works for types that can be converted to size_t and have an operator==. You can provide a specialized template for cnc_tag_hash_compare or specify and implement your own compatible class.
Definition at line 125 of file cnc.h.
| tag_collection | ( | context< Derived > * | ctxt, | |
| bool | preserveTags = false | |||
| ) | [inline] |
| void put | ( | const Tag & | t | ) |
prescribe the associated step. If we are preserving tags for this collection, make a copy of the tag and store it in the collection.
| t | the tag to be put |
| const_iterator begin | ( | ) | const |
returns begin() as in STL containers
| const_iterator end | ( | ) | const |
returns end() as in STL containers
1.5.6