/*========================================================================= Program: ShapeWorks: Particle-based Shape Correspondence & Visualization Module: $RCSfile: itkParticleContainer.h,v $ Date: $Date: 2011/03/24 01:17:33 $ Version: $Revision: 1.2 $ Author: $Author: wmartin $ Copyright (c) 2009 Scientific Computing and Imaging Institute. See ShapeWorksLicense.txt for details. This software is distributed WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the above copyright notices for more information.=========================================================================*/#ifndef __itkParticleContainer_h#define __itkParticleContainer_h#include"itkDataObject.h"#include"itkPoint.h"#include"itkWeakPointer.h"#include"itkCommand.h"#include"itkParticleAttribute.h"#include<map>namespaceitk{template<classT>classITK_EXPORTParticleContainer:publicDataObject{public:typedefTDataType;typedefParticleContainerSelf;typedefDataObjectSuperclass;typedefSmartPointer<Self>Pointer;typedefSmartPointer<constSelf>ConstPointer;typedefWeakPointer<constSelf>ConstWeakPointer;itkNewMacro(Self);// itkTypeMacro(ParticleContainer, ParticleAttribute);itkTypeMacro(ParticleContainer,DataObject);inlineT&operator[](size_tk){if(k>=data.size()){data.resize(k+1);}returndata[k];}inlineT&Get(size_tk){return(*this)[k];}unsignedlongintGetSize()const{returndata.size();}protected:ParticleContainer(){}voidPrintSelf(std::ostream&os,Indentindent)const{Superclass::PrintSelf(os,indent);os<<indent<<"ParticleContainer: "<<std::endl;}virtual~ParticleContainer(){};private:ParticleContainer(constSelf&);//purposely not implementedvoidoperator=(constSelf&);//purposely not implementedstd::vector<T>data;};}// end namespace itk//#if ITK_TEMPLATE_EXPLICIT//# include "Templates/itkParticleContainer+-.h"//#endif//#if ITK_TEMPLATE_TXX//# include "itkParticleContainer.txx"//#endif#endif