6 return Tuple(-1, -1, -1,
id);
23 throw std::runtime_error(
"Tuple switch: Invalid primitive type");
79 std::vector<std::vector<TypedAttributeHandle<int64_t>>> handles(0);
A Curiously Recurring Template Pattern shim to enable generic specialization of functions.
void set_capacities(std::vector< int64_t > capacities)
int64_t capacity(PrimitiveType type) const
read in the m_capacities return the upper bound for the number of entities of the given dimension
virtual bool is_valid(const Tuple &tuple) const
check validity of tuple including its hash
void reserve_attributes_to_fit()
reserve space for all attributes data types for all dimensional simplices
const attribute::Accessor< char > get_flag_accessor(PrimitiveType type) const
std::vector< Tuple > orient_vertices(const Tuple &tuple) const override
Tuple vertex_tuple_from_id(int64_t id) const
Tuple tuple_from_id(const PrimitiveType type, const int64_t gid) const override
internal function that returns the tuple of requested type, and has the global index cid
bool is_boundary(const simplex::Simplex &tuple) const
check if a simplex lies on a boundary or not
Tuple switch_tuple(const Tuple &tuple, PrimitiveType type) const override
switch the orientation of the Tuple of the given dimension
bool is_valid(const Tuple &tuple) const final override
check validity of tuple including its hash
std::vector< std::vector< TypedAttributeHandle< int64_t > > > connectivity_attributes() const override
Returns a vector of vectors of attribute handles.
bool is_ccw(const Tuple &tuple) const override
TODO this needs dimension?
bool is_boundary_vertex(const Tuple &tuple) const
void initialize(int64_t count)
A CachingAccessor that uses tuples for accessing attributes instead of indices.
CachingBaseType & index_access()
T & scalar_attribute(const int64_t index)