Search
Preparing search index...
The search index is not available
DefinitelyTyped
Inherited
Private
Externals
Only exported
dgram
Socket
Interface Socket
Hierarchy
NodeEventEmitter
Socket
Index
Properties
address
Methods
addListener
addMembership
bind
close
dropMembership
emit
listeners
on
once
removeAllListener
removeListener
send
setBroadcast
setMaxListeners
setMulticastLoopback
setMulticastTTL
Properties
public
address
:
{ address: string; family: string; port: number; }
public
address.address
:
string
public
address.family
:
string
public
address.port
:
number
Methods
public
addListener
(
event
:
string
, listener
:
Function
)
:
any
Parameters
event:
string
listener:
Function
Returns
any
public
addMembership
(
multicastAddress
:
string
, multicastInterface
?:
string
)
Parameters
multicastAddress:
string
multicastInterface?:
string
optional
public
bind
(
port
:
number
, address
?:
string
)
Parameters
port:
number
address?:
string
optional
public
close
(
)
public
dropMembership
(
multicastAddress
:
string
, multicastInterface
?:
string
)
Parameters
multicastAddress:
string
multicastInterface?:
string
optional
public
emit
(
event
:
string
, arg1
?:
any
, arg2
?:
any
)
Parameters
event:
string
arg1?:
any
optional
arg2?:
any
optional
public
listeners
(
event
:
string
)
:
Array<{ Function: any; }>
Parameters
event:
string
Returns
Array<{ Function: any; }>
public
on
(
event
:
string
, listener
:
Function
)
:
any
Parameters
event:
string
listener:
Function
Returns
any
public
once
(
event
:
string
, listener
:
Function
)
Parameters
event:
string
listener:
Function
public
removeAllListener
(
event
:
string
)
Parameters
event:
string
public
removeListener
(
event
:
string
, listener
:
Function
)
Parameters
event:
string
listener:
Function
public
send
(
buf
:
Buffer
, offset
:
number
, length
:
number
, port
:
number
, address
:
string
, callback
?:
Function
)
Parameters
buf:
Buffer
offset:
number
length:
number
port:
number
address:
string
callback?:
Function
optional
public
setBroadcast
(
flag
:
boolean
)
Parameters
flag:
boolean
public
setMaxListeners
(
n
:
number
)
Parameters
n:
number
public
setMulticastLoopback
(
flag
:
boolean
)
Parameters
flag:
boolean
public
setMulticastTTL
(
ttl
:
number
)
Parameters
ttl:
number
Globals
assert
child_process
cluster
crypto
dgram
dns
domain
events
fs
http
https
net
os
path
punycode
querystring
readline
repl
stream
string_decoder
tls
tty
url
util
vm
zlib
Socket
address
addListener
addMembership
bind
close
dropMembership
emit
listeners
on
once
removeAllListener
removeListener
send
setBroadcast
setMaxListeners
setMulticastLoopback
setMulticastTTL
createSocket