Changes

Jump to navigation Jump to search
280 bytes added ,  14:25, 27 September 2018
|-
| width='120' | '''Signatures'''
|{{Func|ws:send|$message as xs:anyAtomicTypeitem(), $ids as xs:string*|empty-sequence()}}
|-
| '''Summary'''
|Sends a <code>$message</code>, which may be of type xs:string, xs:base64Binary or xs:hexBinary, to the clients with the specified <code>$ids</code>. Ids that cannot be assigned to clients will be ignored. The message will be handled as follows:* Items of type {{Code|xs:base64Binary}} and {{Code|xs:hexBinary}} will be transmitted as binary messages.* Function items (maps, arrays) will be serialized as JSON and transmitted as string messages.* All other items will be serialized with the default serialization options and transmitted as string messages.
|}
|-
| '''Summary'''
|Broadcasts a <code>$message</code>, which may be of type xs:string, xs:base64Binary or xs:hexBinary, to all connected clients except to the caller. Invocations of this convenience function are equivalent to <code>ws:send($message, ws:ids()[. != ws:id()])</code>. See [[#ws:send|ws:send]] for more details on the message handling.
|}
|-
| '''Summary'''
|Emits a <code>$message</code>, which may be of type xs:string, xs:base64Binary or xs:hexBinary, to all connected clients. Invocations of this function are equivalent to <code>ws:send($message, ws:ids())</code>. See [[#ws:send|ws:send]] for more details on the message handling.
|}
Bureaucrats, editor, reviewer, Administrators
12,226

edits

Navigation menu