VTK
|
00001 /*========================================================================= 00002 00003 Program: Visualization Toolkit 00004 Module: vtkGlobFileNames.h 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 =========================================================================*/ 00038 #ifndef __vtkGlobFileNames_h 00039 #define __vtkGlobFileNames_h 00040 00041 #include "vtkIOCoreModule.h" // For export macro 00042 #include "vtkObject.h" 00043 00044 class vtkStringArray; 00045 00046 class VTKIOCORE_EXPORT vtkGlobFileNames : public vtkObject 00047 { 00048 public: 00050 00051 vtkTypeMacro(vtkGlobFileNames,vtkObject); 00053 00055 static vtkGlobFileNames *New(); 00056 00058 virtual void PrintSelf(ostream& os, vtkIndent indent); 00059 00061 void Reset(); 00062 00064 00069 vtkSetStringMacro(Directory); 00070 vtkGetStringMacro(Directory); 00072 00077 int AddFileNames(const char* pattern); 00078 00080 00081 vtkSetMacro(Recurse, int); 00082 vtkBooleanMacro(Recurse, int); 00083 vtkGetMacro(Recurse, int); 00085 00087 int GetNumberOfFileNames(); 00088 00090 const char* GetNthFileName(int index); 00091 00093 00094 vtkGetObjectMacro(FileNames, vtkStringArray); 00096 00097 protected: 00099 00100 vtkSetStringMacro(Pattern); 00101 vtkGetStringMacro(Pattern); 00103 00104 vtkGlobFileNames(); 00105 ~vtkGlobFileNames(); 00106 00107 private: 00108 char* Directory; // Directory for search. 00109 char* Pattern; // Wildcard pattern 00110 int Recurse; // Recurse into subdirectories 00111 vtkStringArray *FileNames; // VTK array of files 00112 00113 private: 00114 vtkGlobFileNames(const vtkGlobFileNames&); // Not implemented. 00115 void operator=(const vtkGlobFileNames&); // Not implemented. 00116 }; 00117 00118 #endif