GameRC (IRC Server)
1.0.0
C++98 기반 IRC 서버 프로젝트
|
IRC에서 생성되는 Channel 객체를 정의하는 클래스. 더 자세히 ...
#include <Channel.hpp>
Public 타입 | |
enum | { UNLIMIT = 0 } |
채널에 입장 가능한 최대 유저 수의 제한이 없음을 나타낸다. 더 자세히 ... | |
Public 멤버 함수 | |
Channel () | |
Channel 객체의 기본 생성자. | |
virtual | ~Channel () |
Channel 객체의 소멸자. | |
bool | IsUserExist (const std::string &IN nickname) const |
채널에 유저가 존재하는지 확인하는 함수. | |
bool | IsOperator (const std::string &IN nickname) const |
유저가 채널의 operator인지 확인하는 함수. | |
bool | IsInvited (const std::string &IN nickname) const |
유저가 채널에 초대되었는지 확인하는 함수. | |
bool | IsProtectedTopic () const |
채널의 topic을 operator만 설정할 수 있는지 확인하는 함수. | |
bool | IsInviteOnly () const |
채널이 초대 전용으로 설정되었는지 확인하는 함수. | |
bool | IsKeyRequired () const |
채널에 key가 설정되었는지 확인하는 함수. | |
bool | IsLimitedMaxUserCount () const |
채널에 최대 입장 유저 수 제한이 설정되었는지 확인하는 함수. | |
bool | IsChannelEmpty () const |
채널에 유저가 없는지 확인하는 함수. | |
const std::string & | GetName () const |
Channel 객체의 name을 반환하는 함수. | |
const std::string & | GetTopic () const |
Channel 객체의 topic을 반환하는 함수. | |
uint32 | GetMaxUserCount () const |
Channel 객체의 max user count을 반환하는 함수. | |
const std::string & | GetKey () const |
Channel 객체의 key를 반환하는 함수. | |
uint32 | GetCurrentUserCount () const |
현재 채널에 존재하는 유저의 수를 반환하는 함수. | |
const std::map< std::string, User > & | GetUsers () const |
현재 채널에 존재하는 유저 목록을 반환하는 함수. | |
const std::map< std::string, User > & | GetOperators () const |
현재 채널에 존재하는 operator 목록을 반환하는 함수. | |
std::string | GetAllUsersNickname () const |
현재 채널에 존재하는 유저들의 nickname 목록을 반환하는 함수. | |
std::string | GetModeString () const |
현재 채널에 설정된 mode를 반환하는 함수. | |
std::string | GetModeArgument () const |
현재 채널에 설정된 mode에 대한 인자들을 반환하는 함수. | |
void | SetName (const std::string &IN channelName) |
Channel 객체의 name을 설정하는 함수. | |
void | SetTopic (const std::string &IN topic) |
Channel 객체의 topic을 설정하는 함수. | |
void | SetMaxUserCount (uint32 IN maxUserCount) |
Channel 객체의 max user count를 설정하는 함수. | |
void | SetKey (const std::string &IN key) |
Channel 객체의 key를 설정하는 함수. | |
void | SetProtectedTopic () |
채널의 topic을 operator만 설정할 수 있도록 하는 함수. | |
void | SetInviteOnly () |
채널을 초대 전용으로 설정하는 함수. | |
void | SetLimitedMaxUserCount () |
채널에 입장 가능한 최대 유저 수 제한을 설정하는 함수. | |
void | SetKeyRequired () |
채널의 key를 설정하는 함수. | |
void | UnsetProtectedTopic () |
채널의 topic을 모두가 설정할 수 있도록 하는 함수. | |
void | UnsetInviteOnly () |
초대 전용 설정을 해제하는 함수. | |
void | UnsetLimitedMaxUserCount () |
채널에 입장 가능한 최대 유저 수 제한을 해제하는 함수. | |
void | UnsetKeyRequired () |
채널의 key를 해제하는 함수. | |
void | AddUser (const std::string &IN nickname, const User &IN user) |
채널에 유저를 추가하는 함수. | |
void | AddOperator (const std::string &IN nickname, const User &IN user) |
채널에 operator를 추가하는 함수. | |
void | AddInvitedUser (const std::string &IN nickname, const User &IN user) |
채널에 초대 받은 유저를 추가하는 함수. | |
void | DeleteTopic () |
채널의 topic을 삭제하는 함수. | |
void | DeleteUser (const std::string &IN nickname) |
채널의 유저를 삭제하는 함수. | |
void | DeleteOperator (const std::string &IN nickname) |
채널의 operator를 삭제하는 함수. | |
void | DeleteInvitedUser (const std::string &IN nickname) |
채널에 초대 받은 유저를 삭제하는 함수. | |
Private 멤버 함수 | |
Channel (const Channel &IN channel) | |
Channel 객체의 복사 생성자. | |
const Channel & | operator= (const Channel &IN channel) |
Channel 객체의 복사 대입 연산자. | |
Private 속성 | |
std::string | mName |
Channel 객체의 이름을 저장하는 멤버 변수. | |
std::string | mTopic |
Channel 객체의 topic을 저장하는 멤버 변수. | |
uint32 | mMaxUserCount |
Channel 객체의 max user count을 저장하는 멤버 변수. | |
std::string | mKey |
Channel 객체의 key를 저장하는 멤버 변수. | |
std::map< std::string, User > | mUsers |
채널에 입장한 유저의 목록을 저장하는 멤버 변수. | |
std::map< std::string, User > | mOperators |
채널에 입장한 operator의 목록을 저장하는 멤버 변수. | |
std::map< std::string, User > | mInvitedUsers |
채널에 초대된 유저의 목록을 저장하는 멤버 변수. | |
bool | mbIsProtectedTopic |
채널의 topic 설정에 operator 권한이 필요한 상태인지를 저장하는 멤버 변수. | |
bool | mbIsInviteOnly |
채널이 초대 전용 상태인지 저장하는 멤버 변수. | |
bool | mbIsLimitedMaxUserCount |
채널에 입장 가능한 최대 유저 수 제한이 설정된 상태인지를 저장하는 멤버 변수. | |
bool | mbIsKeyRequired |
채널에 key가 설정된 상태인지 저장하는 멤버 변수. | |
IRC에서 생성되는 Channel 객체를 정의하는 클래스.
grc::Channel::Channel | ( | ) |
Channel 객체의 기본 생성자.
객체가 생성될 때, 모든 멤버 변수들을 초기화한다.
|
virtual |
Channel 객체의 소멸자.
|
private |
bool grc::Channel::IsUserExist | ( | const std::string &IN | nickname | ) | const |
채널에 유저가 존재하는지 확인하는 함수.
nickname | target nickname. |
bool grc::Channel::IsOperator | ( | const std::string &IN | nickname | ) | const |
유저가 채널의 operator인지 확인하는 함수.
nickname | target nickname. |
bool grc::Channel::IsInvited | ( | const std::string &IN | nickname | ) | const |
유저가 채널에 초대되었는지 확인하는 함수.
nickname | target nickname. |
bool grc::Channel::IsProtectedTopic | ( | ) | const |
채널의 topic을 operator만 설정할 수 있는지 확인하는 함수.
bool grc::Channel::IsInviteOnly | ( | ) | const |
채널이 초대 전용으로 설정되었는지 확인하는 함수.
bool grc::Channel::IsKeyRequired | ( | ) | const |
채널에 key가 설정되었는지 확인하는 함수.
bool grc::Channel::IsLimitedMaxUserCount | ( | ) | const |
채널에 최대 입장 유저 수 제한이 설정되었는지 확인하는 함수.
bool grc::Channel::IsChannelEmpty | ( | ) | const |
채널에 유저가 없는지 확인하는 함수.
const std::string & grc::Channel::GetName | ( | ) | const |
const std::string & grc::Channel::GetTopic | ( | ) | const |
uint32 grc::Channel::GetMaxUserCount | ( | ) | const |
const std::string & grc::Channel::GetKey | ( | ) | const |
uint32 grc::Channel::GetCurrentUserCount | ( | ) | const |
현재 채널에 존재하는 유저의 수를 반환하는 함수.
const std::map< std::string, User > & grc::Channel::GetUsers | ( | ) | const |
현재 채널에 존재하는 유저 목록을 반환하는 함수.
const std::map< std::string, User > & grc::Channel::GetOperators | ( | ) | const |
현재 채널에 존재하는 operator 목록을 반환하는 함수.
std::string grc::Channel::GetAllUsersNickname | ( | ) | const |
현재 채널에 존재하는 유저들의 nickname 목록을 반환하는 함수.
std::string grc::Channel::GetModeString | ( | ) | const |
현재 채널에 설정된 mode를 반환하는 함수.
std::string grc::Channel::GetModeArgument | ( | ) | const |
현재 채널에 설정된 mode에 대한 인자들을 반환하는 함수.
void grc::Channel::SetName | ( | const std::string &IN | channelName | ) |
Channel 객체의 name을 설정하는 함수.
channelName | target channelName. |
void grc::Channel::SetTopic | ( | const std::string &IN | topic | ) |
Channel 객체의 topic을 설정하는 함수.
topic | target topic. |
void grc::Channel::SetMaxUserCount | ( | uint32 IN | maxUserCount | ) |
Channel 객체의 max user count를 설정하는 함수.
maxUserCount | target maxUserCount. |
void grc::Channel::SetKey | ( | const std::string &IN | key | ) |
Channel 객체의 key를 설정하는 함수.
key | target key. |
void grc::Channel::SetProtectedTopic | ( | ) |
채널의 topic을 operator만 설정할 수 있도록 하는 함수.
멤버 변수 mbIsProtectedTopic을 true로 설정한다.
void grc::Channel::SetInviteOnly | ( | ) |
채널을 초대 전용으로 설정하는 함수.
멤버 변수 mbIsInviteOnly를 true로 설정한다.
void grc::Channel::SetLimitedMaxUserCount | ( | ) |
채널에 입장 가능한 최대 유저 수 제한을 설정하는 함수.
멤버 변수 mbIsLimitedMaxUserCount를 true로 설정한다.
void grc::Channel::SetKeyRequired | ( | ) |
채널의 key를 설정하는 함수.
멤버 변수 mbIsKeyRequired를 true로 설정한다.
void grc::Channel::UnsetProtectedTopic | ( | ) |
채널의 topic을 모두가 설정할 수 있도록 하는 함수.
멤버 변수 mbIsProtectedTopic을 false로 설정한다.
void grc::Channel::UnsetInviteOnly | ( | ) |
초대 전용 설정을 해제하는 함수.
멤버 변수 mbIsInviteOnly를 false로 설정한다.
void grc::Channel::UnsetLimitedMaxUserCount | ( | ) |
채널에 입장 가능한 최대 유저 수 제한을 해제하는 함수.
멤버 변수 mbIsLimitedMaxUserCount를 false로 설정한다.
void grc::Channel::UnsetKeyRequired | ( | ) |
채널의 key를 해제하는 함수.
멤버 변수 mbIsKeyRequired를 false로 설정한다.
void grc::Channel::AddUser | ( | const std::string &IN | nickname, |
const User &IN | user ) |
채널에 유저를 추가하는 함수.
nickname | 추가할 유저의 nickname. |
user | 추가할 User 객체. |
void grc::Channel::AddOperator | ( | const std::string &IN | nickname, |
const User &IN | user ) |
채널에 operator를 추가하는 함수.
nickname | 추가할 operator의 nickname. |
user | 추가할 User 객체. |
void grc::Channel::AddInvitedUser | ( | const std::string &IN | nickname, |
const User &IN | user ) |
채널에 초대 받은 유저를 추가하는 함수.
nickname | 초대 받은 유저의 nickname. |
user | 추가할 User 객체. |
void grc::Channel::DeleteTopic | ( | ) |
채널의 topic을 삭제하는 함수.
void grc::Channel::DeleteUser | ( | const std::string &IN | nickname | ) |
채널의 유저를 삭제하는 함수.
nickname | 삭제할 유저의 nickname. |
void grc::Channel::DeleteOperator | ( | const std::string &IN | nickname | ) |
채널의 operator를 삭제하는 함수.
nickname | 삭제할 operator의 nickname. |
void grc::Channel::DeleteInvitedUser | ( | const std::string &IN | nickname | ) |
채널에 초대 받은 유저를 삭제하는 함수.
nickname | 삭제할 유저의 nickname. |
|
private |
Channel 객체의 이름을 저장하는 멤버 변수.
|
private |
Channel 객체의 topic을 저장하는 멤버 변수.
|
private |
Channel 객체의 max user count을 저장하는 멤버 변수.
|
private |
Channel 객체의 key를 저장하는 멤버 변수.
|
private |
채널에 입장한 유저의 목록을 저장하는 멤버 변수.
|
private |
채널에 입장한 operator의 목록을 저장하는 멤버 변수.
|
private |
채널에 초대된 유저의 목록을 저장하는 멤버 변수.
|
private |
채널의 topic 설정에 operator 권한이 필요한 상태인지를 저장하는 멤버 변수.
|
private |
채널이 초대 전용 상태인지 저장하는 멤버 변수.
|
private |
채널에 입장 가능한 최대 유저 수 제한이 설정된 상태인지를 저장하는 멤버 변수.
|
private |
채널에 key가 설정된 상태인지 저장하는 멤버 변수.