CPP05 1.0
読み取り中…
検索中…
一致する文字列を見つけられません
IFormFactory.hpp
[詳解]
1/* ************************************************************************** */
2/* */
3/* ::: :::::::: */
4/* IFormFactory.hpp :+: :+: :+: */
5/* +:+ +:+ +:+ */
6/* By: kamitsui <kamitsui@student.42tokyo.jp> +#+ +:+ +#+ */
7/* +#+#+#+#+#+ +#+ */
8/* Created: 2025/07/18 19:22:20 by kamitsui #+# #+# */
9/* Updated: 2025/07/18 19:22:22 by kamitsui ### ########.fr */
10/* */
11/* ************************************************************************** */
12
13#ifndef IFORMFACTORY_HPP
14#define IFORMFACTORY_HPP
15
16#include "AForm.hpp"
17#include <string>
18
19// Form Generator Interface.
21 public:
22 virtual ~IFormFactory() {}
23 // Pure virtual functions to generate three different forms.
24 virtual AForm *createShrubbery(const std::string &target) const = 0;
25 virtual AForm *createRobotomy(const std::string &target) const = 0;
26 virtual AForm *createPresidential(const std::string &target) const = 0;
27};
28
29#endif
An abstract base class for forms.
Definition AForm.hpp:34
virtual AForm * createPresidential(const std::string &target) const =0
virtual AForm * createShrubbery(const std::string &target) const =0
virtual ~IFormFactory()
virtual AForm * createRobotomy(const std::string &target) const =0
Defines the abstract base class AForm for all specific forms.