VTK
vtkSortDataArray.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkSortDataArray.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 =========================================================================*/
15 
16 /*
17  * Copyright 2003 Sandia Corporation.
18  * Under the terms of Contract DE-AC04-94AL85000, there is a non-exclusive
19  * license for use of this work by or on behalf of the
20  * U.S. Government. Redistribution and use in source and binary forms, with
21  * or without modification, are permitted provided that this Notice and any
22  * statement of authorship are reproduced on all copies.
23  */
24 
32 #ifndef __vtkSortDataArray_h
33 #define __vtkSortDataArray_h
34 
35 #include "vtkObject.h"
36 
37 class vtkIdList;
38 class vtkAbstractArray;
39 
41 {
42 public:
43  vtkTypeMacro(vtkSortDataArray, vtkObject);
44  static vtkSortDataArray *New();
45  virtual void PrintSelf(ostream &os, vtkIndent indent);
46 
48 
49  static void Sort(vtkIdList *keys);
50  static void Sort(vtkAbstractArray *keys);
52 
59  static void SortArrayByComponent( vtkAbstractArray* arr, int k );
60 
62 
65  static void Sort(vtkIdList *keys, vtkIdList *values);
66  static void Sort(vtkIdList *keys, vtkAbstractArray *values);
67  static void Sort(vtkAbstractArray *keys, vtkIdList *values);
68  static void Sort(vtkAbstractArray *keys, vtkAbstractArray *values);
70 
71 protected:
73  virtual ~vtkSortDataArray();
74 
75 private:
76  vtkSortDataArray(const vtkSortDataArray &); // Not implemented.
77  void operator=(const vtkSortDataArray &); // Not implemented.
78 };
79 
80 #endif //__vtkSortDataArray_h
abstract base class for most VTK objects
Definition: vtkObject.h:60
Abstract superclass for all arrays.
virtual void PrintSelf(ostream &os, vtkIndent indent)
a simple class to control print indentation
Definition: vtkIndent.h:37
list of point or cell ids
Definition: vtkIdList.h:34
#define VTK_COMMON_EXPORT
Provides several methods for sorting vtk arrays.
static vtkObject * New()