/** * @file TemplateWeightedPoint.h * @date Sep 3, 2013 * @brief Weighted point class. * * @copyright * Copyright (c) 2012-2018, OpenGeoSys Community (http://www.opengeosys.org) * Distributed under a Modified BSD License. * See accompanying file LICENSE.txt or * http://www.opengeosys.org/LICENSE.txt */ #pragma once #include "TemplatePoint.h" namespace MathLib { template class TemplateWeightedPoint : public TemplatePoint { public: TemplateWeightedPoint(std::array const& x, W_T weight) : TemplatePoint(x), _weight(weight) {} W_T getWeight() const { return _weight; } private: W_T const _weight; }; using WeightedPoint1D = TemplateWeightedPoint; using WeightedPoint2D = TemplateWeightedPoint; using WeightedPoint3D = TemplateWeightedPoint; } // end namespace MathLib