ParaView
vtkFileSeriesReader.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: ParaView
4  Module: vtkFileSeriesReader.h
5 
6  Copyright (c) Kitware, Inc.
7  All rights reserved.
8  See Copyright.txt or http://www.paraview.org/HTML/Copyright.html 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 /*
17  * Copyright 2008 Sandia Corporation.
18  * Under the terms of Contract DE-AC04-94AL85000, there is a non-exclusive
19  * license for use of this work by or on behalf of the
20  * U.S. Government. Redistribution and use in source and binary forms, with
21  * or without modification, are permitted provided that this Notice and any
22  * statement of authorship are reproduced on all copies.
23  */
24 
50 #ifndef vtkFileSeriesReader_h
51 #define vtkFileSeriesReader_h
52 
53 #include "vtkMetaReader.h"
54 #include "vtkPVVTKExtensionsDefaultModule.h" //needed for exports
55 
56 class vtkStringArray;
57 
58 struct vtkFileSeriesReaderInternals;
59 
60 class VTKPVVTKEXTENSIONSDEFAULT_EXPORT vtkFileSeriesReader : public vtkMetaReader
61 {
62 public:
63  static vtkFileSeriesReader* New();
65  void PrintSelf(ostream& os, vtkIndent indent);
66 
73  virtual int ProcessRequest(vtkInformation*, vtkInformationVector**, vtkInformationVector*);
74 
78  virtual int CanReadFile(const char* filename);
79 
84  virtual void AddFileName(const char* fname);
85 
89  virtual void RemoveAllFileNames();
90 
94  virtual unsigned int GetNumberOfFileNames();
95 
99  virtual const char* GetFileName(unsigned int idx);
100 
101  const char* GetCurrentFileName();
102 
104 
107  vtkGetMacro(UseMetaFile, int);
108  vtkSetMacro(UseMetaFile, int);
109  vtkBooleanMacro(UseMetaFile, int);
111 
113 
117  vtkGetMacro(IgnoreReaderTime, int);
118  vtkSetMacro(IgnoreReaderTime, int);
119  vtkBooleanMacro(IgnoreReaderTime, int);
121 
122 protected:
125 
126  virtual int RequestInformation(vtkInformation* request, vtkInformationVector** inputVector,
127  vtkInformationVector* outputVector);
128  virtual int RequestUpdateExtent(vtkInformation*, vtkInformationVector**, vtkInformationVector*);
129 
130  virtual int RequestUpdateTime(vtkInformation*, vtkInformationVector**, vtkInformationVector*)
131  {
132  return 1;
133  };
135  vtkInformation*, vtkInformationVector**, vtkInformationVector*)
136  {
137  return 1;
138  };
139  virtual int RequestData(vtkInformation* request, vtkInformationVector** inputVector,
140  vtkInformationVector* outputVector);
141 
142  virtual int FillOutputPortInformation(int port, vtkInformation* info);
143 
148  virtual int RequestInformationForInput(
149  int index, vtkInformation* request = NULL, vtkInformationVector* outputVector = NULL);
150 
155  virtual int ReadMetaDataFile(
156  const char* metafilename, vtkStringArray* filesToRead, int maxFilesToRead = VTK_INT_MAX);
157 
162 
166  virtual void UpdateMetaData();
167 
171  void ResetTimeRanges();
172 
173  // Add/Remove filenames without changing the MTime.
174  void RemoveAllFileNamesInternal();
175  void AddFileNameInternal(const char*);
176 
178 
179  int ChooseInput(vtkInformation*);
180 
181 private:
182  vtkFileSeriesReader(const vtkFileSeriesReader&) VTK_DELETE_FUNCTION;
183  void operator=(const vtkFileSeriesReader&) VTK_DELETE_FUNCTION;
184 
185  vtkFileSeriesReaderInternals* Internal;
186 };
187 
188 #endif
int UseMetaFile
True if use a meta-file, false otherwise.
static vtkMetaReader * New()
void PrintSelf(ostream &os, vtkIndent indent)
meta-reader to read file series
virtual int RequestUpdateTime(vtkInformation *, vtkInformationVector **, vtkInformationVector *)
virtual int FillOutputPortInformation(int port, vtkInformation *info)
Common functionality for meta-readers.
Definition: vtkMetaReader.h:33
virtual int RequestUpdateTimeDependentInformation(vtkInformation *, vtkInformationVector **, vtkInformationVector *)