SheafSystem
0.0.0.0
|
An abstract iterator over the id spaces of a interval. More...
#include <index_space_family_iterator.h>
INDEX_SPACE_FAMILY_ITERATOR FACET | |
typedef pod_index_type | pod_type |
The "plain old data" index type for this. More... | |
typedef index_space_family::interval_map_type | interval_map_type |
Type of interval map. More... | |
typedef interval_map_type::const_iterator | const_interval_iterator_type |
Type of interval map iterator. More... | |
const index_space_family * | _id_spaces |
The index space family. More... | |
const_interval_iterator_type | _interval_itr |
The stl iterator over the intervals. More... | |
index_space_interval_iterator | _id_space_itr |
The iterator over id spaces for the current id space interval. More... | |
index_space_family_iterator (const index_space_family &xid_spaces, bool xonly_persistent) | |
Constructor: Creates an instance with id_spaces() == xid_spaces and only_persistent() == xonly_persistent. More... | |
virtual | ~index_space_family_iterator () |
Destructor. More... | |
index_space_family_iterator & | operator= (const index_space_family_iterator &xother) |
Assignment operator. More... | |
bool | operator== (const index_space_family_iterator &xother) const |
True if this is equivalent to xother. More... | |
index_space_family_iterator * | clone () const |
Virtual constructor, makes a new instance of the same type as this. If the iterator is attached, attach to the same state. More... | |
bool | only_persistent () const |
True if only the persistent id spaces are iterated over. More... | |
void | next () |
Makes id_space() the next id space in the iteration. More... | |
bool | is_done () const |
True if iteration is finished. More... | |
void | reset () |
Restarts the iteration. More... | |
const index_space_interval & | host () const |
The current host id space interval being iterated over. More... | |
pod_type | index () const |
The index of the current id space in the iteration. More... | |
std::string | name () const |
The name of the current id space in the iteration. More... | |
index_space_family_iterator () | |
Default constructor; disabled. More... | |
index_space_family_iterator (const index_space_family_iterator &xother) | |
Copy constructor. More... | |
void | next_id_space () |
Increment to the next id space in the interval. More... | |
INDEX SPACE FACET | |
const index_space_family & | id_spaces () const |
The id space family for this (const version). More... | |
const hub_index_space_handle & | hub_id_space () const |
The hub id space. More... | |
size_type | ct () const |
The number of members. More... | |
pod_type | begin () const |
Beginning id of this space. More... | |
pod_type | end () const |
Ending id of this space. More... | |
bool | contains (pod_type xid) const |
True if this space contains id xid. More... | |
bool | contains_hub (pod_type xid) const |
True if this space contains an id equivalent to xid in the unglued hub id space. More... | |
bool | contains_unglued_hub (pod_type xid) const |
True if this space contains an id equivalent to xid in the unglued hub id space. More... | |
bool | contains_glued_hub (pod_type xid) const |
True if this space contains an id equivalent to xid in the glued hub id space. More... | |
bool | contains (pod_type xid, pod_type xhub_id) const |
True if this space contains an id xid equivalent to xhub_id in the hub id space. More... | |
pod_type | pod (pod_type xid) const |
The pod index in this space equivalent to xid in the hub id space. More... | |
pod_type | hub_pod (pod_type xid) const |
The pod index in the unglued hub id space equivalent to xid in this id space. More... | |
pod_type | unglued_hub_pod (pod_type xid) const |
The pod index in the unglued hub id space equivalent to xid in this id space. More... | |
pod_type | glued_hub_pod (pod_type xid) const |
The pod index in the glued hub id space equivalent to xid in this id space. More... | |
bool | is_persistent () const |
True if this id space should be written to disk. More... | |
HANDLE POOL FACET | |
index_space_handle & | get_id_space () const |
Allocates an id space handle from the handle pool attached to the current id space state. More... | |
void | release_id_space (index_space_handle &xid_space) const |
Returns the id space handle xid_space to the handle pool. More... | |
bool | allocated_id_space (index_space_handle &xid_space) const |
True if and only if id space handle xid_space was allocated by the handle pool. More... | |
ITERATOR POOL FACET | |
index_space_iterator & | get_id_space_iterator () const |
Allocates an id space iterator from the iterator pool attached to the current id space state. More... | |
void | release_id_space_iterator (index_space_iterator &xitr) const |
Returns the id space iterator xitr to the iterator pool. More... | |
bool | allocated_id_space_iterator (index_space_iterator &xitr) const |
True if and only if id space iterator xitr was allocated by the iterator pool. More... | |
ANY FACET | |
virtual bool | is_ancestor_of (const any *other) const |
Conformance test; true if other conforms to this. More... | |
virtual bool | invariant () const |
Class invariant. More... | |
Additional Inherited Members | |
Public Member Functions inherited from sheaf::any | |
bool | is_same_type (const any *other) const |
True if other is the same type as this. More... | |
virtual | ~any () |
Destructor. More... | |
bool | invariant_check () const |
True if invariant checking is enabled. More... | |
void | enable_invariant_check () const |
Enable invariant checking. More... | |
void | disable_invariant_check () const |
Disable invariant check. Intended for preventing recursive calls to invariant and for suppressing invariant checking during multi-phase initialization. More... | |
int | disable_invariance_check_request_depth () const |
Number of times disable_invariant_check has been called without matching call to enable_invariant_check. More... | |
Protected Member Functions inherited from sheaf::any | |
any () | |
default constructor More... | |
An abstract iterator over the id spaces of a interval.
Definition at line 50 of file index_space_family_iterator.h.
|
protected |
Type of interval map iterator.
Definition at line 153 of file index_space_family_iterator.h.
|
protected |
Type of interval map.
Definition at line 148 of file index_space_family_iterator.h.
The "plain old data" index type for this.
Definition at line 63 of file index_space_family_iterator.h.
sheaf::index_space_family_iterator::index_space_family_iterator | ( | const index_space_family & | xid_spaces, |
bool | xonly_persistent | ||
) |
Constructor: Creates an instance with id_spaces() == xid_spaces and only_persistent() == xonly_persistent.
Definition at line 34 of file index_space_family_iterator.cc.
References id_spaces(), invariant(), only_persistent(), reset(), and ~index_space_family_iterator().
|
virtual |
Destructor.
Definition at line 57 of file index_space_family_iterator.cc.
References operator=().
Referenced by index_space_family_iterator().
|
inlineprotected |
Default constructor; disabled.
Definition at line 133 of file index_space_family_iterator.h.
|
protected |
Copy constructor.
Definition at line 357 of file index_space_family_iterator.cc.
References invariant(), and next_id_space().
bool sheaf::index_space_family_iterator::allocated_id_space | ( | index_space_handle & | xid_space | ) | const |
True if and only if id space handle xid_space was allocated by the handle pool.
Definition at line 787 of file index_space_family_iterator.cc.
References _id_space_itr, sheaf::index_space_interval_iterator::allocated_id_space(), get_id_space_iterator(), and is_done().
Referenced by release_id_space().
bool sheaf::index_space_family_iterator::allocated_id_space_iterator | ( | index_space_iterator & | xitr | ) | const |
True if and only if id space iterator xitr was allocated by the iterator pool.
Definition at line 862 of file index_space_family_iterator.cc.
References _id_space_itr, sheaf::index_space_interval_iterator::allocated_id_space_iterator(), is_ancestor_of(), and is_done().
Referenced by release_id_space_iterator().
sheaf::index_space_handle::pod_type sheaf::index_space_family_iterator::begin | ( | ) | const |
Beginning id of this space.
Definition at line 481 of file index_space_family_iterator.cc.
References _id_space_itr, sheaf::index_space_interval_iterator::begin(), end(), and is_done().
Referenced by ct().
|
virtual |
Virtual constructor, makes a new instance of the same type as this. If the iterator is attached, attach to the same state.
Reimplemented from sheaf::any.
Definition at line 121 of file index_space_family_iterator.cc.
References index_space_family_iterator(), sheaf::any::is_same_type(), and only_persistent().
Referenced by operator==().
bool sheaf::index_space_family_iterator::contains | ( | pod_type | xid | ) | const |
True if this space contains id xid.
Definition at line 523 of file index_space_family_iterator.cc.
References _id_space_itr, sheaf::index_space_interval_iterator::contains(), contains_hub(), and is_done().
Referenced by contains_glued_hub(), end(), and pod().
True if this space contains an id xid equivalent to xhub_id in the hub id space.
Definition at line 607 of file index_space_family_iterator.cc.
References _id_space_itr, sheaf::index_space_interval_iterator::contains(), is_done(), and pod().
bool sheaf::index_space_family_iterator::contains_glued_hub | ( | pod_type | xid | ) | const |
True if this space contains an id equivalent to xid in the glued hub id space.
Definition at line 586 of file index_space_family_iterator.cc.
References _id_space_itr, contains(), sheaf::index_space_interval_iterator::contains_glued_hub(), and is_done().
Referenced by contains_unglued_hub(), and glued_hub_pod().
bool sheaf::index_space_family_iterator::contains_hub | ( | pod_type | xid | ) | const |
True if this space contains an id equivalent to xid in the unglued hub id space.
Definition at line 544 of file index_space_family_iterator.cc.
References _id_space_itr, sheaf::index_space_interval_iterator::contains_hub(), contains_unglued_hub(), and is_done().
Referenced by contains(), and hub_pod().
bool sheaf::index_space_family_iterator::contains_unglued_hub | ( | pod_type | xid | ) | const |
True if this space contains an id equivalent to xid in the unglued hub id space.
Definition at line 565 of file index_space_family_iterator.cc.
References _id_space_itr, contains_glued_hub(), sheaf::index_space_interval_iterator::contains_unglued_hub(), and is_done().
Referenced by contains_hub(), and unglued_hub_pod().
sheaf::size_type sheaf::index_space_family_iterator::ct | ( | ) | const |
The number of members.
Definition at line 460 of file index_space_family_iterator.cc.
References _id_space_itr, begin(), sheaf::index_space_interval_iterator::ct(), and is_done().
Referenced by hub_id_space().
sheaf::index_space_handle::pod_type sheaf::index_space_family_iterator::end | ( | ) | const |
Ending id of this space.
Definition at line 502 of file index_space_family_iterator.cc.
References _id_space_itr, contains(), sheaf::index_space_interval_iterator::end(), and is_done().
Referenced by begin().
sheaf::index_space_handle & sheaf::index_space_family_iterator::get_id_space | ( | ) | const |
Allocates an id space handle from the handle pool attached to the current id space state.
Definition at line 744 of file index_space_family_iterator.cc.
References _id_space_itr, sheaf::index_space_interval_iterator::get_id_space(), sheaf::index_space_handle::is_attached(), is_done(), and release_id_space().
Referenced by is_persistent().
sheaf::index_space_iterator & sheaf::index_space_family_iterator::get_id_space_iterator | ( | ) | const |
Allocates an id space iterator from the iterator pool attached to the current id space state.
Definition at line 819 of file index_space_family_iterator.cc.
References _id_space_itr, sheaf::index_space_interval_iterator::get_id_space_iterator(), sheaf::index_space_iterator::is_attached(), is_done(), and release_id_space_iterator().
Referenced by allocated_id_space(), and sheaf::index_equivalence_class::index_equivalence_class().
sheaf::index_space_handle::pod_type sheaf::index_space_family_iterator::glued_hub_pod | ( | pod_type | xid | ) | const |
The pod index in the glued hub id space equivalent to xid in this id space.
Definition at line 691 of file index_space_family_iterator.cc.
References _id_space_itr, contains_glued_hub(), sheaf::index_space_interval_iterator::glued_hub_pod(), is_done(), is_persistent(), and sheaf::is_valid().
Referenced by unglued_hub_pod().
const sheaf::index_space_interval & sheaf::index_space_family_iterator::host | ( | ) | const |
The current host id space interval being iterated over.
Definition at line 293 of file index_space_family_iterator.cc.
References _id_space_itr, sheaf::index_space_interval_iterator::host(), index(), and is_done().
Referenced by reset().
const sheaf::hub_index_space_handle & sheaf::index_space_family_iterator::hub_id_space | ( | ) | const |
The hub id space.
Definition at line 441 of file index_space_family_iterator.cc.
References _id_spaces, ct(), and sheaf::index_space_family::hub_id_space().
Referenced by id_spaces().
sheaf::index_space_handle::pod_type sheaf::index_space_family_iterator::hub_pod | ( | pod_type | xid | ) | const |
The pod index in the unglued hub id space equivalent to xid in this id space.
Definition at line 649 of file index_space_family_iterator.cc.
References _id_space_itr, contains_hub(), sheaf::index_space_interval_iterator::hub_pod(), is_done(), sheaf::is_valid(), and unglued_hub_pod().
Referenced by pod().
const sheaf::index_space_family & sheaf::index_space_family_iterator::id_spaces | ( | ) | const |
The id space family for this (const version).
Definition at line 422 of file index_space_family_iterator.cc.
References _id_spaces, and hub_id_space().
Referenced by index_space_family_iterator(), and next_id_space().
sheaf::index_space_family_iterator::pod_type sheaf::index_space_family_iterator::index | ( | ) | const |
The index of the current id space in the iteration.
Definition at line 314 of file index_space_family_iterator.cc.
References _id_space_itr, sheaf::index_space_interval_iterator::index(), is_done(), sheaf::is_valid(), and name().
Referenced by host(), sheaf::index_equivalence_class::index_equivalence_class(), invariant(), name(), next(), and sheaf::operator<<().
|
virtual |
Class invariant.
Reimplemented from sheaf::any.
Definition at line 915 of file index_space_family_iterator.cc.
References sheaf::any::disable_invariant_check(), sheaf::any::enable_invariant_check(), index(), sheaf::any::invariant(), sheaf::any::invariant_check(), is_done(), and sheaf::is_valid().
Referenced by index_space_family_iterator(), is_ancestor_of(), next(), operator=(), and reset().
|
virtual |
Conformance test; true if other conforms to this.
Reimplemented from sheaf::any.
Definition at line 894 of file index_space_family_iterator.cc.
References invariant().
Referenced by allocated_id_space_iterator(), operator=(), and operator==().
bool sheaf::index_space_family_iterator::is_done | ( | ) | const |
True if iteration is finished.
Definition at line 215 of file index_space_family_iterator.cc.
References _id_space_itr, sheaf::index_space_interval_iterator::is_attached(), sheaf::index_space_interval_iterator::is_done(), and reset().
Referenced by allocated_id_space(), allocated_id_space_iterator(), begin(), contains(), contains_glued_hub(), contains_hub(), contains_unglued_hub(), ct(), end(), get_id_space(), get_id_space_iterator(), glued_hub_pod(), host(), hub_pod(), index(), sheaf::index_equivalence_class::index_equivalence_class(), invariant(), is_persistent(), name(), next(), sheaf::operator<<(), pod(), release_id_space(), release_id_space_iterator(), and unglued_hub_pod().
bool sheaf::index_space_family_iterator::is_persistent | ( | ) | const |
True if this id space should be written to disk.
Definition at line 712 of file index_space_family_iterator.cc.
References _id_space_itr, get_id_space(), is_done(), and sheaf::index_space_interval_iterator::is_persistent().
Referenced by glued_hub_pod(), and next_id_space().
std::string sheaf::index_space_family_iterator::name | ( | ) | const |
The name of the current id space in the iteration.
Definition at line 335 of file index_space_family_iterator.cc.
References _id_spaces, index(), index_space_family_iterator(), is_done(), and sheaf::index_space_family::name().
Referenced by index(), and sheaf::operator<<().
void sheaf::index_space_family_iterator::next | ( | ) |
Makes id_space() the next id space in the iteration.
Definition at line 162 of file index_space_family_iterator.cc.
References _id_space_itr, _id_spaces, _interval_itr, sheaf::index_space_family::_intervals, sheaf::index_space_interval_iterator::attach_to(), sheaf::index_space_interval_iterator::detach(), index(), invariant(), is_done(), sheaf::index_space_interval_iterator::is_done(), sheaf::index_space_interval_iterator::next(), next_id_space(), and only_persistent().
Referenced by sheaf::index_equivalence_class::index_equivalence_class(), only_persistent(), and sheaf::operator<<().
|
protected |
Increment to the next id space in the interval.
Definition at line 377 of file index_space_family_iterator.cc.
References _id_space_itr, id_spaces(), sheaf::index_space_interval_iterator::is_attached(), sheaf::index_space_interval_iterator::is_done(), is_persistent(), sheaf::index_space_interval_iterator::next(), and only_persistent().
Referenced by index_space_family_iterator(), next(), and reset().
bool sheaf::index_space_family_iterator::only_persistent | ( | ) | const |
True if only the persistent id spaces are iterated over.
Definition at line 143 of file index_space_family_iterator.cc.
References _id_space_itr, next(), and sheaf::index_space_interval_iterator::only_persistent().
Referenced by clone(), sheaf::index_equivalence_class::index_equivalence_class(), index_space_family_iterator(), next(), next_id_space(), and reset().
sheaf::index_space_family_iterator & sheaf::index_space_family_iterator::operator= | ( | const index_space_family_iterator & | xother | ) |
Assignment operator.
Definition at line 74 of file index_space_family_iterator.cc.
References _id_space_itr, _id_spaces, _interval_itr, invariant(), is_ancestor_of(), and operator==().
Referenced by ~index_space_family_iterator().
bool sheaf::index_space_family_iterator::operator== | ( | const index_space_family_iterator & | xother | ) | const |
True if this is equivalent to xother.
Definition at line 98 of file index_space_family_iterator.cc.
References _id_space_itr, _id_spaces, _interval_itr, clone(), and is_ancestor_of().
Referenced by operator=().
sheaf::index_space_handle::pod_type sheaf::index_space_family_iterator::pod | ( | pod_type | xid | ) | const |
The pod index in this space equivalent to xid in the hub id space.
Definition at line 628 of file index_space_family_iterator.cc.
References _id_space_itr, contains(), hub_pod(), is_done(), sheaf::is_valid(), and sheaf::index_space_interval_iterator::pod().
Referenced by contains().
void sheaf::index_space_family_iterator::release_id_space | ( | index_space_handle & | xid_space | ) | const |
Returns the id space handle xid_space to the handle pool.
Definition at line 765 of file index_space_family_iterator.cc.
References _id_space_itr, allocated_id_space(), is_done(), and sheaf::index_space_interval_iterator::release_id_space().
Referenced by get_id_space().
void sheaf::index_space_family_iterator::release_id_space_iterator | ( | index_space_iterator & | xitr | ) | const |
Returns the id space iterator xitr to the iterator pool.
Definition at line 840 of file index_space_family_iterator.cc.
References _id_space_itr, allocated_id_space_iterator(), is_done(), and sheaf::index_space_interval_iterator::release_id_space_iterator().
Referenced by get_id_space_iterator(), and sheaf::index_equivalence_class::index_equivalence_class().
void sheaf::index_space_family_iterator::reset | ( | ) |
Restarts the iteration.
Definition at line 234 of file index_space_family_iterator.cc.
References _id_space_itr, _id_spaces, _interval_itr, sheaf::index_space_family::_intervals, sheaf::index_space_interval_iterator::attach_to(), sheaf::index_space_interval_iterator::detach(), host(), invariant(), sheaf::index_space_interval_iterator::is_done(), next_id_space(), and only_persistent().
Referenced by index_space_family_iterator(), and is_done().
sheaf::index_space_handle::pod_type sheaf::index_space_family_iterator::unglued_hub_pod | ( | pod_type | xid | ) | const |
The pod index in the unglued hub id space equivalent to xid in this id space.
Definition at line 670 of file index_space_family_iterator.cc.
References _id_space_itr, contains_unglued_hub(), glued_hub_pod(), is_done(), sheaf::is_valid(), and sheaf::index_space_interval_iterator::unglued_hub_pod().
Referenced by hub_pod().
|
protected |
The iterator over id spaces for the current id space interval.
Definition at line 168 of file index_space_family_iterator.h.
Referenced by allocated_id_space(), allocated_id_space_iterator(), begin(), contains(), contains_glued_hub(), contains_hub(), contains_unglued_hub(), ct(), end(), get_id_space(), get_id_space_iterator(), glued_hub_pod(), host(), hub_pod(), index(), is_done(), is_persistent(), next(), next_id_space(), only_persistent(), operator=(), operator==(), pod(), release_id_space(), release_id_space_iterator(), reset(), and unglued_hub_pod().
|
protected |
The index space family.
Definition at line 158 of file index_space_family_iterator.h.
Referenced by hub_id_space(), id_spaces(), name(), next(), operator=(), operator==(), and reset().
|
protected |
The stl iterator over the intervals.
Definition at line 163 of file index_space_family_iterator.h.
Referenced by next(), operator=(), operator==(), and reset().