Search
Preparing search index...
The search index is not available
Sociably
Options
All
Public
Public/Protected
All
Inherited
Externals
Menu
Sociably
websocket/client
Connector
Class Connector<User>
Type parameters
User
:
null
|
SociablyUser
Hierarchy
Emitter
<
{
connect
:
any
;
disconnect
:
any
;
error
:
any
;
events
:
any
}
>
Connector
Index
Constructors
constructor
Properties
is
Closed
Methods
add
Listener
close
connect
emit
event
Names
get
Max
Listeners
is
Connected
listener
Count
listeners
off
on
once
prepend
Listener
prepend
Once
Listener
raw
Listeners
remove
All
Listeners
remove
Listener
send
set
Max
Listeners
Constructors
constructor
new
Connector
<
User
>
(
serverUrl
:
string
, login
:
ClientLoginFn
<
User
,
unknown
>
, marshaler
:
Marshaler
)
:
Connector
<
User
>
Type parameters
User
:
null
|
SociablyUser
Parameters
serverUrl:
string
login:
ClientLoginFn
<
User
,
unknown
>
marshaler:
Marshaler
Returns
Connector
<
User
>
Properties
is
Closed
is
Closed
:
boolean
Methods
add
Listener
add
Listener
<
E
>
(
event
:
E
, listener
:
{
connect
:
any
;
disconnect
:
any
;
error
:
any
;
events
:
any
}
[
E
]
)
:
Connector
<
User
>
Type parameters
E
:
"connect"
|
"events"
|
"disconnect"
|
"error"
Parameters
event:
E
listener:
{
connect
:
any
;
disconnect
:
any
;
error
:
any
;
events
:
any
}
[
E
]
Returns
Connector
<
User
>
close
close
(
code
?:
number
, reason
?:
string
)
:
void
Parameters
Optional
code:
number
Optional
reason:
string
Returns
void
connect
connect
(
)
:
void
Returns
void
emit
emit
<
E
>
(
event
:
E
,
...
args
:
Arguments
<
{
connect
:
any
;
disconnect
:
any
;
error
:
any
;
events
:
any
}
[
E
]
>
)
:
boolean
Type parameters
E
:
"connect"
|
"events"
|
"disconnect"
|
"error"
Parameters
event:
E
Rest
...
args:
Arguments
<
{
connect
:
any
;
disconnect
:
any
;
error
:
any
;
events
:
any
}
[
E
]
>
Returns
boolean
event
Names
event
Names
(
)
:
(
string
|
symbol
)
[]
Returns
(
string
|
symbol
)
[]
get
Max
Listeners
get
Max
Listeners
(
)
:
number
Returns
number
is
Connected
is
Connected
(
)
:
boolean
Returns
boolean
listener
Count
listener
Count
<
E
>
(
event
:
E
)
:
number
Type parameters
E
:
"connect"
|
"events"
|
"disconnect"
|
"error"
Parameters
event:
E
Returns
number
listeners
listeners
<
E
>
(
event
:
E
)
:
Function
[]
Type parameters
E
:
"connect"
|
"events"
|
"disconnect"
|
"error"
Parameters
event:
E
Returns
Function
[]
off
off
<
E
>
(
event
:
E
, listener
:
{
connect
:
any
;
disconnect
:
any
;
error
:
any
;
events
:
any
}
[
E
]
)
:
Connector
<
User
>
Type parameters
E
:
"connect"
|
"events"
|
"disconnect"
|
"error"
Parameters
event:
E
listener:
{
connect
:
any
;
disconnect
:
any
;
error
:
any
;
events
:
any
}
[
E
]
Returns
Connector
<
User
>
on
on
<
E
>
(
event
:
E
, listener
:
{
connect
:
any
;
disconnect
:
any
;
error
:
any
;
events
:
any
}
[
E
]
)
:
Connector
<
User
>
Type parameters
E
:
"connect"
|
"events"
|
"disconnect"
|
"error"
Parameters
event:
E
listener:
{
connect
:
any
;
disconnect
:
any
;
error
:
any
;
events
:
any
}
[
E
]
Returns
Connector
<
User
>
once
once
<
E
>
(
event
:
E
, listener
:
{
connect
:
any
;
disconnect
:
any
;
error
:
any
;
events
:
any
}
[
E
]
)
:
Connector
<
User
>
Type parameters
E
:
"connect"
|
"events"
|
"disconnect"
|
"error"
Parameters
event:
E
listener:
{
connect
:
any
;
disconnect
:
any
;
error
:
any
;
events
:
any
}
[
E
]
Returns
Connector
<
User
>
prepend
Listener
prepend
Listener
<
E
>
(
event
:
E
, listener
:
{
connect
:
any
;
disconnect
:
any
;
error
:
any
;
events
:
any
}
[
E
]
)
:
Connector
<
User
>
Type parameters
E
:
"connect"
|
"events"
|
"disconnect"
|
"error"
Parameters
event:
E
listener:
{
connect
:
any
;
disconnect
:
any
;
error
:
any
;
events
:
any
}
[
E
]
Returns
Connector
<
User
>
prepend
Once
Listener
prepend
Once
Listener
<
E
>
(
event
:
E
, listener
:
{
connect
:
any
;
disconnect
:
any
;
error
:
any
;
events
:
any
}
[
E
]
)
:
Connector
<
User
>
Type parameters
E
:
"connect"
|
"events"
|
"disconnect"
|
"error"
Parameters
event:
E
listener:
{
connect
:
any
;
disconnect
:
any
;
error
:
any
;
events
:
any
}
[
E
]
Returns
Connector
<
User
>
raw
Listeners
raw
Listeners
<
E
>
(
event
:
E
)
:
Function
[]
Type parameters
E
:
"connect"
|
"events"
|
"disconnect"
|
"error"
Parameters
event:
E
Returns
Function
[]
remove
All
Listeners
remove
All
Listeners
<
E
>
(
event
?:
E
)
:
Connector
<
User
>
Type parameters
E
:
"connect"
|
"events"
|
"disconnect"
|
"error"
Parameters
Optional
event:
E
Returns
Connector
<
User
>
remove
Listener
remove
Listener
<
E
>
(
event
:
E
, listener
:
{
connect
:
any
;
disconnect
:
any
;
error
:
any
;
events
:
any
}
[
E
]
)
:
Connector
<
User
>
Type parameters
E
:
"connect"
|
"events"
|
"disconnect"
|
"error"
Parameters
event:
E
listener:
{
connect
:
any
;
disconnect
:
any
;
error
:
any
;
events
:
any
}
[
E
]
Returns
Connector
<
User
>
send
send
(
events
:
EventInput
[]
)
:
Promise
<
void
>
Parameters
events:
EventInput
[]
Returns
Promise
<
void
>
set
Max
Listeners
set
Max
Listeners
(
maxListeners
:
number
)
:
Connector
<
User
>
Parameters
maxListeners:
number
Returns
Connector
<
User
>
Modules
auth
core
create-
app
dev-
tools
dialogflow
http
line
messenger
next
redis-
state
script
stream
telegram
twitter
websocket
webview
Connector
constructor
is
Closed
add
Listener
close
connect
emit
event
Names
get
Max
Listeners
is
Connected
listener
Count
listeners
off
on
once
prepend
Listener
prepend
Once
Listener
raw
Listeners
remove
All
Listeners
remove
Listener
send
set
Max
Listeners
Generated using
TypeDoc