Zao SDK for Jetson / libzep API リファレンス  1.0.0.0 (2023-05-08)
RoomGroupList.hpp
1 #ifndef ZEP_CONTROL_ROOM_GROUP_LIST_HPP
2 #define ZEP_CONTROL_ROOM_GROUP_LIST_HPP
3 
4 #include <string>
5 #include <vector>
6 
7 namespace zep {
8 namespace control {
9 
14  public:
19  RoomGroupEntry() noexcept {}
20 
29  RoomGroupEntry(const std::uint32_t id,
30  const std::string& name,
31  const std::string& nickname) noexcept {
32  SetId(id);
33  SetName(name);
34  SetNickname(nickname);
35  }
36 
40  std::uint32_t GetId() const noexcept { return id_; }
41 
47  void SetId(std::uint32_t id) noexcept { id_ = id; }
48 
52  std::string GetName() const noexcept { return name_; }
53 
59  void SetName(const std::string& name) noexcept { name_ = name; }
60 
64  std::string GetNickname() const noexcept { return nickname_; }
65 
71  void SetNickname(const std::string& nickname) noexcept { nickname_ = nickname; }
72 
80  bool operator==(const RoomGroupEntry& other) const noexcept {
81  return id_ == other.id_ &&
82  name_ == other.name_ &&
83  nickname_ == other.nickname_;
84  }
85 
93  bool operator!=(const RoomGroupEntry& other) const noexcept {
94  return !(*this == other);
95  }
96 
97  private:
101  std::uint32_t id_ = 0;
102 
106  std::string name_;
107 
111  std::string nickname_;
112 
113 };
114 
119  public:
124  RoomGroupList() noexcept {}
125 
129  std::vector<RoomGroupEntry> GetRoomGroups() const noexcept { return room_groups_; }
130 
136  void SetRoomGroup(RoomGroupEntry& room_group) noexcept {
137  room_groups_.push_back(room_group);
138  }
139 
143  std::uint32_t GetSelectedId() const noexcept { return selected_id_; }
144 
150  void SetSelectedId(std::uint32_t id) noexcept { selected_id_ = id; }
151 
152  private:
156  std::vector<RoomGroupEntry> room_groups_;
157 
161  std::uint32_t selected_id_;
162 
163 };
164 
165 } // namespace control
166 } // namespace zep
167 
168 #endif // ZEP_CONTROL_ROOM_GROUP_LIST_HPP
void SetSelectedId(std::uint32_t id) noexcept
ルームグループのIDを選択設定する。
Definition: RoomGroupList.hpp:150
void SetNickname(const std::string &nickname) noexcept
ルームグループのニックネームを設定する。
Definition: RoomGroupList.hpp:71
void SetRoomGroup(RoomGroupEntry &room_group) noexcept
ルームグループを動的配列に追加する。
Definition: RoomGroupList.hpp:136
std::string GetName() const noexcept
ルームグループのネームを取得する。
Definition: RoomGroupList.hpp:52
ZEP SDK用名前空間
Definition: FactoryInterface.hpp:10
RoomGroupList() noexcept
RoomGroupList オブジェクトをデフォルト構築する。
Definition: RoomGroupList.hpp:124
void SetName(const std::string &name) noexcept
ルームグループのネームを設定する。
Definition: RoomGroupList.hpp:59
ルームグループリストのフォーマット
Definition: RoomGroupList.hpp:118
ルームグループのフォーマット
Definition: RoomGroupList.hpp:13
bool operator!=(const RoomGroupEntry &other) const noexcept
ルームグループ同士を非等値比較する
Definition: RoomGroupList.hpp:93
RoomGroupEntry() noexcept
RoomGroupEntry オブジェクトをデフォルト構築する。
Definition: RoomGroupList.hpp:19
std::string GetNickname() const noexcept
ルームグループのニックネームを取得する。
Definition: RoomGroupList.hpp:64
std::uint32_t GetId() const noexcept
ルームグループのIDを取得する。
Definition: RoomGroupList.hpp:40
std::uint32_t GetSelectedId() const noexcept
選択されているルームグループのIDを取得する。
Definition: RoomGroupList.hpp:143
void SetId(std::uint32_t id) noexcept
ルームグループのIDを設定する。
Definition: RoomGroupList.hpp:47
bool operator==(const RoomGroupEntry &other) const noexcept
ルームグループ同士を等値比較する
Definition: RoomGroupList.hpp:80
std::vector< RoomGroupEntry > GetRoomGroups() const noexcept
ルームグループの動的配列を取得する。
Definition: RoomGroupList.hpp:129
RoomGroupEntry(const std::uint32_t id, const std::string &name, const std::string &nickname) noexcept
RoomGroupEntry オブジェクトを初期値付きで構築する。
Definition: RoomGroupList.hpp:29