#include "RectangleElement.h"

RectangleElement::RectangleElement(const DiscretePoint& loc,
            unsigned width, unsigned height)
    : mLocation(loc),
      mWidth(width),
      mHeight(height)
{

}

std::unique_ptr<RectangleElement> RectangleElement::Create(const DiscretePoint& loc,
        unsigned width, unsigned height)
{
    return std::make_unique<RectangleElement>(loc, width, height);
}

GeometryElement::Type RectangleElement::GetType()
{
    return GeometryElement::Type::Rectangle;
}

DiscretePoint RectangleElement::GetLocation() const
{
    return mLocation;
}

unsigned RectangleElement::GetWidth() const
{
    return mWidth;
}

unsigned RectangleElement::GetHeight() const
{
    return mHeight;
}
