<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>JSDoc: Namespace: jsxc</title>
<script src="scripts/prettify/prettify.js"> </script>
<script src="scripts/prettify/lang-css.js"> </script>
<!--[if lt IE 9]>
<script src="//html5shiv.googlecode.com/svn/trunk/html5.js"></script>
<![endif]-->
<link type="text/css" rel="stylesheet" href="styles/prettify-tomorrow.css">
<link type="text/css" rel="stylesheet" href="styles/jsdoc-default.css">
</head>
<body>
<div id="main">
<h1 class="page-title">Namespace: jsxc</h1>
<section>
<header>
<h2>jsxc</h2>
</header>
<article>
<div class="container-overview">
<div class="description">JavaScript Xmpp Chat namespace</div>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="jsxc.lib.js.html">jsxc.lib.js</a>, <a href="jsxc.lib.js.html#line1">line 1</a>
</li></ul></dd>
</dl>
</div>
<h3 class="subsection-title">Classes</h3>
<dl>
<dt><a href="jsxc.Message.html">Message</a></dt>
<dd></dd>
<dt><a href="jsxc.Message.html">Message</a></dt>
<dd></dd>
</dl>
<h3 class="subsection-title">Namespaces</h3>
<dl>
<dt><a href="jsxc.fileTransfer.html">fileTransfer</a></dt>
<dd></dd>
<dt><a href="jsxc.gui.html">gui</a></dt>
<dd></dd>
<dt><a href="jsxc.muc.html">muc</a></dt>
<dd></dd>
<dt><a href="jsxc.notification.html">notification</a></dt>
<dd></dd>
<dt><a href="jsxc.options.html">options</a></dt>
<dd></dd>
<dt><a href="jsxc.otr.html">otr</a></dt>
<dd></dd>
<dt><a href="jsxc.storage.html">storage</a></dt>
<dd></dd>
<dt><a href="jsxc.tab.html">tab</a></dt>
<dd></dd>
<dt><a href="jsxc.webrtc.html">webrtc</a></dt>
<dd></dd>
<dt><a href="jsxc.xmpp.html">xmpp</a></dt>
<dd></dd>
</dl>
<h3 class="subsection-title">Members</h3>
<h4 class="name" id=".bid"><span class="type-signature">(static) </span>bid<span class="type-signature"></span></h4>
<div class="description">
My bar id
</div>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="jsxc.lib.js.html">jsxc.lib.js</a>, <a href="jsxc.lib.js.html#line56">line 56</a>
</li></ul></dd>
</dl>
<h4 class="name" id=".CONST"><span class="type-signature">(static) </span>CONST<span class="type-signature"></span></h4>
<div class="description">
Some constants
</div>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="jsxc.lib.js.html">jsxc.lib.js</a>, <a href="jsxc.lib.js.html#line65">line 65</a>
</li></ul></dd>
</dl>
<h4 class="name" id=".currentState"><span class="type-signature">(static) </span>currentState<span class="type-signature"></span></h4>
<div class="description">
Current state
</div>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="jsxc.lib.js.html">jsxc.lib.js</a>, <a href="jsxc.lib.js.html#line59">line 59</a>
</li></ul></dd>
</dl>
<h4 class="name" id=".currentUIState"><span class="type-signature">(static) </span>currentUIState<span class="type-signature"></span></h4>
<div class="description">
Current UI state
</div>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="jsxc.lib.js.html">jsxc.lib.js</a>, <a href="jsxc.lib.js.html#line62">line 62</a>
</li></ul></dd>
</dl>
<h4 class="name" id=".keepaliveInterval"><span class="type-signature">(static) </span>keepaliveInterval<span class="type-signature"></span></h4>
<div class="description">
Interval for keep-alive
</div>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="jsxc.lib.js.html">jsxc.lib.js</a>, <a href="jsxc.lib.js.html#line29">line 29</a>
</li></ul></dd>
</dl>
<h4 class="name" id=".log"><span class="type-signature">(static) </span>log<span class="type-signature"></span></h4>
<div class="description">
debug log
</div>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="jsxc.lib.js.html">jsxc.lib.js</a>, <a href="jsxc.lib.js.html#line192">line 192</a>
</li></ul></dd>
</dl>
<h4 class="name" id=".ls"><span class="type-signature">(static) </span>ls<span class="type-signature"></span></h4>
<div class="description">
last values which we wrote into localstorage (IE workaround)
</div>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="jsxc.lib.js.html">jsxc.lib.js</a>, <a href="jsxc.lib.js.html#line44">line 44</a>
</li></ul></dd>
</dl>
<h4 class="name" id=".master"><span class="type-signature">(static) </span>master<span class="type-signature"></span></h4>
<div class="description">
True if i'm the master
</div>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="jsxc.lib.js.html">jsxc.lib.js</a>, <a href="jsxc.lib.js.html#line11">line 11</a>
</li></ul></dd>
</dl>
<h4 class="name" id=".notice"><span class="type-signature">(static) </span>notice<span class="type-signature"></span></h4>
<div class="description">
This namespace handle the notice system.
</div>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="jsxc.lib.notice.js.html">jsxc.lib.notice.js</a>, <a href="jsxc.lib.notice.js.html#line7">line 7</a>
</li></ul></dd>
</dl>
<h4 class="name" id=".restoreCompleted"><span class="type-signature">(static) </span>restoreCompleted<span class="type-signature"></span></h4>
<div class="description">
True if restore is complete
</div>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="jsxc.lib.js.html">jsxc.lib.js</a>, <a href="jsxc.lib.js.html#line32">line 32</a>
</li></ul></dd>
</dl>
<h4 class="name" id=".role_allocation"><span class="type-signature">(static) </span>role_allocation<span class="type-signature"></span></h4>
<div class="description">
True if the role allocation is finished
</div>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="jsxc.lib.js.html">jsxc.lib.js</a>, <a href="jsxc.lib.js.html#line14">line 14</a>
</li></ul></dd>
</dl>
<h4 class="name" id=".storageNotConform"><span class="type-signature">(static) </span>storageNotConform<span class="type-signature"></span></h4>
<div class="description">
storage event is even fired if I write something into storage (IE
workaround) 0: conform, 1: not conform, 2: not shure
</div>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="jsxc.lib.js.html">jsxc.lib.js</a>, <a href="jsxc.lib.js.html#line50">line 50</a>
</li></ul></dd>
</dl>
<h4 class="name" id=".to"><span class="type-signature">(static) </span>to<span class="type-signature"></span></h4>
<div class="description">
Timeout for keepalive
</div>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="jsxc.lib.js.html">jsxc.lib.js</a>, <a href="jsxc.lib.js.html#line17">line 17</a>
</li></ul></dd>
</dl>
<h4 class="name" id=".toBusy"><span class="type-signature">(static) </span>toBusy<span class="type-signature"></span></h4>
<div class="description">
Timeout after normal keepalive starts
</div>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="jsxc.lib.js.html">jsxc.lib.js</a>, <a href="jsxc.lib.js.html#line20">line 20</a>
</li></ul></dd>
</dl>
<h4 class="name" id=".toNotification"><span class="type-signature">(static) </span>toNotification<span class="type-signature"></span></h4>
<div class="description">
Timeout for notification
</div>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="jsxc.lib.js.html">jsxc.lib.js</a>, <a href="jsxc.lib.js.html#line23">line 23</a>
</li></ul></dd>
</dl>
<h4 class="name" id=".toNotificationDelay"><span class="type-signature">(static) </span>toNotificationDelay<span class="type-signature"></span></h4>
<div class="description">
Timeout delay for notification
</div>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="jsxc.lib.js.html">jsxc.lib.js</a>, <a href="jsxc.lib.js.html#line26">line 26</a>
</li></ul></dd>
</dl>
<h4 class="name" id=".toSNC"><span class="type-signature">(static) </span>toSNC<span class="type-signature"></span></h4>
<div class="description">
Timeout for storageNotConform test
</div>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="jsxc.lib.js.html">jsxc.lib.js</a>, <a href="jsxc.lib.js.html#line53">line 53</a>
</li></ul></dd>
</dl>
<h4 class="name" id=".triggeredFromBox"><span class="type-signature">(static) </span>triggeredFromBox<span class="type-signature"></span></h4>
<div class="description">
True if login through box
</div>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="jsxc.lib.js.html">jsxc.lib.js</a>, <a href="jsxc.lib.js.html#line35">line 35</a>
</li></ul></dd>
</dl>
<h4 class="name" id=".triggeredFromElement"><span class="type-signature">(static) </span>triggeredFromElement<span class="type-signature"></span></h4>
<div class="description">
True if logout through element click
</div>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="jsxc.lib.js.html">jsxc.lib.js</a>, <a href="jsxc.lib.js.html#line38">line 38</a>
</li></ul></dd>
</dl>
<h4 class="name" id=".triggeredFromLogout"><span class="type-signature">(static) </span>triggeredFromLogout<span class="type-signature"></span></h4>
<div class="description">
True if logout through logout click
</div>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="jsxc.lib.js.html">jsxc.lib.js</a>, <a href="jsxc.lib.js.html#line41">line 41</a>
</li></ul></dd>
</dl>
<h4 class="name" id=".version"><span class="type-signature">(static) </span>version<span class="type-signature"></span></h4>
<div class="description">
Version of jsxc
</div>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="jsxc.lib.js.html">jsxc.lib.js</a>, <a href="jsxc.lib.js.html#line8">line 8</a>
</li></ul></dd>
</dl>
<h3 class="subsection-title">Methods</h3>
<h4 class="name" id=".checkMaster"><span class="type-signature">(static) </span>checkMaster<span class="signature">(cb<span class="signature-attributes">opt</span>)</span><span class="type-signature"></span></h4>
<div class="description">
Checks if there is a master
</div>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th>Attributes</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>cb</code></td>
<td class="type">
<span class="param-type">function</span>
</td>
<td class="attributes">
<optional><br>
</td>
<td class="description last">Called if no master was found.</td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="jsxc.lib.js.html">jsxc.lib.js</a>, <a href="jsxc.lib.js.html#line757">line 757</a>
</li></ul></dd>
</dl>
<h4 class="name" id=".debug"><span class="type-signature">(static) </span>debug<span class="signature">(msg, data, Could)</span><span class="type-signature"></span></h4>
<div class="description">
Write debug message to console and to log.
</div>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>msg</code></td>
<td class="type">
<span class="param-type">String</span>
</td>
<td class="description last">Debug message</td>
</tr>
<tr>
<td class="name"><code>data</code></td>
<td class="type">
<span class="param-type">Object</span>
</td>
<td class="description last"></td>
</tr>
<tr>
<td class="name"><code>Could</code></td>
<td class="type">
<span class="param-type">String</span>
</td>
<td class="description last">be warn|error|null</td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="jsxc.lib.js.html">jsxc.lib.js</a>, <a href="jsxc.lib.js.html#line139">line 139</a>
</li></ul></dd>
</dl>
<h4 class="name" id=".el_exists"><span class="type-signature">(static) </span>el_exists<span class="signature">(selector)</span><span class="type-signature"> → {Boolean}</span></h4>
<div class="description">
Checks if there is a element with the given selector
</div>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>selector</code></td>
<td class="type">
<span class="param-type">String</span>
</td>
<td class="description last">jQuery selector</td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="jsxc.lib.js.html">jsxc.lib.js</a>, <a href="jsxc.lib.js.html#line848">line 848</a>
</li></ul></dd>
</dl>
<h5>Returns:</h5>
<dl>
<dt>
Type
</dt>
<dd>
<span class="param-type">Boolean</span>
</dd>
</dl>
<h4 class="name" id=".error"><span class="type-signature">(static) </span>error<span class="signature">(msg, data)</span><span class="type-signature"></span></h4>
<div class="description">
Write error message.
</div>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>msg</code></td>
<td class="type">
<span class="param-type">String</span>
</td>
<td class="description last">Error message</td>
</tr>
<tr>
<td class="name"><code>data</code></td>
<td class="type">
<span class="param-type">Object</span>
</td>
<td class="description last"></td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="jsxc.lib.js.html">jsxc.lib.js</a>, <a href="jsxc.lib.js.html#line187">line 187</a>
</li></ul></dd>
</dl>
<h4 class="name" id=".escapeHTML"><span class="type-signature">(static) </span>escapeHTML<span class="signature">()</span><span class="type-signature"></span></h4>
<div class="description">
Escapes some characters to HTML character
</div>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="jsxc.lib.js.html">jsxc.lib.js</a>, <a href="jsxc.lib.js.html#line955">line 955</a>
</li></ul></dd>
</dl>
<h4 class="name" id=".exec"><span class="type-signature">(static) </span>exec<span class="signature">(fnName, fnParams)</span><span class="type-signature"></span></h4>
<div class="description">
Executes the given function in jsxc namespace.
</div>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>fnName</code></td>
<td class="type">
<span class="param-type">string</span>
</td>
<td class="description last">Function name</td>
</tr>
<tr>
<td class="name"><code>fnParams</code></td>
<td class="type">
<span class="param-type">array</span>
</td>
<td class="description last">Function parameters</td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="jsxc.lib.js.html">jsxc.lib.js</a>, <a href="jsxc.lib.js.html#line1050">line 1050</a>
</li></ul></dd>
</dl>
<h5>Returns:</h5>
<div class="param-desc">
Function return value
</div>
<h4 class="name" id=".getFormattedTime"><span class="type-signature">(static) </span>getFormattedTime<span class="signature">(unixtime)</span><span class="type-signature"></span></h4>
<div class="description">
Parse a unix timestamp and return a formatted time string
</div>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>unixtime</code></td>
<td class="type">
<span class="param-type">Object</span>
</td>
<td class="description last"></td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="jsxc.lib.js.html">jsxc.lib.js</a>, <a href="jsxc.lib.js.html#line109">line 109</a>
</li></ul></dd>
</dl>
<h5>Returns:</h5>
<div class="param-desc">
time of day and/or date
</div>
<h4 class="name" id=".hasFocus"><span class="type-signature">(static) </span>hasFocus<span class="signature">()</span><span class="type-signature"> → {boolean}</span></h4>
<div class="description">
Checks if tab has focus.
</div>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="jsxc.lib.js.html">jsxc.lib.js</a>, <a href="jsxc.lib.js.html#line1026">line 1026</a>
</li></ul></dd>
</dl>
<h5>Returns:</h5>
<div class="param-desc">
True if tabs has focus
</div>
<dl>
<dt>
Type
</dt>
<dd>
<span class="param-type">boolean</span>
</dd>
</dl>
<h4 class="name" id=".hashStr"><span class="type-signature">(static) </span>hashStr<span class="signature">(str)</span><span class="type-signature"> → {integer}</span></h4>
<div class="description">
Hash string into 32-bit signed integer.
</div>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>str</code></td>
<td class="type">
<span class="param-type">string</span>
</td>
<td class="description last">input string</td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="jsxc.lib.js.html">jsxc.lib.js</a>, <a href="jsxc.lib.js.html#line1070">line 1070</a>
</li></ul></dd>
</dl>
<h5>Returns:</h5>
<div class="param-desc">
32-bit signed integer
</div>
<dl>
<dt>
Type
</dt>
<dd>
<span class="param-type">integer</span>
</dd>
</dl>
<h4 class="name" id=".init"><span class="type-signature">(static) </span>init<span class="signature">(options)</span><span class="type-signature"></span></h4>
<div class="description">
This function initializes important core functions and event handlers.
Afterwards it performs the following actions in the given order:
<ol>
<li>If (loginForm.ifFound = 'force' and form was found) or (jid or rid or
sid was not found) intercept form, and listen for credentials.</li>
<li>Attach with jid, rid and sid from storage, if no form was found or
loginForm.ifFound = 'attach'</li>
<li>Attach with jid, rid and sid from options.xmpp, if no form was found or
loginForm.ifFound = 'attach'</li>
</ol>
</div>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>options</code></td>
<td class="type">
<span class="param-type">object</span>
</td>
<td class="description last">See <a href="jsxc.options.html">jsxc.options</a></td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="jsxc.lib.js.html">jsxc.lib.js</a>, <a href="jsxc.lib.js.html#line210">line 210</a>
</li></ul></dd>
</dl>
<h4 class="name" id=".isHidden"><span class="type-signature">(static) </span>isHidden<span class="signature">()</span><span class="type-signature"> → {boolean}</span></h4>
<div class="description">
Checks if tab is hidden.
</div>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="jsxc.lib.js.html">jsxc.lib.js</a>, <a href="jsxc.lib.js.html#line998">line 998</a>
</li></ul></dd>
</dl>
<h5>Returns:</h5>
<div class="param-desc">
True if tab is hidden
</div>
<dl>
<dt>
Type
</dt>
<dd>
<span class="param-type">boolean</span>
</dd>
</dl>
<h4 class="name" id=".isLoginForm"><span class="type-signature">(static) </span>isLoginForm<span class="signature">()</span><span class="type-signature"> → {boolean}</span></h4>
<div class="description">
Returns true if login form is found.
</div>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="jsxc.lib.js.html">jsxc.lib.js</a>, <a href="jsxc.lib.js.html#line595">line 595</a>
</li></ul></dd>
</dl>
<h5>Returns:</h5>
<div class="param-desc">
True if login form was found.
</div>
<dl>
<dt>
Type
</dt>
<dd>
<span class="param-type">boolean</span>
</dd>
</dl>
<h4 class="name" id=".jidToBid"><span class="type-signature">(static) </span>jidToBid<span class="signature">(jid)</span><span class="type-signature"></span></h4>
<div class="description">
Create comparable bar jid.
</div>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>jid</code></td>
<td class="type">
</td>
<td class="description last"></td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="jsxc.lib.js.html">jsxc.lib.js</a>, <a href="jsxc.lib.js.html#line873">line 873</a>
</li></ul></dd>
</dl>
<h5>Returns:</h5>
<div class="param-desc">
comparable bar jid
</div>
<h4 class="name" id=".jidToCid"><span class="type-signature">(static) </span>jidToCid<span class="signature">(jid)</span><span class="type-signature"> → {String}</span></h4>
<div class="description">
Creates a CSS compatible string from a JID
</div>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>jid</code></td>
<td class="type">
<span class="param-type">type</span>
</td>
<td class="description last">Valid Jabber ID</td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="jsxc.lib.js.html">jsxc.lib.js</a>, <a href="jsxc.lib.js.html#line858">line 858</a>
</li></ul></dd>
</dl>
<h5>Returns:</h5>
<div class="param-desc">
css Compatible string
</div>
<dl>
<dt>
Type
</dt>
<dd>
<span class="param-type">String</span>
</dd>
</dl>
<h4 class="name" id=".keepAlive"><span class="type-signature">(static) </span>keepAlive<span class="signature">()</span><span class="type-signature"></span></h4>
<div class="description">
Sends the keep-alive signal to signal that the master is still there.
</div>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="jsxc.lib.js.html">jsxc.lib.js</a>, <a href="jsxc.lib.js.html#line808">line 808</a>
</li></ul></dd>
</dl>
<h4 class="name" id=".keepBusyAlive"><span class="type-signature">(static) </span>keepBusyAlive<span class="signature">()</span><span class="type-signature"></span></h4>
<div class="description">
Send one keep-alive signal with higher timeout, and than resume with
normal signal
</div>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="jsxc.lib.js.html">jsxc.lib.js</a>, <a href="jsxc.lib.js.html#line819">line 819</a>
</li></ul></dd>
</dl>
<h4 class="name" id=".onMaster"><span class="type-signature">(static) </span>onMaster<span class="signature">()</span><span class="type-signature"></span></h4>
<div class="description">
Called if the script is the master
</div>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="jsxc.lib.js.html">jsxc.lib.js</a>, <a href="jsxc.lib.js.html#line735">line 735</a>
</li></ul></dd>
</dl>
<h4 class="name" id=".onSlave"><span class="type-signature">(static) </span>onSlave<span class="signature">()</span><span class="type-signature"></span></h4>
<div class="description">
Called if the script is a slave
</div>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="jsxc.lib.js.html">jsxc.lib.js</a>, <a href="jsxc.lib.js.html#line717">line 717</a>
</li></ul></dd>
</dl>
<h4 class="name" id=".prepareLogin"><span class="type-signature">(static) </span>prepareLogin<span class="signature">(username, password, cb)</span><span class="type-signature"></span></h4>
<div class="description">
Load settings and prepare jid.
</div>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>username</code></td>
<td class="type">
<span class="param-type">string</span>
</td>
<td class="description last"></td>
</tr>
<tr>
<td class="name"><code>password</code></td>
<td class="type">
<span class="param-type">string</span>
</td>
<td class="description last"></td>
</tr>
<tr>
<td class="name"><code>cb</code></td>
<td class="type">
<span class="param-type">function</span>
</td>
<td class="description last">Called after login is prepared with result as param</td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="jsxc.lib.js.html">jsxc.lib.js</a>, <a href="jsxc.lib.js.html#line607">line 607</a>
</li></ul></dd>
</dl>
<h4 class="name" id=".random"><span class="type-signature">(static) </span>random<span class="signature">(max)</span><span class="type-signature"> → {Integer}</span></h4>
<div class="description">
Generates a random integer number between 0 and max
</div>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>max</code></td>
<td class="type">
<span class="param-type">Integer</span>
</td>
<td class="description last"></td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="jsxc.lib.js.html">jsxc.lib.js</a>, <a href="jsxc.lib.js.html#line838">line 838</a>
</li></ul></dd>
</dl>
<h5>Returns:</h5>
<div class="param-desc">
random integer between 0 and max
</div>
<dl>
<dt>
Type
</dt>
<dd>
<span class="param-type">Integer</span>
</dd>
</dl>
<h4 class="name" id=".removeHTML"><span class="type-signature">(static) </span>removeHTML<span class="signature">(text)</span><span class="type-signature"></span></h4>
<div class="description">
Removes all html tags.
</div>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>text</code></td>
<td class="type">
</td>
<td class="description last"></td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="jsxc.lib.js.html">jsxc.lib.js</a>, <a href="jsxc.lib.js.html#line967">line 967</a>
</li></ul></dd>
</dl>
<h5>Returns:</h5>
<div class="param-desc">
stripped text
</div>
<h4 class="name" id=".restoreRoster"><span class="type-signature">(static) </span>restoreRoster<span class="signature">()</span><span class="type-signature"></span></h4>
<div class="description">
Restore roster
</div>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="jsxc.lib.js.html">jsxc.lib.js</a>, <a href="jsxc.lib.js.html#line880">line 880</a>
</li></ul></dd>
</dl>
<h4 class="name" id=".restoreWindows"><span class="type-signature">(static) </span>restoreWindows<span class="signature">()</span><span class="type-signature"></span></h4>
<div class="description">
Restore all windows
</div>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="jsxc.lib.js.html">jsxc.lib.js</a>, <a href="jsxc.lib.js.html#line902">line 902</a>
</li></ul></dd>
</dl>
<h4 class="name" id=".start"><span class="type-signature">(static) </span>start<span class="signature">(jid, sid, rid)</span><span class="type-signature"></span></h4>
<div class="description">
Attach to new chat session with jid, sid and rid.
</div>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>jid</code></td>
<td class="type">
<span class="param-type">string</span>
</td>
<td class="description last">Jabber Id</td>
</tr>
<tr>
<td class="name"><code>sid</code></td>
<td class="type">
<span class="param-type">string</span>
</td>
<td class="description last">Session Id</td>
</tr>
<tr>
<td class="name"><code>rid</code></td>
<td class="type">
<span class="param-type">string</span>
</td>
<td class="description last">Request Id</td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="jsxc.lib.js.html">jsxc.lib.js</a>, <a href="jsxc.lib.js.html#line460">line 460</a>
</li></ul></dd>
</dl>
<h4 class="name" id=".startKeepAlive"><span class="type-signature">(static) </span>startKeepAlive<span class="signature">()</span><span class="type-signature"></span></h4>
<div class="description">
Start sending keep-alive signal
</div>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="jsxc.lib.js.html">jsxc.lib.js</a>, <a href="jsxc.lib.js.html#line801">line 801</a>
</li></ul></dd>
</dl>
<h4 class="name" id=".submitLoginForm"><span class="type-signature">(static) </span>submitLoginForm<span class="signature">()</span><span class="type-signature"></span></h4>
<div class="description">
This method submits the specified login form.
</div>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="jsxc.lib.js.html">jsxc.lib.js</a>, <a href="jsxc.lib.js.html#line932">line 932</a>
</li></ul></dd>
</dl>
<h4 class="name" id=".switchEvents"><span class="type-signature">(static) </span>switchEvents<span class="signature">()</span><span class="type-signature"> → {string}</span></h4>
<div class="description">
Executes only one of the given events
</div>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>obj.key</code></td>
<td class="type">
<span class="param-type">string</span>
</td>
<td class="description last">event name</td>
</tr>
<tr>
<td class="name"><code>obj.value</code></td>
<td class="type">
<span class="param-type">function</span>
</td>
<td class="description last">function to execute</td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="jsxc.lib.js.html">jsxc.lib.js</a>, <a href="jsxc.lib.js.html#line978">line 978</a>
</li></ul></dd>
</dl>
<h5>Returns:</h5>
<div class="param-desc">
namespace of all events
</div>
<dl>
<dt>
Type
</dt>
<dd>
<span class="param-type">string</span>
</dd>
</dl>
<h4 class="name" id=".warn"><span class="type-signature">(static) </span>warn<span class="signature">(msg, data)</span><span class="type-signature"></span></h4>
<div class="description">
Write warn message.
</div>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>msg</code></td>
<td class="type">
<span class="param-type">String</span>
</td>
<td class="description last">Warn message</td>
</tr>
<tr>
<td class="name"><code>data</code></td>
<td class="type">
<span class="param-type">Object</span>
</td>
<td class="description last"></td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="jsxc.lib.js.html">jsxc.lib.js</a>, <a href="jsxc.lib.js.html#line176">line 176</a>
</li></ul></dd>
</dl>
</article>
</section>
</div>
<nav>
<h2><a href="index.html">Home</a></h2><h3>Classes</h3><ul><li><a href="jsxc.Message.html">Message</a></li></ul><h3>Namespaces</h3><ul><li><a href="jsxc.html">jsxc</a></li><li><a href="jsxc.fileTransfer.html">fileTransfer</a></li><li><a href="jsxc.gui.html">gui</a></li><li><a href="jsxc.gui.dialog.html">dialog</a></li><li><a href="jsxc.gui.queryActions.html">queryActions</a></li><li><a href="jsxc.gui.roster.html">roster</a></li><li><a href="jsxc.gui.window.html">window</a></li><li><a href="jsxc.muc.html">muc</a></li><li><a href="jsxc.notification.html">notification</a></li><li><a href="jsxc.options.html">options</a></li><li><a href="jsxc.otr.html">otr</a></li><li><a href="jsxc.storage.html">storage</a></li><li><a href="jsxc.tab.html">tab</a></li><li><a href="jsxc.webrtc.html">webrtc</a></li><li><a href="jsxc.xmpp.html">xmpp</a></li><li><a href="jsxc.xmpp.bookmarks.html">bookmarks</a></li><li><a href="jsxc.xmpp.carbons.html">carbons</a></li><li><a href="jsxc.xmpp.chatState.html">chatState</a></li><li><a href="jsxc.xmpp.httpUpload.html">httpUpload</a></li><li><a href="jsxc.xmpp.mam.html">mam</a></li></ul><h3><a href="global.html">Global</a></h3>
</nav>
<br class="clear">
<footer>
Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 3.5.5</a> on Fri May 10 2019 12:36:11 GMT+0200 (Central European Summer Time)
</footer>
<script> prettyPrint(); </script>
<script src="scripts/linenumber.js"> </script>
</body>
</html>
|