Main Page | Class Hierarchy | Alphabetical List | Class List | File List | Class Members | File Members

vtkSequenceContainer.h

Go to the documentation of this file.
00001 /* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*-
00002  *
00003  * $Id: vtkSequenceContainer.h,v 1.4 2005/06/24 23:17:16 xpxqx Exp $
00004  *
00005  * Copyright (c) 2005 Sean McInerney
00006  * All rights reserved.
00007  *
00008  * See Copyright.txt or http://vtkcontainers.sourceforge.net/Copyright.html
00009  * for details.
00010  *
00011  *    This software is distributed WITHOUT ANY WARRANTY; without even 
00012  *    the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR 
00013  *    PURPOSE.  See the above copyright notice for more information.
00014  *
00015  */
00016 #ifndef VTK_SEQUENCE_CONTAINER_H_
00017 #  define VTK_SEQUENCE_CONTAINER_H_
00018 #  include "vtkContainer.h"
00019 #  include "vtkSequenceIterator.h" // Covariant return type.
00020 
00021 class vtkObjectBaseComparison;
00022 
00041 class VTK_CONTAINERS_EXPORT vtkSequenceContainer
00042   : public vtkContainer
00043 {
00044 public:
00045   vtkTypeRevisionMacro (vtkSequenceContainer, vtkContainer);
00046   void PrintSelf (ostream&, vtkIndent);
00047 
00052   virtual int           Swap (vtkSequenceContainer* container) = 0;
00053 
00058   virtual int           Copy (vtkSequenceContainer* container) = 0;
00059 
00066   virtual vtkObjectBase*        At (vtkIdType position) const { return NULL; }
00067 
00081   virtual int           Insert (vtkIdType       position,
00082                                 vtkObjectBase*  item) = 0;
00083 
00099   virtual int           Insert (vtkIdType             position,
00100                                 vtkSequenceContainer* sequence) = 0;
00101 
00119   virtual int           Insert (vtkIdType             position,
00120                                 vtkSequenceContainer* sequence,
00121                                 vtkIdType             seqBeg,
00122                                 vtkIdType             seqEnd) = 0;
00123 
00128   virtual int           Assign (vtkIdType      position,
00129                                 vtkObjectBase* item) = 0;
00130 
00135   virtual int           PushFront (vtkObjectBase* item) = 0;
00136 
00142   virtual int           PopFront (void) = 0;
00143 
00148   virtual int           PushBack (vtkObjectBase* item) = 0;
00149 
00155   virtual int           PopBack (void) = 0;
00156 
00161   virtual int           Erase (vtkIdType position) = 0;
00162 
00167   virtual int           Erase (vtkIdType pos1, vtkIdType pos2) = 0;
00168 
00173   virtual int           Erase (vtkObjectBase* item) = 0;
00174 
00179   virtual int           Clear (vtkObjectBase* item) = 0;
00180 
00185   virtual vtkIdType     Find (vtkObjectBase* item) const { return -1; }
00186 
00191   virtual int           Reverse (void) = 0;
00192 
00199   virtual int           Reverse (vtkIdType pos1, vtkIdType pos2) = 0;
00200 
00205   virtual int           Sort (void) = 0;
00206 
00213   virtual int           Unique (void) = 0;
00214 
00221   virtual int           Rotate (vtkIdType index) = 0;
00222 
00229   virtual int           Shuffle (void) = 0;
00230 
00232   virtual vtkSequenceIterator* CreateIterator (void) = 0;
00233 
00234 protected:
00235   vtkSequenceContainer (void);
00236   ~vtkSequenceContainer();
00237 
00238 private:
00239   //BTX
00242   int Swap (vtkContainer* a)
00243     { return this->Swap(static_cast<vtkSequenceContainer*>(a)); }
00244   int Copy (vtkContainer* a)
00245     { return this->Copy(static_cast<vtkSequenceContainer*>(a)); }
00247   //ETX
00248 
00249 private:
00255   vtkSequenceContainer (const vtkSequenceContainer&);
00256   void operator= (const vtkSequenceContainer&);
00258 };
00259 
00260 #endif /* VTK_SEQUENCE_CONTAINER_H_ */
00261 /* 
00262  * End of: $Id: vtkSequenceContainer.h,v 1.4 2005/06/24 23:17:16 xpxqx Exp $.
00263  * 
00264  */

Generated on Thu Jul 14 14:39:40 2005 for vtkContainers by doxygen 1.3.6