VTK
dox/Common/vtkArrayCoordinates.h
Go to the documentation of this file.
00001 /*=========================================================================
00002 
00003   Program:   Visualization Toolkit
00004   Module:    vtkArrayCoordinates.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 
00047 #ifndef __vtkArrayCoordinates_h
00048 #define __vtkArrayCoordinates_h
00049 
00050 #include "vtkSystemIncludes.h"
00051 #include <vtksys/stl/vector>
00052 
00053 class VTK_COMMON_EXPORT vtkArrayCoordinates
00054 {
00055 public:
00058   vtkArrayCoordinates();
00059   
00061   explicit vtkArrayCoordinates(vtkIdType i);
00062   
00064   vtkArrayCoordinates(vtkIdType i, vtkIdType j);
00065   
00067   vtkArrayCoordinates(vtkIdType i, vtkIdType j, vtkIdType k);
00068 
00070   vtkIdType GetDimensions() const;
00071 
00075   void SetDimensions(vtkIdType dimensions);
00076   
00078   vtkIdType& operator[](vtkIdType i);
00079   
00081   const vtkIdType& operator[](vtkIdType i) const;  
00082 
00083   
00085   bool operator==(const vtkArrayCoordinates& rhs) const;
00086   
00088 
00089   bool operator!=(const vtkArrayCoordinates& rhs) const;
00090   VTK_COMMON_EXPORT friend ostream& operator<<(
00091     ostream& stream, const vtkArrayCoordinates& rhs);
00093   
00094 private:
00095   vtkstd::vector<vtkIdType> Storage;
00096 };
00097 
00098 #endif
00099