18 #include "libmesh/elem.h" 30 #ifdef MOOSE_KOKKOS_ENABLED 46 unsigned int comp = 0)
const;
62 unsigned int comp = 0)
const;
71 unsigned int comp = 0)
const;
97 return _id_mesh->maxElementID(elem_id_index);
105 return _id_mesh->minElementID(elem_id_index);
113 return _id_mesh->areElemIDsIdentical(id_name1, id_name2);
119 std::unordered_map<dof_id_type, std::set<dof_id_type>>
122 return _id_mesh->getElemIDMapping(id_name1, id_name2);
130 return _id_mesh->getAllElemIDs(elem_id_index);
138 const std::set<SubdomainID> & blks)
const 140 return _id_mesh->getElemIDsOnBlocks(elem_id_index, blks);
148 if (elem_id_index == elem->n_extra_integers())
149 return elem->subdomain_id();
151 return elem->get_extra_integer(elem_id_index);
bool areElemIDsIdentical(const std::string &id_name1, const std::string &id_name2) const
Whether two element integers are identical for all elements.
virtual const dof_id_type & getElementIDNeighbor(const std::string &id_parameter_name, unsigned int comp=0) const
Gets a neighbor element integer with a parameter of the object derived from this interface.
dof_id_type getElementID(const Elem *elem, unsigned int elem_id_index) const
Get an element integer for an element.
dof_id_type maxElementID(unsigned int elem_id_index) const
Return the maximum element ID for an element integer with its index.
std::shared_ptr< MooseMesh > & _id_mesh
References to the mesh and displaced mesh (currently in the ActionWarehouse)
virtual const dof_id_type & getElementIDNeighborByName(const std::string &id_name) const
Gets a neighbor element integer with the element integer name.
std::set< dof_id_type > getAllElemIDs(unsigned int elem_id_index) const
Return all the unique element IDs for an element integer with its index on the entire domain...
Every object that can be built by the factory should be derived from this class.
const std::string & _ei_name
Name of the object using this interface.
virtual unsigned int getElementIDIndex(const std::string &id_parameter_name, unsigned int comp=0) const
Gets index of an element integer with a parameter of the object derived from this interface...
virtual const dof_id_type & getElementIDByName(const std::string &id_name) const
Gets an element integer with the element integer name.
static InputParameters validParams()
const InputParameters & _obj_parameters
Reference to the object's input parameters.
virtual unsigned int getElementIDIndexByName(const std::string &id_name) const
Return the accessing integer for an extra element integer with its name.
bool hasElementID(const std::string &id_name) const
Whether mesh has an element integer with a given name.
virtual ~ElementIDInterface()
dof_id_type minElementID(unsigned int elem_id_index) const
Return the minimum element ID for an element integer with its index.
virtual const dof_id_type & getElementID(const std::string &id_parameter_name, unsigned int comp=0) const
Gets an element integer with a parameter of the object derived from this interface.
ElementIDInterface(const MooseObject *moose_object)
std::unordered_map< dof_id_type, std::set< dof_id_type > > getElemIDMapping(const std::string &id_name1, const std::string &id_name2) const
Get the mapping from IDs of one extra element integer to another given the two integer names...
std::set< dof_id_type > getElemIDsOnBlocks(unsigned int elem_id_index, const std::set< SubdomainID > &blks) const
Return all the unique element IDs for an extra element integer with its index on a set of subdomains...