VTK
vtkNewickTreeWriter.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkNewickTreeWriter.h
5 
6  Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
7  All rights reserved.
8  See Copyright.txt or http://www.kitware.com/Copyright.htm 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 =========================================================================*/
26 #ifndef vtkNewickTreeWriter_h
27 #define vtkNewickTreeWriter_h
28 
29 #include "vtkIOInfovisModule.h" // For export macro
30 #include "vtkDataWriter.h"
31 #include "vtkStdString.h" // For get/set ivars
32 
33 class vtkTree;
34 
35 class VTKIOINFOVIS_EXPORT vtkNewickTreeWriter : public vtkDataWriter
36 {
37 public:
38  static vtkNewickTreeWriter *New();
40  void PrintSelf(ostream& os, vtkIndent indent);
41 
43 
46  vtkTree* GetInput();
47  vtkTree* GetInput(int port);
49 
51 
58  vtkGetMacro(EdgeWeightArrayName, vtkStdString);
59  vtkSetMacro(EdgeWeightArrayName, vtkStdString);
61 
63 
70  vtkGetMacro(NodeNameArrayName, vtkStdString);
71  vtkSetMacro(NodeNameArrayName, vtkStdString);
73 
74 protected:
77 
78  void WriteData();
79 
84  void WriteVertex(ostream *fp, vtkTree* const input, vtkIdType vertex);
85 
87 
90 
93 
94 private:
95  vtkNewickTreeWriter(const vtkNewickTreeWriter&) VTK_DELETE_FUNCTION;
96  void operator=(const vtkNewickTreeWriter&) VTK_DELETE_FUNCTION;
97 };
98 
99 #endif
Wrapper around std::string to keep symbols short.
Definition: vtkStdString.h:47
write vtkTree data to Newick format.
vtkStdString NodeNameArrayName
Store vtkAlgorithm input/output information.
Abstract superclass for all arrays.
helper class for objects that write vtk data files
Definition: vtkDataWriter.h:45
void PrintSelf(ostream &os, vtkIndent indent)
Methods invoked by print to print information about the object including superclasses.
int vtkIdType
Definition: vtkType.h:287
a simple class to control print indentation
Definition: vtkIndent.h:39
vtkDataObject * GetInput()
vtkAbstractArray * EdgeWeightArray
virtual int FillInputPortInformation(int port, vtkInformation *info)
Fill the input port information objects for this algorithm.
vtkSetMacro(IgnoreDriverBugs, bool)
When set known driver bugs are ignored during driver feature detection.
static vtkDataWriter * New()
Created object with default header, ASCII format, and default names for scalars, vectors, tensors, normals, and texture coordinates.
vtkStdString EdgeWeightArrayName
vtkAbstractArray * NodeNameArray
A rooted tree data structure.
Definition: vtkTree.h:60
void WriteData()