ILIAS
Release_4_4_x_branch Revision 61816
|
Class ilChatroomServerConnector. More...
Public Member Functions | |
__construct (ilChatroomServerSettings $settings) | |
Constructor Sets $this->settings using given $settings. | |
connect ($scope, $userId) | |
Returns connect URL Creates connect URL using given $scope and $userId and returns it. | |
post ($scope, $query) | |
Returns post URL Creates post URL using given $scope and $query and returns it. | |
enterPrivateRoom ($scope, $query) | |
leavePrivateRoom ($scope, $query) | |
kick ($scope, $query) | |
Returns kick URL Creates kick URL using given $scope and $query and returns it. | |
getSettings () | |
Returns $this->settings. | |
sendMessage ($scope, $message, $options=array()) | |
Returns if given message is sucessfully sent. | |
inviteToPrivateRoom (ilChatRoom $room, $scope, ilObjUser $inviter, $invited_id) | |
createPrivateRoom (ilChatroom $room, $title, ilChatroomUser $owner) | |
isServerAlive () |
Static Public Member Functions | |
static | checkServerConnection () |
Private Member Functions | |
file_get_contents ($url, array $stream_context_params=null) | |
sendCreatePrivateRoom ($scope, $query) |
Private Attributes | |
$settings |
Class ilChatroomServerConnector.
Definition at line 10 of file class.ilChatroomServerConnector.php.
ilChatroomServerConnector::__construct | ( | ilChatroomServerSettings | $settings | ) |
Constructor Sets $this->settings using given $settings.
ilChatroomServerSettings | $settings |
Definition at line 22 of file class.ilChatroomServerConnector.php.
References $settings.
|
static |
Definition at line 280 of file class.ilChatroomServerConnector.php.
References $settings.
Referenced by ilChatroomBlockGUI\getHTML().
ilChatroomServerConnector::connect | ( | $scope, | |
$userId | |||
) |
Returns connect URL Creates connect URL using given $scope and $userId and returns it.
string | $scope | |
integer | $userId |
Definition at line 58 of file class.ilChatroomServerConnector.php.
References file_get_contents().
ilChatroomServerConnector::createPrivateRoom | ( | ilChatroom | $room, |
$title, | |||
ilChatroomUser | $owner | ||
) |
ilChatroom | $room | |
string | $title | |
ilChatroomUser | $owner |
Definition at line 208 of file class.ilChatroomServerConnector.php.
References $query, $result, $settings, ilChatroom\addPrivateRoom(), enterPrivateRoom(), ilChatroom\getRoomId(), ilChatroomUser\getUserId(), sendCreatePrivateRoom(), sendMessage(), and ilChatroom\subscribeUserToPrivateRoom().
ilChatroomServerConnector::enterPrivateRoom | ( | $scope, | |
$query | |||
) |
string | $scope | |
string | $query |
Definition at line 96 of file class.ilChatroomServerConnector.php.
References $query, and file_get_contents().
Referenced by createPrivateRoom().
|
private |
string | $url | |
array | $stream_context_params |
Definition at line 32 of file class.ilChatroomServerConnector.php.
Referenced by connect(), enterPrivateRoom(), isServerAlive(), kick(), leavePrivateRoom(), post(), and sendCreatePrivateRoom().
ilChatroomServerConnector::getSettings | ( | ) |
Returns $this->settings.
Definition at line 133 of file class.ilChatroomServerConnector.php.
References $settings.
ilChatroomServerConnector::inviteToPrivateRoom | ( | ilChatRoom | $room, |
$scope, | |||
ilObjUser | $inviter, | ||
$invited_id | |||
) |
ilChatRoom | $room | |
int | $scope | |
ilObjUser | $inviter | |
int | $invited_id |
Definition at line 161 of file class.ilChatroomServerConnector.php.
References ilObject\getId(), ilChatroom\lookupPrivateRoomTitle(), and sendMessage().
ilChatroomServerConnector::isServerAlive | ( | ) |
Definition at line 258 of file class.ilChatroomServerConnector.php.
References file_get_contents().
ilChatroomServerConnector::kick | ( | $scope, | |
$query | |||
) |
Returns kick URL Creates kick URL using given $scope and $query and returns it.
string | $scope | |
string | $query |
Definition at line 122 of file class.ilChatroomServerConnector.php.
References $query, and file_get_contents().
ilChatroomServerConnector::leavePrivateRoom | ( | $scope, | |
$query | |||
) |
string | $scope | |
string | $query |
Definition at line 108 of file class.ilChatroomServerConnector.php.
References $query, and file_get_contents().
ilChatroomServerConnector::post | ( | $scope, | |
$query | |||
) |
Returns post URL Creates post URL using given $scope and $query and returns it.
string | $scope | |
string | $query |
Definition at line 72 of file class.ilChatroomServerConnector.php.
References $query, and file_get_contents().
Referenced by sendMessage().
|
private |
string | $scope | |
string | $query |
Definition at line 84 of file class.ilChatroomServerConnector.php.
References $query, and file_get_contents().
Referenced by createPrivateRoom().
ilChatroomServerConnector::sendMessage | ( | $scope, | |
$message, | |||
$options = array() |
|||
) |
Returns if given message is sucessfully sent.
Calls $this->post using given $scope and $query built by http_build_query with given $message and returns if message was sent sucessfully.
string | $scope | |
string | $message |
Definition at line 147 of file class.ilChatroomServerConnector.php.
References $options, $query, and post().
Referenced by createPrivateRoom(), and inviteToPrivateRoom().
|
private |
Definition at line 15 of file class.ilChatroomServerConnector.php.
Referenced by __construct(), checkServerConnection(), createPrivateRoom(), and getSettings().