MCPcopy Create free account
hub / github.com/ThatOpen/engine_web-ifc / PushDouble

Method PushDouble

src/cpp/web-ifc/parsing/IfcLoader.cpp:356–365  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

354 }
355
356 void IfcLoader::PushDouble(double input)
357 {
358 std::string numberString = std::format("{}", input);
359 size_t eLoc = numberString.find_first_of('e');
360 if (eLoc != std::string::npos) numberString[eLoc]='E';
361 else if (std::floor(input) == input) numberString+='.';
362 uint16_t length = numberString.size();
363 Push<uint16_t>((uint16_t)length);
364 Push((void*)numberString.c_str(), numberString.size());
365 }
366
367 void IfcLoader::PushInt(int input)
368 {

Callers 2

WriteValueFunction · 0.80
WriteSetFunction · 0.80

Calls 1

sizeMethod · 0.80

Tested by

no test coverage detected