VTK  9.1.0
vtkArrayReader.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkArrayReader.h
5 
6 -------------------------------------------------------------------------
7  Copyright 2008 Sandia Corporation.
8  Under the terms of Contract DE-AC04-94AL85000 with Sandia Corporation,
9  the U.S. Government retains certain rights in this software.
10 -------------------------------------------------------------------------
11 
12  Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
13  All rights reserved.
14  See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
15 
16  This software is distributed WITHOUT ANY WARRANTY; without even
17  the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
18  PURPOSE. See the above copyright notice for more information.
19 
20 =========================================================================*/
21 
39 #ifndef vtkArrayReader_h
40 #define vtkArrayReader_h
41 
42 #include "vtkArrayDataAlgorithm.h"
43 #include "vtkIOCoreModule.h" // For export macro
44 #include "vtkStdString.h" // For vtkStdString
45 
46 class vtkArray;
47 
48 class VTKIOCORE_EXPORT vtkArrayReader : public vtkArrayDataAlgorithm
49 {
50 public:
51  static vtkArrayReader* New();
53  void PrintSelf(ostream& os, vtkIndent indent) override;
54 
56 
62 
64 
68  virtual void SetInputString(const vtkStdString& string);
71 
73 
76  vtkSetMacro(ReadFromInputString, bool);
77  vtkGetMacro(ReadFromInputString, bool);
78  vtkBooleanMacro(ReadFromInputString, bool);
80 
86  static vtkArray* Read(istream& stream);
87 
91  static vtkArray* Read(const vtkStdString& str);
92 
93 protected:
95  ~vtkArrayReader() override;
96 
98 
99  char* FileName;
102 
103 private:
104  vtkArrayReader(const vtkArrayReader&) = delete;
105  void operator=(const vtkArrayReader&) = delete;
106 };
107 
108 #endif
vtkStdString.h
vtkArrayDataAlgorithm.h
vtkArrayReader::ReadFromInputString
bool ReadFromInputString
Definition: vtkArrayReader.h:101
vtkInformationVector
Store zero or more vtkInformation instances.
Definition: vtkInformationVector.h:145
vtkArrayReader::Read
static vtkArray * Read(const vtkStdString &str)
Read an arbitrary array from a string.
vtkArrayReader::SetInputString
virtual void SetInputString(const vtkStdString &string)
The input string to parse.
vtkArrayReader::New
static vtkArrayReader * New()
vtkArrayReader::~vtkArrayReader
~vtkArrayReader() override
vtkArrayReader::PrintSelf
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
vtkArrayReader::InputString
vtkStdString InputString
Definition: vtkArrayReader.h:100
vtkIndent
a simple class to control print indentation
Definition: vtkIndent.h:113
vtkArrayReader
Reads sparse and dense vtkArray data written by vtkArrayWriter.
Definition: vtkArrayReader.h:49
vtkArrayDataAlgorithm
Superclass for algorithms that produce vtkArrayDatas as output.
Definition: vtkArrayDataAlgorithm.h:54
vtkArrayReader::vtkSetFilePathMacro
vtkSetFilePathMacro(FileName)
Set the filesystem location from which data will be read.
vtkArray
Abstract interface for N-dimensional arrays.
Definition: vtkArray.h:65
vtkArrayReader::vtkGetFilePathMacro
vtkGetFilePathMacro(FileName)
Set the filesystem location from which data will be read.
vtkArrayReader::FileName
char * FileName
Definition: vtkArrayReader.h:99
vtkArrayReader::vtkArrayReader
vtkArrayReader()
vtkArrayReader::RequestData
int RequestData(vtkInformation *, vtkInformationVector **, vtkInformationVector *) override
This is called by the superclass.
vtkInformation
Store vtkAlgorithm input/output information.
Definition: vtkInformation.h:183
vtkArrayReader::GetInputString
virtual vtkStdString GetInputString()
The input string to parse.
vtkStdString
Wrapper around std::string to keep symbols short.
Definition: vtkStdString.h:105
vtkArrayReader::Read
static vtkArray * Read(istream &stream)
Read an arbitrary array from a stream.