From 4fa58b99c003567d572c75a9749f705f02bbd67b Mon Sep 17 00:00:00 2001 From: Niels Dekker Date: Fri, 20 Sep 2024 16:39:47 +0200 Subject: [PATCH] STYLE: Remove SizeValueType template argument from VectorContainer uses The index type (`ElementIdentifier`) of `itk::VectorContainer` is already `itk::SizeValueType` by default. --- Modules/Core/Common/include/itkSTLConstContainerAdaptor.h | 2 +- Modules/Core/Common/include/itkVectorContainer.h | 2 +- Modules/Core/Transform/include/itkKernelTransform.h | 2 +- Modules/Filtering/ImageSources/include/itkGridImageSource.h | 2 +- Modules/IO/MeshVTK/include/itkVTKPolyDataMeshIO.h | 2 +- 5 files changed, 5 insertions(+), 5 deletions(-) diff --git a/Modules/Core/Common/include/itkSTLConstContainerAdaptor.h b/Modules/Core/Common/include/itkSTLConstContainerAdaptor.h index 670c38e3f7c..b9ef269e1b2 100644 --- a/Modules/Core/Common/include/itkSTLConstContainerAdaptor.h +++ b/Modules/Core/Common/include/itkSTLConstContainerAdaptor.h @@ -36,7 +36,7 @@ namespace itk * Here's a usage example of STLContainerAdaptor * \code - itk::STLConstContainerAdaptor> vecAdaptor(aContainer); + itk::STLConstContainerAdaptor> vecAdaptor(aContainer); const std::vector & vec = vecAdaptor.GetSTLContainerRef(); // do things with vec ... \endcode diff --git a/Modules/Core/Common/include/itkVectorContainer.h b/Modules/Core/Common/include/itkVectorContainer.h index 56447a4ac45..0bcfbe09c0a 100644 --- a/Modules/Core/Common/include/itkVectorContainer.h +++ b/Modules/Core/Common/include/itkVectorContainer.h @@ -587,7 +587,7 @@ template auto MakeVectorContainer(std::vector stdVector) { - auto vectorContainer = VectorContainer::New(); + auto vectorContainer = VectorContainer::New(); vectorContainer->CastToSTLContainer() = std::move(stdVector); return vectorContainer; } diff --git a/Modules/Core/Transform/include/itkKernelTransform.h b/Modules/Core/Transform/include/itkKernelTransform.h index 239372536fb..e1edc39834a 100644 --- a/Modules/Core/Transform/include/itkKernelTransform.h +++ b/Modules/Core/Transform/include/itkKernelTransform.h @@ -125,7 +125,7 @@ class ITK_TEMPLATE_EXPORT KernelTransform : public Transform; + using VectorSetType = itk::VectorContainer; using VectorSetPointer = typename VectorSetType::Pointer; /** Get/Set the source landmarks list, which we will denote \f$ p \f$. */ diff --git a/Modules/Filtering/ImageSources/include/itkGridImageSource.h b/Modules/Filtering/ImageSources/include/itkGridImageSource.h index 3b86e455dc0..56ee1bbfcd6 100644 --- a/Modules/Filtering/ImageSources/include/itkGridImageSource.h +++ b/Modules/Filtering/ImageSources/include/itkGridImageSource.h @@ -91,7 +91,7 @@ class ITK_TEMPLATE_EXPORT GridImageSource : public GenerateImageSource; using BoolArrayType = FixedArray; using PixelArrayType = vnl_vector; - using PixelArrayContainerType = VectorContainer; + using PixelArrayContainerType = VectorContainer; /** Set/Get kernel function used to create the grid. */ itkSetObjectMacro(KernelFunction, KernelFunctionType); diff --git a/Modules/IO/MeshVTK/include/itkVTKPolyDataMeshIO.h b/Modules/IO/MeshVTK/include/itkVTKPolyDataMeshIO.h index a4586e2a5b7..b00b614cfbd 100644 --- a/Modules/IO/MeshVTK/include/itkVTKPolyDataMeshIO.h +++ b/Modules/IO/MeshVTK/include/itkVTKPolyDataMeshIO.h @@ -56,7 +56,7 @@ class ITKIOMeshVTK_EXPORT VTKPolyDataMeshIO : public MeshIOBase using StringVectorType = std::vector; using StringStreamType = std::stringstream; using PointIdVector = std::vector; - using PolylinesContainerType = VectorContainer; + using PolylinesContainerType = VectorContainer; using PolylinesContainerPointer = PolylinesContainerType::Pointer; /** Method for creation through the object factory. */