Main Page Class Hierarchy Alphabetical List Compound List File List Compound Members File Members Related Pages

# vtkXMLReader Class Reference

`#include <vtkXMLReader.h>`

Inheritance diagram for vtkXMLReader:

[legend]
Collaboration diagram for vtkXMLReader:

[legend]
List of all members.

## Detailed Description

Superclass for VTK's XML format readers.

Date:
  2002/11/27 00:16:04

Revision:
  1.3

vtkXMLReader uses vtkXMLDataParser to parse a VTK XML input file. Concrete subclasses then traverse the parsed file structure and extract data.

Created by:
  - King, Brad

CVS contributions (if > 5%):
  - King, Brad (96%)

CVS logs (CVSweb):
  - .`cxx` (`/IO/vtkXMLReader.cxx)`
  - .`h` (`/IO/vtkXMLReader.h)`

Definition at line 50 of file vtkXMLReader.h.

## Public Types
typedef vtkSource | Superclass
## Public Methods
virtual const char * | GetClassName ()
virtual int | IsA (const char *type)
void | PrintSelf (ostream &os, vtkIndent indent)
virtual int | CanReadFile (const char *name)
vtkDataSet * | GetOutputAsDataSet ()
virtual void | SetFileName (const char *)
virtual char * | GetFileName ()
virtual vtkDataArraySelection * | GetPointDataArraySelection ()
virtual vtkDataArraySelection * | GetCellDataArraySelection ()
int | GetNumberOfPointArrays ()
int | GetNumberOfCellArrays ()
const char * | GetPointArrayName (int index)
const char * | GetCellArrayName (int index)
int | GetPointArrayStatus (const char *name)
int | GetCellArrayStatus (const char *name)
void | SetPointArrayStatus (const char *name, int status)
void | SetCellArrayStatus (const char *name, int status)
## Static Public Methods
int | IsTypeOf (const char *type)
vtkXMLReader * | SafeDownCast (vtkObject *o)
## Protected Methods
| vtkXMLReader ()
| ~vtkXMLReader ()
void | ExecuteInformation ()
void | ExecuteData (vtkDataObject *output)
virtual void | ReadXMLInformation ()
virtual void | ReadXMLData ()
virtual const char * | GetDataSetName ()=0
virtual int | CanReadFileVersion (int major, int minor)
virtual void | SetupEmptyOutput ()=0
virtual void | SetupOutputInformation ()
virtual void | SetupOutputData ()
virtual int | ReadPrimaryElement (vtkXMLDataElement *ePrimary)
int | ReadVTKFile (vtkXMLDataElement *eVTKFile)
vtkDataArray * | CreateDataArray (vtkXMLDataElement *da)
int | OpenVTKFile ()
void | CloseVTKFile ()
void | CreateXMLParser ()
void | DestroyXMLParser ()
void | SetupCompressor (const char *type)
int | CanReadFileVersionString (const char *version)
int | IntersectExtents (int *extent1, int *extent2, int *result)
int | Min (int a, int b)
int | Max (int a, int b)
void | ComputeDimensions (int *extent, int *dimensions, int isPoint)
void | ComputeIncrements (int *extent, int *increments, int isPoint)
unsigned int | GetStartTuple (int *extent, int *increments, int i, int j, int k)
void | ReadAttributeIndices (vtkXMLDataElement *eDSA, vtkDataSetAttributes *dsa)
char ** | CreateStringArray (int numStrings)
void | DestroyStringArray (int numStrings, char **strings)
void | SetDataArraySelections (vtkXMLDataElement *eDSA, vtkDataArraySelection *sel)
int | PointDataArrayIsEnabled (vtkXMLDataElement *ePDA)
int | CellDataArrayIsEnabled (vtkXMLDataElement *eCDA)
## Static Protected Methods
void | SelectionModifiedCallback (vtkObject *caller, unsigned long eid, void *clientdata, void *calldata)
## Protected Attributes
vtkXMLDataParser * | XMLParser
char * | FileName
ifstream * | FileStream
vtkDataArraySelection * | PointDataArraySelection
vtkDataArraySelection * | CellDataArraySelection
vtkCallbackCommand * | SelectionObserver
int | InformationError
int | DataError

## Member Typedef Documentation

typedef vtkSource vtkXMLReader::Superclass

| Reimplemented from vtkSource. Reimplemented in vtkXMLDataReader, vtkXMLImageDataReader, vtkXMLPDataReader, vtkXMLPImageDataReader, vtkXMLPolyDataReader, vtkXMLPPolyDataReader, vtkXMLPRectilinearGridReader, vtkXMLPStructuredDataReader, vtkXMLPStructuredGridReader, vtkXMLPUnstructuredDataReader, vtkXMLPUnstructuredGridReader, vtkXMLRectilinearGridReader, vtkXMLStructuredDataReader, vtkXMLStructuredGridReader, vtkXMLUnstructuredDataReader, and vtkXMLUnstructuredGridReader. Definition at line 53 of file vtkXMLReader.h.

## Constructor & Destructor Documentation

vtkXMLReader::vtkXMLReader | ( |  | ) | `[protected]`

vtkXMLReader::~vtkXMLReader | ( |  | ) | `[protected]`

## Member Function Documentation

virtual const char* vtkXMLReader::GetClassName | ( |  | ) | `[virtual]`

| Reimplemented from vtkSource. Reimplemented in vtkXMLDataReader, vtkXMLImageDataReader, vtkXMLPDataReader, vtkXMLPImageDataReader, vtkXMLPolyDataReader, vtkXMLPPolyDataReader, vtkXMLPRectilinearGridReader, vtkXMLPStructuredDataReader, vtkXMLPStructuredGridReader, vtkXMLPUnstructuredDataReader, vtkXMLPUnstructuredGridReader, vtkXMLRectilinearGridReader, vtkXMLStructuredDataReader, vtkXMLStructuredGridReader, vtkXMLUnstructuredDataReader, and vtkXMLUnstructuredGridReader.

int vtkXMLReader::IsTypeOf | ( | const char * | type | ) | `[static]`

| Return 1 if this class type is the same type of (or a subclass of) the named class. Returns 0 otherwise. This method works in combination with vtkTypeRevisionMacro found in vtkSetGet.h. Reimplemented from vtkSource. Reimplemented in vtkXMLDataReader, vtkXMLImageDataReader, vtkXMLPDataReader, vtkXMLPImageDataReader, vtkXMLPolyDataReader, vtkXMLPPolyDataReader, vtkXMLPRectilinearGridReader, vtkXMLPStructuredDataReader, vtkXMLPStructuredGridReader, vtkXMLPUnstructuredDataReader, vtkXMLPUnstructuredGridReader, vtkXMLRectilinearGridReader, vtkXMLStructuredDataReader, vtkXMLStructuredGridReader, vtkXMLUnstructuredDataReader, and vtkXMLUnstructuredGridReader.

virtual int vtkXMLReader::IsA | ( | const char * | type | ) | `[virtual]`

| Return 1 if this class is the same type of (or a subclass of) the named class. Returns 0 otherwise. This method works in combination with vtkTypeRevisionMacro found in vtkSetGet.h. Reimplemented from vtkSource. Reimplemented in vtkXMLDataReader, vtkXMLImageDataReader, vtkXMLPDataReader, vtkXMLPImageDataReader, vtkXMLPolyDataReader, vtkXMLPPolyDataReader, vtkXMLPRectilinearGridReader, vtkXMLPStructuredDataReader, vtkXMLPStructuredGridReader, vtkXMLPUnstructuredDataReader, vtkXMLPUnstructuredGridReader, vtkXMLRectilinearGridReader, vtkXMLStructuredDataReader, vtkXMLStructuredGridReader, vtkXMLUnstructuredDataReader, and vtkXMLUnstructuredGridReader.

vtkXMLReader* vtkXMLReader::SafeDownCast | ( | vtkObject * | o | ) | `[static]`

| Reimplemented from vtkSource. Reimplemented in vtkXMLDataReader, vtkXMLImageDataReader, vtkXMLPDataReader, vtkXMLPImageDataReader, vtkXMLPolyDataReader, vtkXMLPPolyDataReader, vtkXMLPRectilinearGridReader, vtkXMLPStructuredDataReader, vtkXMLPStructuredGridReader, vtkXMLPUnstructuredDataReader, vtkXMLPUnstructuredGridReader, vtkXMLRectilinearGridReader, vtkXMLStructuredDataReader, vtkXMLStructuredGridReader, vtkXMLUnstructuredDataReader, and vtkXMLUnstructuredGridReader.

void vtkXMLReader::PrintSelf | ( | ostream & | os,
|  | vtkIndent | indent
| ) | `[virtual]`

| Methods invoked by print to print information about the object including superclasses. Typically not called by the user (use Print() instead) but used in the hierarchical print process to combine the output of several classes. Reimplemented from vtkSource. Reimplemented in vtkXMLDataReader, vtkXMLImageDataReader, vtkXMLPDataReader, vtkXMLPImageDataReader, vtkXMLPolyDataReader, vtkXMLPPolyDataReader, vtkXMLPRectilinearGridReader, vtkXMLPStructuredDataReader, vtkXMLPStructuredGridReader, vtkXMLPUnstructuredDataReader, vtkXMLPUnstructuredGridReader, vtkXMLRectilinearGridReader, vtkXMLStructuredDataReader, vtkXMLStructuredGridReader, vtkXMLUnstructuredDataReader, and vtkXMLUnstructuredGridReader.

virtual void vtkXMLReader::SetFileName | ( | const char * |  | ) | `[virtual]`

| Get/Set the name of the input file.

virtual char* vtkXMLReader::GetFileName | ( |  | ) | `[virtual]`

| Get/Set the name of the input file.

virtual int vtkXMLReader::CanReadFile | ( | const char * | name | ) | `[virtual]`

| Test whether the file with the given name can be read by this reader.

vtkDataSet* vtkXMLReader::GetOutputAsDataSet | ( |  | ) |

| Get the output as a vtkDataSet pointer.

virtual vtkDataArraySelection* vtkXMLReader::GetPointDataArraySelection | ( |  | ) | `[virtual]`

| Get the data array selection tables used to configure which data arrays are loaded by the reader.

virtual vtkDataArraySelection* vtkXMLReader::GetCellDataArraySelection | ( |  | ) | `[virtual]`

| Get the data array selection tables used to configure which data arrays are loaded by the reader.

int vtkXMLReader::GetNumberOfPointArrays | ( |  | ) |

| Get the number of point or cell arrays available in the input.

int vtkXMLReader::GetNumberOfCellArrays | ( |  | ) |

| Get the number of point or cell arrays available in the input.

const char* vtkXMLReader::GetPointArrayName | ( | int | index | ) |

| Get the name of the point or cell array with the given index in the input.

const char* vtkXMLReader::GetCellArrayName | ( | int | index | ) |

| Get the name of the point or cell array with the given index in the input.

int vtkXMLReader::GetPointArrayStatus | ( | const char * | name | ) |

| Get/Set whether the point or cell array with the given name is to be read.

int vtkXMLReader::GetCellArrayStatus | ( | const char * | name | ) |

| Get/Set whether the point or cell array with the given name is to be read.

void vtkXMLReader::SetPointArrayStatus | ( | const char * | name,
|  | int | status
| ) |

| Get/Set whether the point or cell array with the given name is to be read.

void vtkXMLReader::SetCellArrayStatus | ( | const char * | name,
|  | int | status
| ) |

| Get/Set whether the point or cell array with the given name is to be read.

void vtkXMLReader::ExecuteInformation | ( |  | ) | `[protected, virtual]`

| Reimplemented from vtkSource.

void vtkXMLReader::ExecuteData | ( | vtkDataObject * | output | ) | `[protected]`

virtual void vtkXMLReader::ReadXMLInformation | ( |  | ) | `[protected, virtual]`

| Reimplemented in vtkXMLPDataReader.

virtual void vtkXMLReader::ReadXMLData | ( |  | ) | `[protected, virtual]`

| Reimplemented in vtkXMLPStructuredDataReader, vtkXMLPUnstructuredDataReader, vtkXMLStructuredDataReader, and vtkXMLUnstructuredDataReader.

virtual const char* vtkXMLReader::GetDataSetName | ( |  | ) | `[protected, pure virtual]`

| Implemented in vtkXMLImageDataReader, vtkXMLPImageDataReader, vtkXMLPolyDataReader, vtkXMLPPolyDataReader, vtkXMLPRectilinearGridReader, vtkXMLPStructuredGridReader, vtkXMLPUnstructuredGridReader, vtkXMLRectilinearGridReader, vtkXMLStructuredGridReader, and vtkXMLUnstructuredGridReader.

virtual int vtkXMLReader::CanReadFileVersion | ( | int | major,
|  | int | minor
| ) | `[protected, virtual]`

virtual void vtkXMLReader::SetupEmptyOutput | ( |  | ) | `[protected, pure virtual]`

| Implemented in vtkXMLPStructuredDataReader, vtkXMLPUnstructuredDataReader, vtkXMLStructuredDataReader, and vtkXMLUnstructuredDataReader.

virtual void vtkXMLReader::SetupOutputInformation | ( |  | ) | `[protected, virtual]`

| Reimplemented in vtkXMLDataReader, vtkXMLImageDataReader, vtkXMLPDataReader, vtkXMLPImageDataReader, vtkXMLPRectilinearGridReader, vtkXMLPStructuredGridReader, vtkXMLPUnstructuredDataReader, vtkXMLRectilinearGridReader, vtkXMLStructuredGridReader, and vtkXMLUnstructuredDataReader.

virtual void vtkXMLReader::SetupOutputData | ( |  | ) | `[protected, virtual]`

| Reimplemented in vtkXMLDataReader, vtkXMLPDataReader, vtkXMLPolyDataReader, vtkXMLPPolyDataReader, vtkXMLPRectilinearGridReader, vtkXMLPStructuredGridReader, vtkXMLPUnstructuredDataReader, vtkXMLPUnstructuredGridReader, vtkXMLRectilinearGridReader, vtkXMLStructuredGridReader, vtkXMLUnstructuredDataReader, and vtkXMLUnstructuredGridReader.

virtual int vtkXMLReader::ReadPrimaryElement | ( | vtkXMLDataElement * | ePrimary | ) | `[protected, virtual]`

| Reimplemented in vtkXMLDataReader, vtkXMLImageDataReader, vtkXMLPDataReader, vtkXMLPImageDataReader, vtkXMLPRectilinearGridReader, vtkXMLPStructuredDataReader, vtkXMLPStructuredGridReader, vtkXMLPUnstructuredDataReader, and vtkXMLStructuredDataReader.

int vtkXMLReader::ReadVTKFile | ( | vtkXMLDataElement * | eVTKFile | ) | `[protected]`

vtkDataArray* vtkXMLReader::CreateDataArray | ( | vtkXMLDataElement * | da | ) | `[protected]`

int vtkXMLReader::OpenVTKFile | ( |  | ) | `[protected]`

void vtkXMLReader::CloseVTKFile | ( |  | ) | `[protected]`

void vtkXMLReader::CreateXMLParser | ( |  | ) | `[protected]`

void vtkXMLReader::DestroyXMLParser | ( |  | ) | `[protected]`

void vtkXMLReader::SetupCompressor | ( | const char * | type | ) | `[protected]`

int vtkXMLReader::CanReadFileVersionString | ( | const char * | version | ) | `[protected]`

int vtkXMLReader::IntersectExtents | ( | int * | extent1,
|  | int * | extent2,
|  | int * | result
| ) | `[protected]`

int vtkXMLReader::Min | ( | int | a,
|  | int | b
| ) | `[protected]`

int vtkXMLReader::Max | ( | int | a,
|  | int | b
| ) | `[protected]`

void vtkXMLReader::ComputeDimensions | ( | int * | extent,
|  | int * | dimensions,
|  | int | isPoint
| ) | `[protected]`

void vtkXMLReader::ComputeIncrements | ( | int * | extent,
|  | int * | increments,
|  | int | isPoint
| ) | `[protected]`

unsigned int vtkXMLReader::GetStartTuple | ( | int * | extent,
|  | int * | increments,
|  | int | i,
|  | int | j,
|  | int | k
| ) | `[protected]`

void vtkXMLReader::ReadAttributeIndices | ( | vtkXMLDataElement * | eDSA,
|  | vtkDataSetAttributes * | dsa
| ) | `[protected]`

char** vtkXMLReader::CreateStringArray | ( | int | numStrings | ) | `[protected]`

void vtkXMLReader::DestroyStringArray | ( | int | numStrings,
|  | char ** | strings
| ) | `[protected]`

void vtkXMLReader::SetDataArraySelections | ( | vtkXMLDataElement * | eDSA,
|  | vtkDataArraySelection * | sel
| ) | `[protected]`

int vtkXMLReader::PointDataArrayIsEnabled | ( | vtkXMLDataElement * | ePDA | ) | `[protected]`

int vtkXMLReader::CellDataArrayIsEnabled | ( | vtkXMLDataElement * | eCDA | ) | `[protected]`

void vtkXMLReader::SelectionModifiedCallback | ( | vtkObject * | caller,
|  | unsigned long | eid,
|  | void * | clientdata,
|  | void * | calldata
| ) | `[static, protected]`

## Member Data Documentation

vtkXMLDataParser* vtkXMLReader::XMLParser`[protected]`

| Definition at line 172 of file vtkXMLReader.h.

char* vtkXMLReader::FileName`[protected]`

| Definition at line 175 of file vtkXMLReader.h.

ifstream* vtkXMLReader::FileStream`[protected]`

| Definition at line 178 of file vtkXMLReader.h.

vtkDataArraySelection* vtkXMLReader::PointDataArraySelection`[protected]`

| Definition at line 181 of file vtkXMLReader.h.

vtkDataArraySelection* vtkXMLReader::CellDataArraySelection`[protected]`

| Definition at line 182 of file vtkXMLReader.h.

vtkCallbackCommand* vtkXMLReader::SelectionObserver`[protected]`

| Definition at line 186 of file vtkXMLReader.h.

int vtkXMLReader::InformationError`[protected]`

| Definition at line 189 of file vtkXMLReader.h.

int vtkXMLReader::DataError`[protected]`

| Definition at line 192 of file vtkXMLReader.h.

The documentation for this class was generated from the following file:

- IO/vtkXMLReader.h