------------------------------------------------------------------------------
| 279 | |
| 280 | //------------------------------------------------------------------------------ |
| 281 | char* vtkXMLPDataObjectWriter::CreatePieceFileName(int index, const char* path) |
| 282 | { |
| 283 | std::ostringstream s; |
| 284 | if (path) |
| 285 | { |
| 286 | s << path; |
| 287 | } |
| 288 | s << this->FileNameBase; |
| 289 | if (this->UseSubdirectory) |
| 290 | { |
| 291 | s << "/" << this->FileNameBase; |
| 292 | } |
| 293 | s << "_" << index; |
| 294 | if (this->PieceFileNameExtension) |
| 295 | { |
| 296 | s << this->PieceFileNameExtension; |
| 297 | } |
| 298 | |
| 299 | size_t len = s.str().length(); |
| 300 | char* buffer = new char[len + 1]; |
| 301 | strncpy(buffer, s.str().c_str(), len); |
| 302 | buffer[len] = '\0'; |
| 303 | |
| 304 | return buffer; |
| 305 | } |
| 306 | |
| 307 | //------------------------------------------------------------------------------ |
| 308 | void vtkXMLPDataObjectWriter::SplitFileName() |
no test coverage detected