CPP04 1.0
読み取り中…
検索中…
一致する文字列を見つけられません
Animal.hpp
[詳解]
1/* ************************************************************************** */
2/* */
3/* ::: :::::::: */
4/* Animal.hpp :+: :+: :+: */
5/* +:+ +:+ +:+ */
6/* By: kamitsui <kamitsui@student.42tokyo.jp> +#+ +:+ +#+ */
7/* +#+#+#+#+#+ +#+ */
8/* Created: 2025/05/20 16:24:30 by kamitsui #+# #+# */
9/* Updated: 2025/05/20 23:18:05 by kamitsui ### ########.fr */
10/* */
11/* ************************************************************************** */
12
21#ifndef ANIMAL_HPP
22#define ANIMAL_HPP
23
24#include <iostream>
25#include <string>
26
37class Animal {
38 protected:
40
41 public:
43 Animal(const Animal &other);
44 Animal &operator=(const Animal &other);
45 virtual ~Animal();
46
47 virtual void makeSound() const;
48 const std::string &getType() const;
49};
50
51#endif
The Animal class represents a generic animal.
Definition Animal.hpp:37
virtual ~Animal()
const std::string & getType() const
Animal & operator=(const Animal &other)
virtual void makeSound() const
Animal(const Animal &other)
std::string type
Definition Animal.hpp:39