Cuberite
A lightweight, fast and extensible game server for Minecraft
Classes | Functions
ManualBindings_Network.cpp File Reference
#include "Globals.h"
#include "ManualBindings.h"
#include "tolua++/include/tolua++.h"
#include "LuaState.h"
#include "LuaTCPLink.h"
#include "LuaNameLookup.h"
#include "LuaServerHandle.h"
#include "LuaUDPEndpoint.h"
#include "../HTTP/UrlClient.h"
Include dependency graph for ManualBindings_Network.cpp:

Go to the source code of this file.

Classes

class  cFullUrlClientCallbacks
 Used when the cUrlClient Lua request wants all the callbacks. More...
 
class  cSimpleUrlClientCallbacks
 Used when the cUrlClient Lua request has just a single callback. More...
 

Functions

static int tolua_cNetwork_Connect (lua_State *L)
 Binds cNetwork::Connect. More...
 
static int tolua_cNetwork_CreateUDPEndpoint (lua_State *L)
 Binds cNetwork::CreateUDPEndpoint. More...
 
static int tolua_cNetwork_EnumLocalIPAddresses (lua_State *L)
 Binds cNetwork::EnumLocalIPAddresses. More...
 
static int tolua_cNetwork_HostnameToIP (lua_State *L)
 Binds cNetwork::HostnameToIP. More...
 
static int tolua_cNetwork_IPToHostname (lua_State *L)
 Binds cNetwork::IPToHostname. More...
 
static int tolua_cNetwork_Listen (lua_State *L)
 Binds cNetwork::Listen. More...
 
static int tolua_collect_cServerHandle (lua_State *L)
 Called when Lua destroys the object instance. More...
 
static int tolua_collect_cUDPEndpoint (lua_State *L)
 Called when Lua destroys the object instance. More...
 
static int tolua_cServerHandle_Close (lua_State *L)
 Binds cLuaServerHandle::Close. More...
 
static int tolua_cServerHandle_IsListening (lua_State *L)
 Binds cLuaServerHandle::IsListening. More...
 
static int tolua_cTCPLink_Close (lua_State *L)
 Binds cLuaTCPLink::Close. More...
 
static int tolua_cTCPLink_GetLocalIP (lua_State *L)
 Binds cLuaTCPLink::GetLocalIP. More...
 
static int tolua_cTCPLink_GetLocalPort (lua_State *L)
 Binds cLuaTCPLink::GetLocalPort. More...
 
static int tolua_cTCPLink_GetRemoteIP (lua_State *L)
 Binds cLuaTCPLink::GetRemoteIP. More...
 
static int tolua_cTCPLink_GetRemotePort (lua_State *L)
 Binds cLuaTCPLink::GetRemotePort. More...
 
static int tolua_cTCPLink_Send (lua_State *L)
 Binds cLuaTCPLink::Send. More...
 
static int tolua_cTCPLink_Shutdown (lua_State *L)
 Binds cLuaTCPLink::Shutdown. More...
 
static int tolua_cTCPLink_StartTLSClient (lua_State *L)
 Binds cLuaTCPLink::StartTLSClient. More...
 
static int tolua_cTCPLink_StartTLSServer (lua_State *L)
 Binds cLuaTCPLink::StartTLSServer. More...
 
static int tolua_cUDPEndpoint_Close (lua_State *L)
 Binds cLuaUDPEndpoint::Close. More...
 
static int tolua_cUDPEndpoint_EnableBroadcasts (lua_State *L)
 Binds cLuaUDPEndpoint::EnableBroadcasts. More...
 
static int tolua_cUDPEndpoint_GetPort (lua_State *L)
 Binds cLuaUDPEndpoint::GetPort. More...
 
static int tolua_cUDPEndpoint_IsOpen (lua_State *L)
 Binds cLuaUDPEndpoint::IsOpen. More...
 
static int tolua_cUDPEndpoint_Send (lua_State *L)
 Binds cLuaUDPEndpoint::Send. More...
 
static int tolua_cUrlClient_Delete (lua_State *a_LuaState)
 Implements cUrlClient:Get() using cUrlClient::Request(). More...
 
static int tolua_cUrlClient_Get (lua_State *a_LuaState)
 Implements cUrlClient:Get() using cUrlClient::Request(). More...
 
static int tolua_cUrlClient_Post (lua_State *a_LuaState)
 Implements cUrlClient:Post() using cUrlClient::Request(). More...
 
static int tolua_cUrlClient_Put (lua_State *a_LuaState)
 Implements cUrlClient:Put() using cUrlClient::Request(). More...
 
static int tolua_cUrlClient_Request (lua_State *a_LuaState)
 Binds cUrlClient::Request(). More...
 
static int tolua_cUrlClient_Request_Common (lua_State *a_LuaState, const AString &a_Method, int a_UrlStackIdx)
 Common code shared among the cUrlClient request methods. More...
 

Function Documentation

◆ tolua_cNetwork_Connect()

static int tolua_cNetwork_Connect ( lua_State *  L)
static

Binds cNetwork::Connect.

Definition at line 25 of file ManualBindings_Network.cpp.

◆ tolua_cNetwork_CreateUDPEndpoint()

static int tolua_cNetwork_CreateUDPEndpoint ( lua_State *  L)
static

Binds cNetwork::CreateUDPEndpoint.

Definition at line 73 of file ManualBindings_Network.cpp.

◆ tolua_cNetwork_EnumLocalIPAddresses()

static int tolua_cNetwork_EnumLocalIPAddresses ( lua_State *  L)
static

◆ tolua_cNetwork_HostnameToIP()

static int tolua_cNetwork_HostnameToIP ( lua_State *  L)
static

Binds cNetwork::HostnameToIP.

Definition at line 146 of file ManualBindings_Network.cpp.

◆ tolua_cNetwork_IPToHostname()

static int tolua_cNetwork_IPToHostname ( lua_State *  L)
static

Binds cNetwork::IPToHostname.

Definition at line 182 of file ManualBindings_Network.cpp.

◆ tolua_cNetwork_Listen()

static int tolua_cNetwork_Listen ( lua_State *  L)
static

Binds cNetwork::Listen.

Definition at line 218 of file ManualBindings_Network.cpp.

◆ tolua_collect_cServerHandle()

static int tolua_collect_cServerHandle ( lua_State *  L)
static

Called when Lua destroys the object instance.

Close the server and let it deallocate on its own (it's in a SharedPtr).

Definition at line 273 of file ManualBindings_Network.cpp.

◆ tolua_collect_cUDPEndpoint()

static int tolua_collect_cUDPEndpoint ( lua_State *  L)
static

Called when Lua destroys the object instance.

Close the endpoint and let it deallocate on its own (it's in a SharedPtr).

Definition at line 629 of file ManualBindings_Network.cpp.

◆ tolua_cServerHandle_Close()

static int tolua_cServerHandle_Close ( lua_State *  L)
static

Binds cLuaServerHandle::Close.

Definition at line 286 of file ManualBindings_Network.cpp.

◆ tolua_cServerHandle_IsListening()

static int tolua_cServerHandle_IsListening ( lua_State *  L)
static

Binds cLuaServerHandle::IsListening.

Definition at line 314 of file ManualBindings_Network.cpp.

◆ tolua_cTCPLink_Close()

static int tolua_cTCPLink_Close ( lua_State *  L)
static

Binds cLuaTCPLink::Close.

Definition at line 345 of file ManualBindings_Network.cpp.

◆ tolua_cTCPLink_GetLocalIP()

static int tolua_cTCPLink_GetLocalIP ( lua_State *  L)
static

Binds cLuaTCPLink::GetLocalIP.

Definition at line 373 of file ManualBindings_Network.cpp.

◆ tolua_cTCPLink_GetLocalPort()

static int tolua_cTCPLink_GetLocalPort ( lua_State *  L)
static

Binds cLuaTCPLink::GetLocalPort.

Definition at line 401 of file ManualBindings_Network.cpp.

◆ tolua_cTCPLink_GetRemoteIP()

static int tolua_cTCPLink_GetRemoteIP ( lua_State *  L)
static

Binds cLuaTCPLink::GetRemoteIP.

Definition at line 429 of file ManualBindings_Network.cpp.

◆ tolua_cTCPLink_GetRemotePort()

static int tolua_cTCPLink_GetRemotePort ( lua_State *  L)
static

Binds cLuaTCPLink::GetRemotePort.

Definition at line 457 of file ManualBindings_Network.cpp.

◆ tolua_cTCPLink_Send()

static int tolua_cTCPLink_Send ( lua_State *  L)
static

Binds cLuaTCPLink::Send.

Definition at line 485 of file ManualBindings_Network.cpp.

◆ tolua_cTCPLink_Shutdown()

static int tolua_cTCPLink_Shutdown ( lua_State *  L)
static

Binds cLuaTCPLink::Shutdown.

Definition at line 518 of file ManualBindings_Network.cpp.

◆ tolua_cTCPLink_StartTLSClient()

static int tolua_cTCPLink_StartTLSClient ( lua_State *  L)
static

Binds cLuaTCPLink::StartTLSClient.

Definition at line 546 of file ManualBindings_Network.cpp.

◆ tolua_cTCPLink_StartTLSServer()

static int tolua_cTCPLink_StartTLSServer ( lua_State *  L)
static

Binds cLuaTCPLink::StartTLSServer.

Definition at line 582 of file ManualBindings_Network.cpp.

◆ tolua_cUDPEndpoint_Close()

static int tolua_cUDPEndpoint_Close ( lua_State *  L)
static

Binds cLuaUDPEndpoint::Close.

Definition at line 642 of file ManualBindings_Network.cpp.

◆ tolua_cUDPEndpoint_EnableBroadcasts()

static int tolua_cUDPEndpoint_EnableBroadcasts ( lua_State *  L)
static

◆ tolua_cUDPEndpoint_GetPort()

static int tolua_cUDPEndpoint_GetPort ( lua_State *  L)
static

Binds cLuaUDPEndpoint::GetPort.

Definition at line 698 of file ManualBindings_Network.cpp.

◆ tolua_cUDPEndpoint_IsOpen()

static int tolua_cUDPEndpoint_IsOpen ( lua_State *  L)
static

Binds cLuaUDPEndpoint::IsOpen.

Definition at line 726 of file ManualBindings_Network.cpp.

◆ tolua_cUDPEndpoint_Send()

static int tolua_cUDPEndpoint_Send ( lua_State *  L)
static

Binds cLuaUDPEndpoint::Send.

Definition at line 754 of file ManualBindings_Network.cpp.

◆ tolua_cUrlClient_Delete()

static int tolua_cUrlClient_Delete ( lua_State *  a_LuaState)
static

Implements cUrlClient:Get() using cUrlClient::Request().

Definition at line 1018 of file ManualBindings_Network.cpp.

◆ tolua_cUrlClient_Get()

static int tolua_cUrlClient_Get ( lua_State *  a_LuaState)
static

Implements cUrlClient:Get() using cUrlClient::Request().

Definition at line 1033 of file ManualBindings_Network.cpp.

◆ tolua_cUrlClient_Post()

static int tolua_cUrlClient_Post ( lua_State *  a_LuaState)
static

Implements cUrlClient:Post() using cUrlClient::Request().

Definition at line 1048 of file ManualBindings_Network.cpp.

◆ tolua_cUrlClient_Put()

static int tolua_cUrlClient_Put ( lua_State *  a_LuaState)
static

Implements cUrlClient:Put() using cUrlClient::Request().

Definition at line 1063 of file ManualBindings_Network.cpp.

◆ tolua_cUrlClient_Request()

static int tolua_cUrlClient_Request ( lua_State *  a_LuaState)
static

Binds cUrlClient::Request().

Definition at line 1078 of file ManualBindings_Network.cpp.

◆ tolua_cUrlClient_Request_Common()

static int tolua_cUrlClient_Request_Common ( lua_State *  a_LuaState,
const AString a_Method,
int  a_UrlStackIdx 
)
static

Common code shared among the cUrlClient request methods.

a_Method is the method name to be used in the request. a_UrlStackIdx is the position on the Lua stack of the Url parameter.

Definition at line 951 of file ManualBindings_Network.cpp.