VTK  9.4.20241112
vtkDummyCommunicator.h
Go to the documentation of this file.
1// SPDX-FileCopyrightText: Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
2// SPDX-License-Identifier: BSD-3-Clause
3
16#ifndef vtkDummyCommunicator_h
17#define vtkDummyCommunicator_h
18
19#include "vtkCommunicator.h"
20#include "vtkParallelCoreModule.h" // For export macro
21
22VTK_ABI_NAMESPACE_BEGIN
23class VTKPARALLELCORE_EXPORT vtkDummyCommunicator : public vtkCommunicator
24{
25public:
28 void PrintSelf(ostream& os, vtkIndent indent) override;
29
31
35 int SendVoidArray(const void*, vtkIdType, int, int, int) override
36 {
37 vtkWarningMacro("There is no one to send to.");
38 return 0;
39 }
40 int ReceiveVoidArray(void*, vtkIdType, int, int, int) override
41 {
42 vtkWarningMacro("There is no one to receive from.");
43 return 0;
44 }
46
47protected:
50
51private:
53 void operator=(const vtkDummyCommunicator&) = delete;
54};
55
56VTK_ABI_NAMESPACE_END
57#endif // vtkDummyCommunicator_h
Used to send/receive messages in a multiprocess environment.
Dummy controller for single process applications.
~vtkDummyCommunicator() override
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
int SendVoidArray(const void *, vtkIdType, int, int, int) override
Since there is no one to communicate with, these methods just report an error.
static vtkDummyCommunicator * New()
int ReceiveVoidArray(void *, vtkIdType, int, int, int) override
Since there is no one to communicate with, these methods just report an error.
a simple class to control print indentation
Definition vtkIndent.h:108
int vtkIdType
Definition vtkType.h:315