From c426fe76ec5925e8c94aae3db04e5e1f1ce1585e Mon Sep 17 00:00:00 2001 From: Charles Cabergs Date: Mon, 19 Oct 2020 13:59:12 +0200 Subject: Adding boilerplate cpp05/ex02 --- cpp05/ex02/ShrubberyCreationForm.cpp | 31 +++++++++++++++++++++++++++++++ 1 file changed, 31 insertions(+) create mode 100644 cpp05/ex02/ShrubberyCreationForm.cpp (limited to 'cpp05/ex02/ShrubberyCreationForm.cpp') diff --git a/cpp05/ex02/ShrubberyCreationForm.cpp b/cpp05/ex02/ShrubberyCreationForm.cpp new file mode 100644 index 0000000..e138824 --- /dev/null +++ b/cpp05/ex02/ShrubberyCreationForm.cpp @@ -0,0 +1,31 @@ +/* ************************************************************************** */ +/* */ +/* ::: :::::::: */ +/* ShrubberyCreationForm.cpp :+: :+: :+: */ +/* +:+ +:+ +:+ */ +/* By: cacharle +#+ +:+ +#+ */ +/* +#+#+#+#+#+ +#+ */ +/* Created: 2020/10/19 13:45:45 by cacharle #+# #+# */ +/* Updated: 2020/10/19 13:55:53 by cacharle ### ########.fr */ +/* */ +/* ************************************************************************** */ + +#include "ShrubberyCreationForm.hpp" + +ShrubberyCreationForm::ShrubberyCreationForm(const ShrubberyCreationForm& other) + : m_target(other.m_target) +{} + +ShrubberyCreationForm& ShrubberyCreationForm::operator=(const ShrubberyCreationForm& other) +{ + Form::operator=(*this, other); + m_target = other.m_target; + return *this; +} + +ShrubberyCreationForm::~ShrubberyCreationForm() {} + +ShrubberyCreationForm::ShrubberyCreationForm(std::string const& target) + m_target(target) {} + +ShrubberyCreationForm::ShrubberyCreationForm() : m_target("") {} -- cgit