![]() | |
![]() | ![]() |
Entire Class Index | Main Class Index | Cross Index | Global Index |
Network component class. Starting place for all net activity in ClanLib.
Contained in: global
Derived from:
none
Derived by:
none
Group: Network (System)
#include <ClanLib/network.h>
public function member index: |
||
Operations: |
||
static void | find_sessions_broadcast | (std::string game_id, int port); |
static void | find_session_at | (std::string app_id, const std::string& host_address, int port); |
static bool | peek_session_found | (); |
static CL_NetSession* | receive_session_found | (int timeout_millis); |
static void | clear_sessions_found | (); |
static CL_NetSession* | create_session | (std::string app_id, int port); |
app_id - The app ID is used to locate netsessions of the same type.
port - Port the game accepts connections on - and listens for broadcasts.
Returns - The created network game.
host_address - IP address or hostname of the computer to be contacted.
port - Port which the computer contacted listens on.
game_id - The game's ID used to locate this type of game with.
port - Broadcast UDP port.
Returns - True if any netsessions have been found.
timeout_millis - Timeout before returning if no game was found.
Returns - The netsession found, or NULL if timed out. Remember to delete the
Returns - netsession after usage.