Merge pull request #12023 from bgbsww/bgbsww-patch-30

Initial code of mapSubElement Test
This commit is contained in:
Chris Hennes
2024-01-22 16:02:00 -06:00
committed by GitHub
3 changed files with 154 additions and 1 deletions

View File

@@ -609,7 +609,7 @@ public:
void copyElementMap(const TopoShape & topoShape, const char *op=nullptr);
bool canMapElement(const TopoShape &other) const;
void mapSubElement(const TopoShape &other,const char *op=nullptr, bool forceHasher=false);
void mapSubElement(const std::vector<TopoShape> &shapes, const char *op);
void mapSubElement(const std::vector<TopoShape> &shapes, const char *op=nullptr);
bool hasPendingElementMap() const;

View File

@@ -376,6 +376,9 @@ void TopoShape::mapSubElementTypeForShape(const TopoShape& other,
}
std::ostringstream ss;
char elementType {shapeName(type)[0]};
if ( ! elementMap() ) {
FC_THROWM(NullShapeException, "No element map");
}
elementMap()->encodeElementName(elementType, name, ss, &sids, Tag, op, other.Tag);
elementMap()->setElementName(element, name, Tag, &sids);
}