Main Page | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Class Members | File Members | Related Pages

vtkDataObjectAlgorithm.h

Go to the documentation of this file.
00001 /*=========================================================================
00002 
00003   Program:   Visualization Toolkit
00004   Module:    $RCSfile: vtkDataObjectAlgorithm.h,v $
00005 
00006   Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
00007   All rights reserved.
00008   See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
00009 
00010      This software is distributed WITHOUT ANY WARRANTY; without even
00011      the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
00012      PURPOSE.  See the above copyright notice for more information.
00013 
00014 =========================================================================*/
00036 #ifndef __vtkDataObjectAlgorithm_h
00037 #define __vtkDataObjectAlgorithm_h
00038 
00039 #include "vtkAlgorithm.h"
00040 #include "vtkDataObject.h" // makes things a bit easier
00041 
00042 class vtkDataSet;
00043 class vtkDataObject;
00044 
00045 class VTK_FILTERING_EXPORT vtkDataObjectAlgorithm : public vtkAlgorithm
00046 {
00047 public:
00048   static vtkDataObjectAlgorithm *New();
00049   vtkTypeRevisionMacro(vtkDataObjectAlgorithm,vtkAlgorithm);
00050   void PrintSelf(ostream& os, vtkIndent indent);
00051 
00053 
00054   vtkDataObject* GetOutput();
00055   vtkDataObject* GetOutput(int);
00056   virtual void SetOutput(vtkDataObject* d);
00058 
00060 
00061   virtual int ProcessRequest(vtkInformation*,
00062                              vtkInformationVector**,
00063                              vtkInformationVector*);
00065 
00066   // this method is not recommended for use, but lots of old style filters
00067   // use it
00068   vtkDataObject* GetInput();
00069   vtkDataObject *GetInput(int port);
00070 
00072 
00079   void SetInput(vtkDataObject *);
00080   void SetInput(int, vtkDataObject*);
00082 
00084 
00088   void AddInput(vtkDataObject *);
00089   void AddInput(int, vtkDataObject*);
00091 
00092 protected:
00093   vtkDataObjectAlgorithm();
00094   ~vtkDataObjectAlgorithm();
00095 
00096   // convenience method
00097   virtual int RequestInformation(vtkInformation* request,
00098                                  vtkInformationVector** inputVector,
00099                                  vtkInformationVector* outputVector);
00100 
00102 
00104   virtual int RequestData(vtkInformation* request,
00105                           vtkInformationVector** inputVector,
00106                           vtkInformationVector* outputVector);
00108 
00110 
00112   virtual int RequestUpdateExtent(vtkInformation*,
00113                                   vtkInformationVector**,
00114                                   vtkInformationVector*)
00115     {
00116       return 1;
00117     };
00119 
00124   int UpdateExtentIsEmpty(vtkDataObject *output);
00125 
00127 
00128   virtual void ExecuteData(vtkDataObject *output);
00129   virtual void Execute();
00131 
00132   // see algorithm for more info
00133   virtual int FillOutputPortInformation(int port, vtkInformation* info);
00134   virtual int FillInputPortInformation(int port, vtkInformation* info);
00135 
00136 private:
00137   vtkDataObjectAlgorithm(const vtkDataObjectAlgorithm&);  // Not implemented.
00138   void operator=(const vtkDataObjectAlgorithm&);  // Not implemented.
00139 };
00140 
00141 #endif

Generated on Mon Jan 21 23:07:18 2008 for VTK by  doxygen 1.4.3-20050530