21 #include "SheafSystem/index_space_interval.h" 22 #include "SheafSystem/assert_contract.h" 23 #include "SheafSystem/index_space_family.h" 59 ensure(is_basic_query);
78 ensure(is_basic_query);
93 bool result = (
_begin <= xspace_id) && (xspace_id <
_end);
97 ensure(is_basic_query);
133 define_old_variable(
size_type old_id_spaces_end = xid_spaces.
end());
136 _begin = _id_spaces->end();
139 _id_spaces->insert_interval(*
this);
144 ensure(
begin() == old_id_spaces_end);
145 ensure(
end() == xid_spaces.
end());
163 ensure(is_basic_query);
183 static const std::string result(
"index_space_interval");
251 result = result && (
_end == lother.
_end);
273 ensure(is_basic_query);
292 ensure(is_basic_query);
365 ensure((*
this) == xother);
393 ensure(is_basic_query);
412 ensure(is_basic_query);
496 xos <<
"[" << xn.
begin() <<
", " << xn.
end() <<
"] " virtual bool contains_family(pod_type xspace_id) const
True if this collection contains the id space with family id xspace_id.
virtual pod_type local_scope(pod_type xspace_id) const
Id relative to this collection equivalent to the id space family id xspace_id.
virtual const std::string & class_name() const
The name of this class.
pod_type end() const
The ending index of the id spaces.
virtual const index_space_family & id_spaces() const
The id space family for this (const version).
virtual ~index_space_interval()
Destructor.
virtual bool is_ancestor_of(const any *other) const
Conformance test; true if other conforms to this.
virtual index_space_interval & operator=(const index_space_collection &xother)
Assignment operator.
virtual bool invariant() const
Class invariant.
virtual bool operator==(const index_space_collection &xother) const
True if this is equivalent to xother.
pod_index_type pod_type
The "plain old data" index type for this.
virtual pod_type family_scope(pod_type xlocal_id) const
Id relative to the id space family equivalent to the local id xlocal_id.
index_space_family * _id_spaces
The index space family of this collection.
index_space_interval()
Default constructor.
Abstract base class with useful features for all objects.
An implemenation of index_space_collection that adds an interface for the interval [begin()...
pod_type _begin
Beginning space id of this interval in the id space family scope.
A factory for instanting descendants of an abstract type T, given the class name of the descendant...
void new_state(index_space_family &xid_spaces, size_type xub)
Create a new id space interval in the id space family xid_spaces with upper bound xub...
unsigned long size_type
An unsigned integral type used to represent sizes and capacities.
pod_type _end
Ending space id of this interval in the id space family scope.
A collection of id space states. This is a virtual class with provides an interface for accessing the...
void disable_invariant_check() const
Disable invariant check. Intended for preventing recursive calls to invariant and for suppressing inv...
static factory< index_space_interval > & id_space_interval_factory()
A factory for making descendants of this class.
virtual bool supports_persistent_id_spaces() const
True, if this interval supports persistent id spaces.
bool invariant_check() const
True if invariant checking is enabled.
virtual index_space_interval * clone() const =0
Virtual constructor; create a new instance of the same type at thi.
SHEAF_DLL_SPEC std::ostream & operator<<(std::ostream &os, const dof_descriptor_array &p)
Insert dof_descriptor_array& p into ostream& os.
pod_type end() const
Ending space id of this interval in the id space family scope.
virtual bool contains(pod_type xlocal_id) const
True if this collection contains the id space with local id xlocal_id.
Factory and container for a family of id spaces.
virtual bool invariant() const
Class invariant.
SHEAF_DLL_SPEC bool is_valid(pod_index_type xpod_index)
True if an only if xpod_index is valid.
pod_type begin() const
Beginning space id of this interval in the id space family scope.
SHEAF_DLL_SPEC pod_index_type invalid_pod_index()
The invalid pod index value.
bool is_same_type(const any *other) const
True if other is the same type as this.
void enable_invariant_check() const
Enable invariant checking.
bool in_bounds(pod_type xspace_id) const
True if id xspace_id is in the bounds [begin(), end()).