OGS
ProcessLib::LIE::anonymous_namespace{PostUtils.cpp} Namespace Reference

Functions

bool includesNodeID (std::vector< MeshLib::Node * > const &vec_nodes, std::size_t node_id)
 
std::vector< int > const & getMaterialIdsForNode (std::vector< std::pair< std::size_t, std::vector< int > > > const &vec_nodeID_matIDs, std::size_t nodeID)
 

Function Documentation

◆ getMaterialIdsForNode()

std::vector< int > const & ProcessLib::LIE::anonymous_namespace{PostUtils.cpp}::getMaterialIdsForNode ( std::vector< std::pair< std::size_t, std::vector< int > > > const & vec_nodeID_matIDs,
std::size_t nodeID )

Definition at line 31 of file PostUtils.cpp.

35{
36 auto itr =
37 std::find_if(vec_nodeID_matIDs.begin(), vec_nodeID_matIDs.end(),
38 [&](std::pair<std::size_t, std::vector<int>> const& entry)
39 { return entry.first == nodeID; });
40 assert(itr != vec_nodeID_matIDs.end());
41 return itr->second;
42};

References getMaterialIdsForNode().

Referenced by getMaterialIdsForNode().

◆ includesNodeID()

bool ProcessLib::LIE::anonymous_namespace{PostUtils.cpp}::includesNodeID ( std::vector< MeshLib::Node * > const & vec_nodes,
std::size_t node_id )

Definition at line 23 of file PostUtils.cpp.

25{
26 return std::any_of(vec_nodes.begin(), vec_nodes.end(),
27 [&](MeshLib::Node const* node)
28 { return node->getID() == node_id; });
29}

References includesNodeID().

Referenced by includesNodeID().