Base: make getAttribute template

This commit is contained in:
Benjamin Bræstrup Sayoc
2025-02-25 20:32:11 +01:00
parent 7f49550dee
commit 2b1aec0041
64 changed files with 834 additions and 675 deletions

View File

@@ -48,9 +48,9 @@ void ExternalGeometryExtension::restoreAttributes(Base::XMLReader& reader)
{
Part::GeometryPersistenceExtension::restoreAttributes(reader);
Ref = reader.getAttribute("Ref", "");
RefIndex = reader.getAttributeAsInteger("RefIndex", "-1");
Flags = FlagType(reader.getAttributeAsUnsigned("Flags", "0"));
Ref = reader.getAttribute<const char*>("Ref", "");
RefIndex = reader.getAttribute<long>("RefIndex", -1);
Flags = FlagType(reader.getAttribute<unsigned long>("Flags", 0));
}
void ExternalGeometryExtension::saveAttributes(Base::Writer& writer) const