SmartFoxServer 3 C++ Client API 3.1.0-beta
Client API for SmartFoxServer 3
Loading...
Searching...
No Matches
sfs3::requests::ChangeRoomNameRequest Class Reference

Changes the name of a Room. More...

#include <ChangeRoomNameRequest.h>

Inheritance diagram for sfs3::requests::ChangeRoomNameRequest:
[legend]

Public Member Functions

 ChangeRoomNameRequest (std::shared_ptr< entities::Room > room, std::string newName)
 Creates a new ChangeRoomNameRequest.

Detailed Description

Changes the name of a Room.

On success a event::SFSEvent::ROOM_NAME_CHANGE event reaches every user who subscribed the Group of the Room, the requester included. If the user is not the creator (owner) of the Room, a event::SFSEvent::ROOM_NAME_CHANGE_ERROR event is fired instead. An administrator or a moderator does not have this limit.

If the Room was set up so that it cannot be renamed (see the permissions setting in RoomSettings), the request is dropped and no error is fired.

See also
event::SFSEvent::ROOM_NAME_CHANGE
event::SFSEvent::ROOM_NAME_CHANGE_ERROR
RoomSettings::permissions

Constructor & Destructor Documentation

◆ ChangeRoomNameRequest()

sfs3::requests::ChangeRoomNameRequest::ChangeRoomNameRequest ( std::shared_ptr< entities::Room > room,
std::string newName )
inline

Creates a new ChangeRoomNameRequest.

Pass it to SmartFox::send for the request to be performed.

Parameters
roomThe Room whose name must change.
newNameThe new name of the Room.
See also
SmartFox::send

The documentation for this class was generated from the following files:
  • requests/ChangeRoomNameRequest.h
  • requests/ChangeRoomNameRequest.cpp