MCPcopy Create free account
hub / github.com/Kitware/VTK / WritePrimaryElementAttributes

Method WritePrimaryElementAttributes

IO/XML/vtkXMLWriter.cxx:3072–3090  ·  view source on GitHub ↗

------------------------------------------------------------------------------

Source from the content-addressed store, hash-verified

3070
3071//------------------------------------------------------------------------------
3072void vtkXMLWriter::WritePrimaryElementAttributes(ostream& os, vtkIndent indent)
3073{
3074 // Write the time step if any:
3075 if (this->NumberOfTimeSteps > 1)
3076 {
3077 // First thing allocate NumberOfTimeValues
3078 assert(this->NumberOfTimeValues == nullptr);
3079 this->NumberOfTimeValues = new vtkTypeInt64[this->NumberOfTimeSteps];
3080 os << indent << "TimeValues=\"\n";
3081
3082 std::string blankline = std::string(40, ' '); // enough room for precision
3083 for (int i = 0; i < this->NumberOfTimeSteps; i++)
3084 {
3085 this->NumberOfTimeValues[i] = os.tellp();
3086 os << blankline << "\n";
3087 }
3088 os << "\"";
3089 }
3090}
3091
3092//------------------------------------------------------------------------------
3093int vtkXMLWriter::WritePrimaryElement(ostream& os, vtkIndent indent)

Callers 1

WritePrimaryElementMethod · 0.95

Calls 2

assertFunction · 0.50
stringClass · 0.50

Tested by

no test coverage detected