VTK
dox/IO/Core/vtkArrayDataReader.h
Go to the documentation of this file.
00001 /*=========================================================================
00002 
00003   Program:   Visualization Toolkit
00004   Module:    vtkArrayDataReader.h
00005 
00006 -------------------------------------------------------------------------
00007   Copyright 2008 Sandia Corporation.
00008   Under the terms of Contract DE-AC04-94AL85000 with Sandia Corporation,
00009   the U.S. Government retains certain rights in this software.
00010 -------------------------------------------------------------------------
00011 
00012   Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
00013   All rights reserved.
00014   See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
00015 
00016      This software is distributed WITHOUT ANY WARRANTY; without even
00017      the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
00018      PURPOSE.  See the above copyright notice for more information.
00019 
00020 =========================================================================*/
00021 
00038 #ifndef __vtkArrayDataReader_h
00039 #define __vtkArrayDataReader_h
00040 
00041 #include "vtkIOCoreModule.h" // For export macro
00042 #include "vtkArrayDataAlgorithm.h"
00043 
00044 class VTKIOCORE_EXPORT vtkArrayDataReader :
00045   public vtkArrayDataAlgorithm
00046 {
00047 public:
00048   static vtkArrayDataReader* New();
00049   vtkTypeMacro(vtkArrayDataReader, vtkArrayDataAlgorithm);
00050   void PrintSelf(ostream& os, vtkIndent indent);
00051 
00053 
00054   vtkGetStringMacro(FileName);
00055   vtkSetStringMacro(FileName);
00057 
00059 
00062   virtual void SetInputString(const vtkStdString& string);
00063   virtual vtkStdString GetInputString();
00065 
00067 
00069   vtkSetMacro(ReadFromInputString, bool);
00070   vtkGetMacro(ReadFromInputString, bool);
00071   vtkBooleanMacro(ReadFromInputString, bool);
00073 
00076   static vtkArrayData* Read(istream& stream);
00077 
00079   static vtkArrayData* Read(vtkStdString str);
00080 
00081 protected:
00082   vtkArrayDataReader();
00083   ~vtkArrayDataReader();
00084 
00085   int RequestData(
00086     vtkInformation*,
00087     vtkInformationVector**,
00088     vtkInformationVector*);
00089 
00090   char* FileName;
00091   vtkStdString InputString;
00092   bool ReadFromInputString;
00093 
00094 private:
00095   vtkArrayDataReader(const vtkArrayDataReader&); // Not implemented
00096   void operator=(const vtkArrayDataReader&);   // Not implemented
00097 };
00098 
00099 #endif