VTK
vtkPBGLGraphSQLReader.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkPBGLGraphSQLReader.h
5 
6  Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
7  All rights reserved.
8  See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
9 
10  This software is distributed WITHOUT ANY WARRANTY; without even
11  the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
12  PURPOSE. See the above copyright notice for more information.
13 
14 =========================================================================*/
15 /*----------------------------------------------------------------------------
16  Copyright (c) Sandia Corporation
17  See Copyright.txt or http://www.paraview.org/HTML/Copyright.html for details.
18 ----------------------------------------------------------------------------*/
43 #ifndef vtkPBGLGraphSQLReader_h
44 #define vtkPBGLGraphSQLReader_h
45 
46 #include "vtkInfovisParallelModule.h" // For export macro
47 #include "vtkGraphAlgorithm.h"
48 
49 class vtkSQLDatabase;
50 
51 #if !defined(VTK_LEGACY_REMOVE)
52 class VTKINFOVISPARALLEL_EXPORT vtkPBGLGraphSQLReader : public vtkGraphAlgorithm
53 {
54 public:
55  static vtkPBGLGraphSQLReader* New();
57  void PrintSelf(ostream& os, vtkIndent indent);
58 
60 
62  vtkSetMacro(Directed, bool);
63  vtkGetMacro(Directed, bool);
64  vtkBooleanMacro(Directed, bool);
66 
68 
69  virtual void SetDatabase(vtkSQLDatabase* db);
70  vtkGetObjectMacro(Database, vtkSQLDatabase);
72 
74 
75  vtkSetStringMacro(VertexTable);
76  vtkGetStringMacro(VertexTable);
78 
80 
81  vtkSetStringMacro(EdgeTable);
82  vtkGetStringMacro(EdgeTable);
84 
86 
88  vtkSetStringMacro(SourceField);
89  vtkGetStringMacro(SourceField);
91 
93 
95  vtkSetStringMacro(TargetField);
96  vtkGetStringMacro(TargetField);
98 
100 
101  vtkSetStringMacro(VertexIdField);
102  vtkGetStringMacro(VertexIdField);
104 
106 
107  static void GetRange(int rank, int total,
110 
112 
113  void SetDistributionUserData(int procs, vtkIdType verts)
114  { this->DistributionUserData[0] = procs;
115  this->DistributionUserData[1] = verts; }
117 
119 
122  { return this->DistributionUserData; }
124 
125 protected:
128 
129  bool Directed;
131  char* VertexTable;
132  char* EdgeTable;
133  char* SourceField;
134  char* TargetField;
136  vtkIdType DistributionUserData[2];
137 
138  virtual int RequestData(
142 
143  virtual int RequestDataObject(
147 
148 private:
149  vtkPBGLGraphSQLReader(const vtkPBGLGraphSQLReader&); // Not implemented
150  void operator=(const vtkPBGLGraphSQLReader&); // Not implemented
151 };
152 
153 #endif //VTK_LEGACY_REMOVE
154 #endif
155 
static vtkGraphAlgorithm * New()
Store vtkAlgorithm input/output information.
int vtkIdType
Definition: vtkType.h:275
Superclass for algorithms that produce only graph as output.
maintain a connection to an sql database
a simple class to control print indentation
Definition: vtkIndent.h:38
void PrintSelf(ostream &os, vtkIndent indent)
virtual int RequestDataObject(vtkInformation *request, vtkInformationVector **inputVector, vtkInformationVector *outputVector)
vtkIdType * GetDistributionUserData()
virtual int RequestData(vtkInformation *request, vtkInformationVector **inputVector, vtkInformationVector *outputVector)
read a vtkGraph from a database
Store zero or more vtkInformation instances.
void SetDistributionUserData(int procs, vtkIdType verts)