10 #ifndef vtk_m_exec_internal_ErrorMessageBuffer_h
11 #define vtk_m_exec_internal_ErrorMessageBuffer_h
37 : MessageBuffer(nullptr)
38 , MessageBufferSize(0)
43 ErrorMessageBuffer(
char* messageBuffer,
vtkm::Id bufferSize)
44 : MessageBuffer(messageBuffer)
45 , MessageBufferSize(bufferSize)
49 VTKM_EXEC void RaiseError(
const char* message)
const
58 if (this->IsErrorRaised())
64 for (
vtkm::Id index = 0; index < this->MessageBufferSize; index++)
66 this->MessageBuffer[index] = message[index];
67 if (message[index] ==
'\0')
74 this->MessageBuffer[this->MessageBufferSize - 1] =
'\0';
79 if (this->MessageBufferSize > 0)
81 return (this->MessageBuffer[0] !=
'\0');
98 #endif // vtk_m_exec_internal_ErrorMessageBuffer_h