GameRC (IRC Server)  1.0.0
C++98 기반 IRC 서버 프로젝트
로딩중...
검색중...
일치하는것 없음
Earth.hpp
이 파일의 문서화 페이지로 가기
1/**
2 * @file Earth.hpp
3 * @author Jeekun Park (jeekunp@naver.com)
4 * @brief IAnimation 인터페이스를 구현하는 Earth 클래스를 정의한다.
5 * @version 0.1
6 * @date 2024-04-12
7 *
8 * @copyright Copyright (c) 2024
9 */
10
11#pragma once
12
13#include "common.hpp"
14#include <vector>
15
17
18namespace grc
19{
20
21/**
22 * @class Earth
23 * @brief 지구의 애니메이션을 출력하는 클래스이다.
24 *
25 * Earth 클래스는 IAnimation 인터페이스를 구현하여 지구의 애니메이션 표현을 제공한다.
26 * 여러 프레임의 애니메이션을 저장하고 순차적으로 표시한다.
27 */
28class Earth : public IAnimation
29{
30public:
31
32 /**
33 * @brief Earth 클래스의 기본 생성자
34 */
35 Earth();
36
37 /**
38 * @brief Earth 클래스의 복사 생성자
39 * @param copy 복사할 Earth 객체의 참조
40 */
41 Earth(const Earth& copy);
42
43 /**
44 * @brief Earth 클래스의 복사 대입 연산자
45 * @param copy 복사할 Earth 객체의 참조
46 * @return Earth& 업데이트된 객체의 참조를 반환
47 */
48 Earth& operator=(const Earth& copy);
49
50 /**
51 * @brief Earth 클래스의 소멸자
52 */
53 virtual ~Earth();
54
55 /**
56 * @brief 인자로 받은 디스플레이 콘솔에 다음 애니메이션 프레임을 출력한다.
57 *
58 * 연속적인 호출을 통해 애니메이션 효과를 생성한다.
59 *
60 * @param monitor 프레임이 출력될 gdf::DispalyConsole 객체의 참조
61 */
62 virtual void PrintNextFrame(gdf::DisplayConsole& monitor);
63private:
64 enum { FRAMES_SIZE = 30}; ///< 애니메이션 시퀀스의 전체 프레임 수
65 uint64 mFramesIndex; ///< 프레임 시퀀스에서의 현재 프레임 인덱스
66 std::vector<std::string> mFrames; ///< 각 애니메이션 프레임을 저장하는 배열
67};
68
69} // namespace grc
IAnimation 인터페이스에 대한 정의
지구의 애니메이션을 출력하는 클래스이다.
Definition Earth.hpp:29
virtual void PrintNextFrame(gdf::DisplayConsole &monitor)
인자로 받은 디스플레이 콘솔에 다음 애니메이션 프레임을 출력한다.
Definition Earth.cpp:789
Earth & operator=(const Earth &copy)
Earth 클래스의 복사 대입 연산자
Definition Earth.cpp:775
@ FRAMES_SIZE
Definition Earth.hpp:64
Earth()
Earth 클래스의 기본 생성자
Definition Earth.cpp:14
std::vector< std::string > mFrames
각 애니메이션 프레임을 저장하는 배열
Definition Earth.hpp:66
virtual ~Earth()
Earth 클래스의 소멸자
Definition Earth.cpp:785
uint64 mFramesIndex
프레임 시퀀스에서의 현재 프레임 인덱스
Definition Earth.hpp:65
Definition Earth.cpp:12