Property | Type | Description | |
---|---|---|---|
$defaultPort | integer | Default port | |
$host | string | Hostname | |
$listenerMode | boolean | Listener mode? | |
$port | integer | Port | |
$portsMap | Ports map | ||
$reuse | boolean | Reuse? |
Method | Description | |
---|---|---|
bindSocket ( ) : boolean | Bind given addreess | |
enable ( ) : void | Enable socket events | |
onReadUdp ( resource $stream = null, integer $events, mixed $arg = null ) : boolean | Called when we got UDP packet | |
sendTo ( string $data, integer $flags, string $host, integer $port ) : integer | Send UDP packet | |
setDefaultPort ( integer $port ) : void | Sets default port | |
setReuse ( integer $reuse = true ) : void | Sets reuse | |
unassignAddr ( string $addr ) : void | Unassigns addr |
Method | Description | |
---|---|---|
onBound ( ) : boolean | Called when socket is bound |
public bindSocket ( ) : boolean | ||
return | boolean | Success. |
public setDefaultPort ( integer $port ) : void | ||
$port | integer | Port |
return | void |
public unassignAddr ( string $addr ) : void | ||
$addr | string | Address |
return | void |