![]() |
Murl Engine Lua Addon API
Version 1.0 beta
|
The socket address interface.
GetIpAddress() and GetPortNumber() returns the values set by SetIpAddress(), SetPortNumber(), SetAnyAddress(), SetBroadcastAddress() and SetLoopbackAddress() only.
The SetResolveHostName() method is safe to be used in the logic code. The ip-address is evaluated later by MakeSystemAddress().
GetHostName() returns the string set by SetResolveHostName() until MakeSystemAddress() evaluates the ip-address, which replaces the host name by the "real" name used for evaluation. The Net::ISocketClient and Net::ISocketServer implementation makes copies of all address objects, so that addresses passed to these classes are not affected by this mechanism.
(!) Do not use MakeSystemAddress() directly in the logic code, this method will wait for network response and is intend for internal socket implementation only.
Get the ip-address. The ip-address format is 0xaabbccdd for "aaa.bbb.ccc.ddd".
Integer GetIpAddress()
Get the port number.
Integer GetPortNumber()
Get the host name.
String GetHostName()
Get the dot notation string of the ip-address.
String GetDotNotation()
Get the dot notation string of the ip-address and the port.
String GetDotPortNotation()
Set the ip-address. Additionally the host name is set to the dot-notation of the ip-address. The ip-address format is 0xaabbccdd for "aaa.bbb.ccc.ddd".
SetIpAddress(Integer ipAddress)
ipAddress | The ip-address. |
Set the port number.
SetPortNumber(Integer portNumber)
portNumber | The port number. |
Set to the any ip-address (0.0.0.0). This is the default address for new address objects.
SetAnyAddress()
Set to the broadcast ip-address (255.255.255.255).
SetBroadcastAddress()
Set to the loopback ip-address (127.0.0.1).
SetLoopbackAddress()
Copy the address information.
CopyAddress(Murl.SharedPointer.NetISocketAddressConst address)
address | The source address object. |
Set the host name for resolving. An empty string resolves the local host.
SetResolveHostName(String hostName)
hostName | The host name. The host name can be specified by the domain name or the dot notation e.g. "127.0.0.1". If the host name is empty, the local ip-address is used. |
Converts the object content to a string in a reasonable format.