00001 
00002 
00003 
00004 
00005 
00006 
00007 
00008 
00009 
00010 
00011 
00012 
00013 
00014 
00015 
00016 
00017 
00018 
00019 
00052 #ifndef __vtkRowQuery_h
00053 #define __vtkRowQuery_h
00054 
00055 #include "vtkObject.h"
00056 
00057 class vtkVariant;
00058 class vtkVariantArray;
00059 
00060 class VTK_IO_EXPORT vtkRowQuery : public vtkObject
00061 {
00062 public:
00063   vtkTypeMacro(vtkRowQuery, vtkObject);
00064   void PrintSelf(ostream& os, vtkIndent indent);
00065 
00068   virtual bool Execute() = 0;
00069 
00071   virtual int GetNumberOfFields() = 0;
00072 
00074   virtual const char* GetFieldName(int i) = 0;
00075 
00078   virtual int GetFieldType(int i) = 0;
00079 
00082   int GetFieldIndex(char* name);
00083 
00085   virtual bool NextRow() = 0;
00086 
00090   virtual bool IsActive() = 0;
00091 
00094   bool NextRow(vtkVariantArray* rowArray);
00095 
00097   virtual vtkVariant DataValue(vtkIdType c) = 0;
00098 
00100   virtual bool HasError() = 0;
00101   
00103   virtual const char* GetLastErrorText() = 0;
00104 
00106 
00111   vtkSetMacro(CaseSensitiveFieldNames, bool);
00112   vtkGetMacro(CaseSensitiveFieldNames, bool);
00113   vtkBooleanMacro(CaseSensitiveFieldNames, bool);
00115 
00116 protected:
00117   vtkRowQuery();
00118   ~vtkRowQuery();
00119   bool CaseSensitiveFieldNames;
00120 private:
00121   vtkRowQuery(const vtkRowQuery &); 
00122   void operator=(const vtkRowQuery &); 
00123 };
00124 
00125 #endif // __vtkRowQuery_h
00126