C++  1.4.6
CloudBackend Software Development Kit - SDK API for C++
Member.h
1 #ifndef CBE_MEMBER_H
2 #define CBE_MEMBER_H
3 
4 #include "CBE/Types.h"
5 
6 namespace CBE {
7 
8  struct Request {
9  uint64_t userId{0};
10  std::string alias{""};
11  std::string applicationComment{""};
12  uint64_t date{0}; //unix time
13  };
14 
15 //this might be better to have just as a string on the member. also if so then list members should call list roles.
16  struct Role {
17  std::string role;
18  };
19 
20  class Member {
21  public:
28  virtual void kick(std::string kickComment, CBE::GroupDelegatePtr delegate);
29 
36  virtual void ban(std::string banComment, CBE::GroupDelegatePtr delegate);
37 
43  virtual void unBan(CBE::GroupDelegatePtr delegate);
44 
50  virtual uint64_t memberId() const;
51 
57  virtual std::string name() const;
58 
64  virtual CBE::Visibility visibility() const;
65 
71  virtual CBE::group_id_t groupId() const;
72 
78  virtual std::map<std::pair<uint64_t,uint64_t>,std::pair<uint64_t,std::string>> getMemberBanInfo();
79 
80  };
81 
82 
83 }
84 
85 #endif //CBE_MEMBER_H
CBE::Member::getMemberBanInfo
virtual std::map< std::pair< uint64_t, uint64_t >, std::pair< uint64_t, std::string > > getMemberBanInfo()
Get the Member Ban Info map.
CBE::Member
Definition: Member.h:20
CBE::Role
Definition: Member.h:16
CBE::Member::visibility
virtual CBE::Visibility visibility() const
Get the visibility set.
CBE::Member::groupId
virtual CBE::group_id_t groupId() const
Get the group id number.
CBE::Member::ban
virtual void ban(std::string banComment, CBE::GroupDelegatePtr delegate)
ban a user from joining a group.
CBE::Member::kick
virtual void kick(std::string kickComment, CBE::GroupDelegatePtr delegate)
kick out a member from the group.
CBE::Member::unBan
virtual void unBan(CBE::GroupDelegatePtr delegate)
Lift the ban on a user.
CBE::Member::memberId
virtual uint64_t memberId() const
Get the member id number.
CBE::Request
Definition: Member.h:8
CBE::Member::name
virtual std::string name() const
Returns the member name.