/usr/include/paraview/vtkCPProcessor.h is in paraview-dev 5.0.1+dfsg1-4.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 | /*=========================================================================
Program: ParaView
Module: vtkCPProcessor.h
Copyright (c) Kitware, Inc.
All rights reserved.
See Copyright.txt or http://www.paraview.org/HTML/Copyright.html for details.
This software is distributed WITHOUT ANY WARRANTY; without even
the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
PURPOSE. See the above copyright notice for more information.
=========================================================================*/
#ifndef vtkCPProcessor_h
#define vtkCPProcessor_h
#include "vtkObject.h"
#include "vtkPVCatalystModule.h" // For windows import/export of shared libraries
struct vtkCPProcessorInternals;
class vtkCPDataDescription;
class vtkCPPipeline;
class vtkMPICommunicatorOpaqueComm;
class vtkMultiProcessController;
/// @defgroup CoProcessing ParaView CoProcessing
/// The CoProcessing library is designed to be called from parallel
/// simulation codes to reduce the size of the information that is saved
/// while also keeping the important information available as results.
/// @ingroup CoProcessing
/// There are 3 distinct phases for the operation of a co-processor.\n
/// 1) Initialization -- set up for the run.\n
/// 2) Processing -- the run.\n
/// 3) Finalization -- clean up before exit.\n
/// The processing phase occurs repeatedly and is composed of two distinct steps,
/// namely 1) Configuration (see vtkCPProcessor::ProcessDataDescription) and
/// 2) Processing (see vtkCPProcessor::ProcessData).
///
/// Configuration step:\n
/// In the first step the Co-Processor implemntation is called with a
/// vtkDataDescription describing the data that the simulation can provide
/// This gives the Co-Processor implemntation a chance to identify what
/// (if any) of the available data it will process during this pass. By
/// default all of the avaible data is selected, so that if the Co-Processor
/// implementation does nothing it will receive all data during the Processing
/// step. The Co-Processor implementation should extract what ever meta-data
/// it will need (or alternatively can save a reference to the DataDescription),
/// during the Processing step.
///
/// Processing step:\n
/// In the second step the Co-Processor implementation is called with the
/// actual data that it has been asked to provide, if any. If no data was
/// selected during the Configuration Step than the priovided vtkDataObject
/// may be NULL.
class VTKPVCATALYST_EXPORT vtkCPProcessor : public vtkObject
{
public:
static vtkCPProcessor* New();
vtkTypeMacro(vtkCPProcessor,vtkObject);
void PrintSelf(ostream& os, vtkIndent indent);
/// Add in a pipeline that is externally configured. Returns 1 if
/// successful and 0 otherwise.
virtual int AddPipeline(vtkCPPipeline* pipeline);
/// Get the number of pipelines.
virtual int GetNumberOfPipelines();
/// Return a specific pipeline.
virtual vtkCPPipeline* GetPipeline(int which);
/// Remove pipelines.
virtual void RemovePipeline(vtkCPPipeline* pipeline);
virtual void RemoveAllPipelines();
/// Initialize the co-processor. Returns 1 if successful and 0
/// otherwise.
/// otherwise. If Catalyst is built with MPI then Initialize()
/// can also be called with a specific MPI communicator if
/// MPI_COMM_WORLD isn't the proper one. Catalyst is initialized
/// to use MPI_COMM_WORLD by default.
virtual int Initialize();
#ifndef __WRAP__
virtual int Initialize(vtkMPICommunicatorOpaqueComm& comm);
#endif
/// Configuration Step:
/// The coprocessor first determines if any coprocessing needs to be done
/// at this TimeStep/Time combination returning 1 if it does and 0
/// otherwise. If coprocessing does need to be performed this time step
/// it fills in the FieldNames array that the coprocessor requires
/// in order to fulfill all the coprocessing requests for this
/// TimeStep/Time combination.
virtual int RequestDataDescription(
vtkCPDataDescription* dataDescription);
/// Processing Step:
/// Provides the grid and the field data for the co-procesor to process.
/// Return value is 1 for success and 0 for failure.
virtual int CoProcess(vtkCPDataDescription* dataDescription);
/// Called after all co-processing is complete giving the Co-Processor
/// implementation an opportunity to clean up, before it is destroyed.
virtual int Finalize();
protected:
vtkCPProcessor();
virtual ~vtkCPProcessor();
/// Create a new instance of the InitializationHelper.
virtual vtkObject* NewInitializationHelper();
private:
vtkCPProcessor(const vtkCPProcessor&); // Not implemented
void operator=(const vtkCPProcessor&); // Not implemented
vtkCPProcessorInternals* Internal;
vtkObject* InitializationHelper;
static vtkMultiProcessController* Controller;
};
#endif
|