1668 lines
35 KiB
HTML
1668 lines
35 KiB
HTML
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
|
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
|
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
|
|
<head>
|
|
<meta http-equiv="content-type" content="text/html; charset=utf-8" />
|
|
<meta name="generator" content="JsDoc Toolkit" />
|
|
|
|
<title>JsDoc Reference - _global_</title>
|
|
|
|
<style type="text/css">
|
|
/* default.css */
|
|
body
|
|
{
|
|
font: 12px "Lucida Grande", Tahoma, Arial, Helvetica, sans-serif;
|
|
width: 800px;
|
|
}
|
|
|
|
.header
|
|
{
|
|
clear: both;
|
|
background-color: #ccc;
|
|
padding: 8px;
|
|
}
|
|
|
|
h1
|
|
{
|
|
font-size: 150%;
|
|
font-weight: bold;
|
|
padding: 0;
|
|
margin: 1em 0 0 .3em;
|
|
}
|
|
|
|
hr
|
|
{
|
|
border: none 0;
|
|
border-top: 1px solid #7F8FB1;
|
|
height: 1px;
|
|
}
|
|
|
|
pre.code
|
|
{
|
|
display: block;
|
|
padding: 8px;
|
|
border: 1px dashed #ccc;
|
|
}
|
|
|
|
#index
|
|
{
|
|
margin-top: 24px;
|
|
float: left;
|
|
width: 160px;
|
|
position: absolute;
|
|
left: 8px;
|
|
background-color: #F3F3F3;
|
|
padding: 8px;
|
|
}
|
|
|
|
#content
|
|
{
|
|
margin-left: 190px;
|
|
width: 600px;
|
|
}
|
|
|
|
.classList
|
|
{
|
|
list-style-type: none;
|
|
padding: 0;
|
|
margin: 0 0 0 8px;
|
|
font-family: arial, sans-serif;
|
|
font-size: 1em;
|
|
overflow: auto;
|
|
}
|
|
|
|
.classList li
|
|
{
|
|
padding: 0;
|
|
margin: 0 0 8px 0;
|
|
}
|
|
|
|
.summaryTable { width: 100%; }
|
|
|
|
h1.classTitle
|
|
{
|
|
font-size:170%;
|
|
line-height:130%;
|
|
}
|
|
|
|
h2 { font-size: 110%; }
|
|
caption, div.sectionTitle
|
|
{
|
|
background-color: #7F8FB1;
|
|
color: #fff;
|
|
font-size:130%;
|
|
text-align: left;
|
|
padding: 2px 6px 2px 6px;
|
|
border: 1px #7F8FB1 solid;
|
|
}
|
|
|
|
div.sectionTitle { margin-bottom: 8px; }
|
|
.summaryTable thead { display: none; }
|
|
|
|
.summaryTable td
|
|
{
|
|
vertical-align: top;
|
|
padding: 4px;
|
|
border-bottom: 1px #7F8FB1 solid;
|
|
border-right: 1px #7F8FB1 solid;
|
|
}
|
|
|
|
/*col#summaryAttributes {}*/
|
|
.summaryTable td.attributes
|
|
{
|
|
border-left: 1px #7F8FB1 solid;
|
|
width: 140px;
|
|
text-align: right;
|
|
}
|
|
|
|
td.attributes, .fixedFont
|
|
{
|
|
line-height: 15px;
|
|
color: #002EBE;
|
|
font-family: "Courier New",Courier,monospace;
|
|
font-size: 13px;
|
|
}
|
|
|
|
.summaryTable td.nameDescription
|
|
{
|
|
text-align: left;
|
|
font-size: 13px;
|
|
line-height: 15px;
|
|
}
|
|
|
|
.summaryTable td.nameDescription, .description
|
|
{
|
|
line-height: 15px;
|
|
padding: 4px;
|
|
padding-left: 4px;
|
|
}
|
|
|
|
.summaryTable { margin-bottom: 8px; }
|
|
|
|
ul.inheritsList
|
|
{
|
|
list-style: square;
|
|
margin-left: 20px;
|
|
padding-left: 0;
|
|
}
|
|
|
|
.detailList {
|
|
margin-left: 20px;
|
|
line-height: 15px;
|
|
}
|
|
.detailList dt { margin-left: 20px; }
|
|
|
|
.detailList .heading
|
|
{
|
|
font-weight: bold;
|
|
padding-bottom: 6px;
|
|
margin-left: 0;
|
|
}
|
|
|
|
.light, td.attributes, .light a:link, .light a:visited
|
|
{
|
|
color: #777;
|
|
font-style: italic;
|
|
}
|
|
|
|
.fineprint
|
|
{
|
|
text-align: right;
|
|
font-size: 10px;
|
|
}
|
|
</style>
|
|
</head>
|
|
|
|
<body>
|
|
<!-- ============================== header ================================= -->
|
|
<!-- begin static/header.html -->
|
|
<div id="header">
|
|
</div>
|
|
<!-- end static/header.html -->
|
|
|
|
<!-- ============================== classes index ============================ -->
|
|
<div id="index">
|
|
<!-- begin publish.classesIndex -->
|
|
<div align="center"><a href="../index.html">Class Index</a>
|
|
| <a href="../files.html">File Index</a></div>
|
|
<hr />
|
|
<h2>Classes</h2>
|
|
<ul class="classList">
|
|
|
|
<li><i><a href="../symbols/_global_.html">_global_</a></i></li>
|
|
|
|
</ul>
|
|
<hr />
|
|
<!-- end publish.classesIndex -->
|
|
</div>
|
|
|
|
<div id="content">
|
|
<!-- ============================== class title ============================ -->
|
|
<h1 class="classTitle">
|
|
|
|
Built-In Namespace _global_
|
|
</h1>
|
|
|
|
<!-- ============================== class summary ========================== -->
|
|
<p class="description">
|
|
|
|
|
|
|
|
|
|
|
|
|
|
</p>
|
|
|
|
<!-- ============================== constructor summary ==================== -->
|
|
|
|
|
|
<!-- ============================== properties summary ===================== -->
|
|
|
|
|
|
|
|
<table class="summaryTable" cellspacing="0" summary="A summary of the fields documented in the class _global_.">
|
|
<caption>Field Summary</caption>
|
|
<thead>
|
|
<tr>
|
|
<th scope="col">Field Attributes</th>
|
|
<th scope="col">Field Name and Description</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody>
|
|
|
|
<tr>
|
|
<td class="attributes"> </td>
|
|
<td class="nameDescription">
|
|
<div class="fixedFont">
|
|
<b><a href="../symbols/_global_.html#AttributePoolFactory">AttributePoolFactory</a></b>
|
|
</div>
|
|
<div class="description">Copyright 2009 Google Inc.</div>
|
|
</td>
|
|
</tr>
|
|
|
|
<tr>
|
|
<td class="attributes"> </td>
|
|
<td class="nameDescription">
|
|
<div class="fixedFont">
|
|
<b><a href="../symbols/_global_.html#Changeset">Changeset</a></b>
|
|
</div>
|
|
<div class="description">2011 Peter 'Pita' Martischka
|
|
|
|
Licensed under the Apache License, Version 2.0 (the "License");
|
|
you may not use this file except in compliance with the License.</div>
|
|
</td>
|
|
</tr>
|
|
|
|
<tr>
|
|
<td class="attributes"> </td>
|
|
<td class="nameDescription">
|
|
<div class="fixedFont">
|
|
<b><a href="../symbols/_global_.html#globalAuthors">globalAuthors</a></b>
|
|
</div>
|
|
<div class="description">Saves all Authors as a assoative Array.</div>
|
|
</td>
|
|
</tr>
|
|
|
|
<tr>
|
|
<td class="attributes"> </td>
|
|
<td class="nameDescription">
|
|
<div class="fixedFont">
|
|
<b><a href="../symbols/_global_.html#globalPads">globalPads</a></b>
|
|
</div>
|
|
<div class="description">A Array with all known Pads</div>
|
|
</td>
|
|
</tr>
|
|
|
|
<tr>
|
|
<td class="attributes"> </td>
|
|
<td class="nameDescription">
|
|
<div class="fixedFont">
|
|
<b><a href="../symbols/_global_.html#http">http</a></b>
|
|
</div>
|
|
<div class="description">2011 Peter 'Pita' Martischka
|
|
|
|
Licensed under the Apache License, Version 2.0 (the "License");
|
|
you may not use this file except in compliance with the License.</div>
|
|
</td>
|
|
</tr>
|
|
|
|
<tr>
|
|
<td class="attributes"> </td>
|
|
<td class="nameDescription">
|
|
<div class="fixedFont">
|
|
<b><a href="../symbols/_global_.html#pad2sessions">pad2sessions</a></b>
|
|
</div>
|
|
<div class="description">A associative array that saves which sessions belong to a pad</div>
|
|
</td>
|
|
</tr>
|
|
|
|
<tr>
|
|
<td class="attributes"> </td>
|
|
<td class="nameDescription">
|
|
<div class="fixedFont">
|
|
<b><a href="../symbols/_global_.html#padManager">padManager</a></b>
|
|
</div>
|
|
<div class="description">Copyright 2009 Google Inc.</div>
|
|
</td>
|
|
</tr>
|
|
|
|
<tr>
|
|
<td class="attributes"> </td>
|
|
<td class="nameDescription">
|
|
<div class="fixedFont">
|
|
<b><a href="../symbols/_global_.html#session2pad">session2pad</a></b>
|
|
</div>
|
|
<div class="description">A associative array that translates a session to a pad</div>
|
|
</td>
|
|
</tr>
|
|
|
|
<tr>
|
|
<td class="attributes"> </td>
|
|
<td class="nameDescription">
|
|
<div class="fixedFont">
|
|
<b><a href="../symbols/_global_.html#sessioninfos">sessioninfos</a></b>
|
|
</div>
|
|
<div class="description">A associative array that saves some general informations about a session
|
|
key = sessionId
|
|
values = author, rev
|
|
rev = That last revision that was send to this client
|
|
author = the author name of this session</div>
|
|
</td>
|
|
</tr>
|
|
|
|
<tr>
|
|
<td class="attributes"> </td>
|
|
<td class="nameDescription">
|
|
<div class="fixedFont">
|
|
<b><a href="../symbols/_global_.html#socketio">socketio</a></b>
|
|
</div>
|
|
<div class="description">Saves the Socket class we need to send and recieve data from the client</div>
|
|
</td>
|
|
</tr>
|
|
|
|
<tr>
|
|
<td class="attributes"> </td>
|
|
<td class="nameDescription">
|
|
<div class="fixedFont">
|
|
<b><a href="../symbols/_global_.html#token2author">token2author</a></b>
|
|
</div>
|
|
<div class="description">A easy key value pair.</div>
|
|
</td>
|
|
</tr>
|
|
|
|
</tbody>
|
|
</table>
|
|
|
|
|
|
|
|
|
|
|
|
<!-- ============================== methods summary ======================== -->
|
|
|
|
|
|
|
|
<table class="summaryTable" cellspacing="0" summary="A summary of the methods documented in the class _global_.">
|
|
<caption>Method Summary</caption>
|
|
<thead>
|
|
<tr>
|
|
<th scope="col">Method Attributes</th>
|
|
<th scope="col">Method Name and Description</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody>
|
|
|
|
<tr>
|
|
<td class="attributes"> </td>
|
|
<td class="nameDescription">
|
|
<div class="fixedFont"><b><a href="../symbols/_global_.html#_correctMarkersInPad">_correctMarkersInPad</a></b>(atext, apool)
|
|
</div>
|
|
<div class="description">Copied from the Etherpad Source Code.</div>
|
|
</td>
|
|
</tr>
|
|
|
|
<tr>
|
|
<td class="attributes"> </td>
|
|
<td class="nameDescription">
|
|
<div class="fixedFont"><b><a href="../symbols/_global_.html#_randomString">_randomString</a></b>(len)
|
|
</div>
|
|
<div class="description">Generates a random String with the given length.</div>
|
|
</td>
|
|
</tr>
|
|
|
|
<tr>
|
|
<td class="attributes"> </td>
|
|
<td class="nameDescription">
|
|
<div class="fixedFont"><b><a href="../symbols/_global_.html#appendRevision">appendRevision</a></b>(id, theChangeset, The)
|
|
</div>
|
|
<div class="description">Append a changeset to a pad</div>
|
|
</td>
|
|
</tr>
|
|
|
|
<tr>
|
|
<td class="attributes"> </td>
|
|
<td class="nameDescription">
|
|
<div class="fixedFont"><b><a href="../symbols/_global_.html#atext">atext</a></b>(id)
|
|
</div>
|
|
<div class="description">Returns the Attributed Text of a pad</div>
|
|
</td>
|
|
</tr>
|
|
|
|
<tr>
|
|
<td class="attributes"> </td>
|
|
<td class="nameDescription">
|
|
<div class="fixedFont"><b><a href="../symbols/_global_.html#createPad">createPad</a></b>(id)
|
|
</div>
|
|
<div class="description">Creates an empty pad</div>
|
|
</td>
|
|
</tr>
|
|
|
|
<tr>
|
|
<td class="attributes"> </td>
|
|
<td class="nameDescription">
|
|
<div class="fixedFont"><b><a href="../symbols/_global_.html#getAllAuthors">getAllAuthors</a></b>(id)
|
|
</div>
|
|
<div class="description">Returns all Authors of a Pad</div>
|
|
</td>
|
|
</tr>
|
|
|
|
<tr>
|
|
<td class="attributes"> </td>
|
|
<td class="nameDescription">
|
|
<div class="fixedFont"><b><a href="../symbols/_global_.html#getHeadRevisionNumber">getHeadRevisionNumber</a></b>(id)
|
|
</div>
|
|
<div class="description">Returns the latest Revision Number of the Pad</div>
|
|
</td>
|
|
</tr>
|
|
|
|
<tr>
|
|
<td class="attributes"> </td>
|
|
<td class="nameDescription">
|
|
<div class="fixedFont"><b><a href="../symbols/_global_.html#getRevisionAuthor">getRevisionAuthor</a></b>(id, revNum)
|
|
</div>
|
|
<div class="description">Returns the author of a specific revision</div>
|
|
</td>
|
|
</tr>
|
|
|
|
<tr>
|
|
<td class="attributes"> </td>
|
|
<td class="nameDescription">
|
|
<div class="fixedFont"><b><a href="../symbols/_global_.html#getRevisionChangeset">getRevisionChangeset</a></b>(id, revNum)
|
|
</div>
|
|
<div class="description">Returns the changeset of a specific revision</div>
|
|
</td>
|
|
</tr>
|
|
|
|
<tr>
|
|
<td class="attributes"> </td>
|
|
<td class="nameDescription">
|
|
<div class="fixedFont"><b><a href="../symbols/_global_.html#handleClientReady">handleClientReady</a></b>(client, message)
|
|
</div>
|
|
<div class="description">Handles a CLIENT_READY.</div>
|
|
</td>
|
|
</tr>
|
|
|
|
<tr>
|
|
<td class="attributes"> </td>
|
|
<td class="nameDescription">
|
|
<div class="fixedFont"><b><a href="../symbols/_global_.html#handleUserChanges">handleUserChanges</a></b>(client, message)
|
|
</div>
|
|
<div class="description">Handles a USERINFO_UPDATE, that means that a user have changed his color or name.</div>
|
|
</td>
|
|
</tr>
|
|
|
|
<tr>
|
|
<td class="attributes"> </td>
|
|
<td class="nameDescription">
|
|
<div class="fixedFont"><b><a href="../symbols/_global_.html#handleUserInfoUpdate">handleUserInfoUpdate</a></b>(client, message)
|
|
</div>
|
|
<div class="description">Handles a USERINFO_UPDATE, that means that a user have changed his color or name.</div>
|
|
</td>
|
|
</tr>
|
|
|
|
<tr>
|
|
<td class="attributes"> </td>
|
|
<td class="nameDescription">
|
|
<div class="fixedFont"><b><a href="../symbols/_global_.html#pool">pool</a></b>(id)
|
|
</div>
|
|
<div class="description">Returns the Attribute Pool whichs the Pad is using</div>
|
|
</td>
|
|
</tr>
|
|
|
|
<tr>
|
|
<td class="attributes"> </td>
|
|
<td class="nameDescription">
|
|
<div class="fixedFont"><b><a href="../symbols/_global_.html#text">text</a></b>(id)
|
|
</div>
|
|
<div class="description">Returns the plain text of a pad</div>
|
|
</td>
|
|
</tr>
|
|
|
|
<tr>
|
|
<td class="attributes"> </td>
|
|
<td class="nameDescription">
|
|
<div class="fixedFont"><b><a href="../symbols/_global_.html#throwExceptionIfAuthorNotExist">throwExceptionIfAuthorNotExist</a></b>(author)
|
|
</div>
|
|
<div class="description">A internal function that checks if the Author exist and throws a exception if not</div>
|
|
</td>
|
|
</tr>
|
|
|
|
<tr>
|
|
<td class="attributes"> </td>
|
|
<td class="nameDescription">
|
|
<div class="fixedFont"><b><a href="../symbols/_global_.html#throwExceptionIfClientOrIOisInvalid">throwExceptionIfClientOrIOisInvalid</a></b>(client)
|
|
</div>
|
|
<div class="description">A internal function that simply checks if client or socketio is null and throws a exception if yes</div>
|
|
</td>
|
|
</tr>
|
|
|
|
<tr>
|
|
<td class="attributes"> </td>
|
|
<td class="nameDescription">
|
|
<div class="fixedFont"><b><a href="../symbols/_global_.html#throwExceptionIfPadDontExist">throwExceptionIfPadDontExist</a></b>(id)
|
|
</div>
|
|
<div class="description">Check if the ID is a valid Pad ID and trows an Exeption if not</div>
|
|
</td>
|
|
</tr>
|
|
|
|
<tr>
|
|
<td class="attributes"> </td>
|
|
<td class="nameDescription">
|
|
<div class="fixedFont"><b><a href="../symbols/_global_.html#throwExceptionIfRevDontExist">throwExceptionIfRevDontExist</a></b>(id, revNum)
|
|
</div>
|
|
<div class="description">Check if the Revision of a Pad is valid and throws an Exeption if not</div>
|
|
</td>
|
|
</tr>
|
|
|
|
</tbody>
|
|
</table>
|
|
|
|
|
|
|
|
|
|
<!-- ============================== events summary ======================== -->
|
|
|
|
|
|
<!-- ============================== constructor details ==================== -->
|
|
|
|
|
|
<!-- ============================== field details ========================== -->
|
|
|
|
<div class="sectionTitle">
|
|
Field Detail
|
|
</div>
|
|
|
|
<a name="AttributePoolFactory"> </a>
|
|
<div class="fixedFont">
|
|
|
|
|
|
<b>AttributePoolFactory</b>
|
|
|
|
</div>
|
|
<div class="description">
|
|
Copyright 2009 Google Inc., 2011 Peter 'Pita' Martischka
|
|
|
|
Licensed under the Apache License, Version 2.0 (the "License");
|
|
you may not use this file except in compliance with the License.
|
|
You may obtain a copy of the License at
|
|
|
|
http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
Unless required by applicable law or agreed to in writing, software
|
|
distributed under the License is distributed on an "AS-IS" BASIS,
|
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
See the License for the specific language governing permissions and
|
|
limitations under the License.
|
|
|
|
<br />
|
|
<i>Defined in: </i> <a href="../symbols/src/node_Changeset.js.html">Changeset.js</a>.
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<hr />
|
|
|
|
<a name="Changeset"> </a>
|
|
<div class="fixedFont">
|
|
|
|
|
|
<b>Changeset</b>
|
|
|
|
</div>
|
|
<div class="description">
|
|
2011 Peter 'Pita' Martischka
|
|
|
|
Licensed under the Apache License, Version 2.0 (the "License");
|
|
you may not use this file except in compliance with the License.
|
|
You may obtain a copy of the License at
|
|
|
|
http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
Unless required by applicable law or agreed to in writing, software
|
|
distributed under the License is distributed on an "AS-IS" BASIS,
|
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
See the License for the specific language governing permissions and
|
|
limitations under the License.
|
|
|
|
<br />
|
|
<i>Defined in: </i> <a href="../symbols/src/node_PadManager.js.html">PadManager.js</a>.
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<hr />
|
|
|
|
<a name="globalAuthors"> </a>
|
|
<div class="fixedFont">
|
|
|
|
|
|
<b>globalAuthors</b>
|
|
|
|
</div>
|
|
<div class="description">
|
|
Saves all Authors as a assoative Array. The Key is the author id.
|
|
Authors can have the following attributes:
|
|
-name The Name of the Author as shown on the Pad
|
|
-colorId The Id of Usercolor. A number between 0 and 31
|
|
-timestamp The timestamp on which the user was last seen
|
|
|
|
<br />
|
|
<i>Defined in: </i> <a href="../symbols/src/node_AuthorManager.js.html">AuthorManager.js</a>.
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<hr />
|
|
|
|
<a name="globalPads"> </a>
|
|
<div class="fixedFont">
|
|
|
|
|
|
<b>globalPads</b>
|
|
|
|
</div>
|
|
<div class="description">
|
|
A Array with all known Pads
|
|
|
|
<br />
|
|
<i>Defined in: </i> <a href="../symbols/src/node_PadManager.js.html">PadManager.js</a>.
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<hr />
|
|
|
|
<a name="http"> </a>
|
|
<div class="fixedFont">
|
|
|
|
|
|
<b>http</b>
|
|
|
|
</div>
|
|
<div class="description">
|
|
2011 Peter 'Pita' Martischka
|
|
|
|
Licensed under the Apache License, Version 2.0 (the "License");
|
|
you may not use this file except in compliance with the License.
|
|
You may obtain a copy of the License at
|
|
|
|
http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
Unless required by applicable law or agreed to in writing, software
|
|
distributed under the License is distributed on an "AS-IS" BASIS,
|
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
See the License for the specific language governing permissions and
|
|
limitations under the License.
|
|
|
|
<br />
|
|
<i>Defined in: </i> <a href="../symbols/src/node_server.js.html">server.js</a>.
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<hr />
|
|
|
|
<a name="pad2sessions"> </a>
|
|
<div class="fixedFont">
|
|
|
|
|
|
<b>pad2sessions</b>
|
|
|
|
</div>
|
|
<div class="description">
|
|
A associative array that saves which sessions belong to a pad
|
|
|
|
<br />
|
|
<i>Defined in: </i> <a href="../symbols/src/node_MessageHandler.js.html">MessageHandler.js</a>.
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<hr />
|
|
|
|
<a name="padManager"> </a>
|
|
<div class="fixedFont">
|
|
|
|
|
|
<b>padManager</b>
|
|
|
|
</div>
|
|
<div class="description">
|
|
Copyright 2009 Google Inc., 2011 Peter 'Pita' Martischka
|
|
|
|
Licensed under the Apache License, Version 2.0 (the "License");
|
|
you may not use this file except in compliance with the License.
|
|
You may obtain a copy of the License at
|
|
|
|
http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
Unless required by applicable law or agreed to in writing, software
|
|
distributed under the License is distributed on an "AS-IS" BASIS,
|
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
See the License for the specific language governing permissions and
|
|
limitations under the License.
|
|
|
|
<br />
|
|
<i>Defined in: </i> <a href="../symbols/src/node_MessageHandler.js.html">MessageHandler.js</a>.
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<hr />
|
|
|
|
<a name="session2pad"> </a>
|
|
<div class="fixedFont">
|
|
|
|
|
|
<b>session2pad</b>
|
|
|
|
</div>
|
|
<div class="description">
|
|
A associative array that translates a session to a pad
|
|
|
|
<br />
|
|
<i>Defined in: </i> <a href="../symbols/src/node_MessageHandler.js.html">MessageHandler.js</a>.
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<hr />
|
|
|
|
<a name="sessioninfos"> </a>
|
|
<div class="fixedFont">
|
|
|
|
|
|
<b>sessioninfos</b>
|
|
|
|
</div>
|
|
<div class="description">
|
|
A associative array that saves some general informations about a session
|
|
key = sessionId
|
|
values = author, rev
|
|
rev = That last revision that was send to this client
|
|
author = the author name of this session
|
|
|
|
<br />
|
|
<i>Defined in: </i> <a href="../symbols/src/node_MessageHandler.js.html">MessageHandler.js</a>.
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<hr />
|
|
|
|
<a name="socketio"> </a>
|
|
<div class="fixedFont">
|
|
|
|
|
|
<b>socketio</b>
|
|
|
|
</div>
|
|
<div class="description">
|
|
Saves the Socket class we need to send and recieve data from the client
|
|
|
|
<br />
|
|
<i>Defined in: </i> <a href="../symbols/src/node_MessageHandler.js.html">MessageHandler.js</a>.
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<hr />
|
|
|
|
<a name="token2author"> </a>
|
|
<div class="fixedFont">
|
|
|
|
|
|
<b>token2author</b>
|
|
|
|
</div>
|
|
<div class="description">
|
|
A easy key value pair. The Key is the token, the value is the authorid
|
|
|
|
<br />
|
|
<i>Defined in: </i> <a href="../symbols/src/node_AuthorManager.js.html">AuthorManager.js</a>.
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<!-- ============================== method details ========================= -->
|
|
|
|
<div class="sectionTitle">
|
|
Method Detail
|
|
</div>
|
|
|
|
<a name="_correctMarkersInPad"> </a>
|
|
<div class="fixedFont">
|
|
|
|
|
|
<b>_correctMarkersInPad</b>(atext, apool)
|
|
|
|
</div>
|
|
<div class="description">
|
|
Copied from the Etherpad Source Code. Don't know what this methode does excatly...
|
|
|
|
<br />
|
|
<i>Defined in: </i> <a href="../symbols/src/node_MessageHandler.js.html">MessageHandler.js</a>.
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
<dl class="detailList">
|
|
<dt class="heading">Parameters:</dt>
|
|
|
|
<dt>
|
|
<b>atext</b>
|
|
|
|
</dt>
|
|
<dd></dd>
|
|
|
|
<dt>
|
|
<b>apool</b>
|
|
|
|
</dt>
|
|
<dd></dd>
|
|
|
|
</dl>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<hr />
|
|
|
|
<a name="_randomString"> </a>
|
|
<div class="fixedFont">
|
|
|
|
|
|
<b>_randomString</b>(len)
|
|
|
|
</div>
|
|
<div class="description">
|
|
Generates a random String with the given length. Is needed to generate the Author Ids
|
|
|
|
<br />
|
|
<i>Defined in: </i> <a href="../symbols/src/node_AuthorManager.js.html">AuthorManager.js</a>.
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
<dl class="detailList">
|
|
<dt class="heading">Parameters:</dt>
|
|
|
|
<dt>
|
|
<b>len</b>
|
|
|
|
</dt>
|
|
<dd></dd>
|
|
|
|
</dl>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<hr />
|
|
|
|
<a name="appendRevision"> </a>
|
|
<div class="fixedFont">
|
|
|
|
|
|
<b>appendRevision</b>(id, theChangeset, The)
|
|
|
|
</div>
|
|
<div class="description">
|
|
Append a changeset to a pad
|
|
|
|
<br />
|
|
<i>Defined in: </i> <a href="../symbols/src/node_PadManager.js.html">PadManager.js</a>.
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
<dl class="detailList">
|
|
<dt class="heading">Parameters:</dt>
|
|
|
|
<dt>
|
|
<b>id</b>
|
|
|
|
</dt>
|
|
<dd>The Pad id</dd>
|
|
|
|
<dt>
|
|
<b>theChangeset</b>
|
|
|
|
</dt>
|
|
<dd>the changeset which should apply to the text</dd>
|
|
|
|
<dt>
|
|
<b>The</b>
|
|
|
|
</dt>
|
|
<dd>author of the revision, can be null</dd>
|
|
|
|
</dl>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<hr />
|
|
|
|
<a name="atext"> </a>
|
|
<div class="fixedFont">
|
|
|
|
|
|
<b>atext</b>(id)
|
|
|
|
</div>
|
|
<div class="description">
|
|
Returns the Attributed Text of a pad
|
|
|
|
<br />
|
|
<i>Defined in: </i> <a href="../symbols/src/node_PadManager.js.html">PadManager.js</a>.
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
<dl class="detailList">
|
|
<dt class="heading">Parameters:</dt>
|
|
|
|
<dt>
|
|
<b>id</b>
|
|
|
|
</dt>
|
|
<dd>The Pad id</dd>
|
|
|
|
</dl>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<hr />
|
|
|
|
<a name="createPad"> </a>
|
|
<div class="fixedFont">
|
|
|
|
|
|
<b>createPad</b>(id)
|
|
|
|
</div>
|
|
<div class="description">
|
|
Creates an empty pad
|
|
|
|
<br />
|
|
<i>Defined in: </i> <a href="../symbols/src/node_PadManager.js.html">PadManager.js</a>.
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
<dl class="detailList">
|
|
<dt class="heading">Parameters:</dt>
|
|
|
|
<dt>
|
|
<b>id</b>
|
|
|
|
</dt>
|
|
<dd>The Pad id</dd>
|
|
|
|
</dl>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<hr />
|
|
|
|
<a name="getAllAuthors"> </a>
|
|
<div class="fixedFont">
|
|
|
|
|
|
<b>getAllAuthors</b>(id)
|
|
|
|
</div>
|
|
<div class="description">
|
|
Returns all Authors of a Pad
|
|
|
|
<br />
|
|
<i>Defined in: </i> <a href="../symbols/src/node_PadManager.js.html">PadManager.js</a>.
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
<dl class="detailList">
|
|
<dt class="heading">Parameters:</dt>
|
|
|
|
<dt>
|
|
<b>id</b>
|
|
|
|
</dt>
|
|
<dd>The Pad id</dd>
|
|
|
|
</dl>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<hr />
|
|
|
|
<a name="getHeadRevisionNumber"> </a>
|
|
<div class="fixedFont">
|
|
|
|
|
|
<b>getHeadRevisionNumber</b>(id)
|
|
|
|
</div>
|
|
<div class="description">
|
|
Returns the latest Revision Number of the Pad
|
|
|
|
<br />
|
|
<i>Defined in: </i> <a href="../symbols/src/node_PadManager.js.html">PadManager.js</a>.
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
<dl class="detailList">
|
|
<dt class="heading">Parameters:</dt>
|
|
|
|
<dt>
|
|
<b>id</b>
|
|
|
|
</dt>
|
|
<dd>The Pad id</dd>
|
|
|
|
</dl>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<hr />
|
|
|
|
<a name="getRevisionAuthor"> </a>
|
|
<div class="fixedFont">
|
|
|
|
|
|
<b>getRevisionAuthor</b>(id, revNum)
|
|
|
|
</div>
|
|
<div class="description">
|
|
Returns the author of a specific revision
|
|
|
|
<br />
|
|
<i>Defined in: </i> <a href="../symbols/src/node_PadManager.js.html">PadManager.js</a>.
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
<dl class="detailList">
|
|
<dt class="heading">Parameters:</dt>
|
|
|
|
<dt>
|
|
<b>id</b>
|
|
|
|
</dt>
|
|
<dd>The Pad id</dd>
|
|
|
|
<dt>
|
|
<b>revNum</b>
|
|
|
|
</dt>
|
|
<dd>The Revision Number</dd>
|
|
|
|
</dl>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<hr />
|
|
|
|
<a name="getRevisionChangeset"> </a>
|
|
<div class="fixedFont">
|
|
|
|
|
|
<b>getRevisionChangeset</b>(id, revNum)
|
|
|
|
</div>
|
|
<div class="description">
|
|
Returns the changeset of a specific revision
|
|
|
|
<br />
|
|
<i>Defined in: </i> <a href="../symbols/src/node_PadManager.js.html">PadManager.js</a>.
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
<dl class="detailList">
|
|
<dt class="heading">Parameters:</dt>
|
|
|
|
<dt>
|
|
<b>id</b>
|
|
|
|
</dt>
|
|
<dd>The Pad id</dd>
|
|
|
|
<dt>
|
|
<b>revNum</b>
|
|
|
|
</dt>
|
|
<dd>The Revision Number</dd>
|
|
|
|
</dl>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<hr />
|
|
|
|
<a name="handleClientReady"> </a>
|
|
<div class="fixedFont">
|
|
|
|
|
|
<b>handleClientReady</b>(client, message)
|
|
|
|
</div>
|
|
<div class="description">
|
|
Handles a CLIENT_READY. A CLIENT_READY is the first message from the client to the server. The Client sends his token
|
|
and the pad it wants to enter. The Server answers with the inital values (clientVars) of the pad
|
|
|
|
<br />
|
|
<i>Defined in: </i> <a href="../symbols/src/node_MessageHandler.js.html">MessageHandler.js</a>.
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
<dl class="detailList">
|
|
<dt class="heading">Parameters:</dt>
|
|
|
|
<dt>
|
|
<b>client</b>
|
|
|
|
</dt>
|
|
<dd>the client that send this message</dd>
|
|
|
|
<dt>
|
|
<b>message</b>
|
|
|
|
</dt>
|
|
<dd>the message from the client</dd>
|
|
|
|
</dl>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<hr />
|
|
|
|
<a name="handleUserChanges"> </a>
|
|
<div class="fixedFont">
|
|
|
|
|
|
<b>handleUserChanges</b>(client, message)
|
|
|
|
</div>
|
|
<div class="description">
|
|
Handles a USERINFO_UPDATE, that means that a user have changed his color or name. Anyway, we get both informations
|
|
This Method is nearly 90% copied out of the Etherpad Source Code. So I can't tell you what happens here exactly
|
|
Look at https://github.com/ether/pad/blob/master/etherpad/src/etherpad/collab/collab_server.js in the function applyUserChanges()
|
|
|
|
<br />
|
|
<i>Defined in: </i> <a href="../symbols/src/node_MessageHandler.js.html">MessageHandler.js</a>.
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
<dl class="detailList">
|
|
<dt class="heading">Parameters:</dt>
|
|
|
|
<dt>
|
|
<b>client</b>
|
|
|
|
</dt>
|
|
<dd>the client that send this message</dd>
|
|
|
|
<dt>
|
|
<b>message</b>
|
|
|
|
</dt>
|
|
<dd>the message from the client</dd>
|
|
|
|
</dl>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<hr />
|
|
|
|
<a name="handleUserInfoUpdate"> </a>
|
|
<div class="fixedFont">
|
|
|
|
|
|
<b>handleUserInfoUpdate</b>(client, message)
|
|
|
|
</div>
|
|
<div class="description">
|
|
Handles a USERINFO_UPDATE, that means that a user have changed his color or name. Anyway, we get both informations
|
|
|
|
<br />
|
|
<i>Defined in: </i> <a href="../symbols/src/node_MessageHandler.js.html">MessageHandler.js</a>.
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
<dl class="detailList">
|
|
<dt class="heading">Parameters:</dt>
|
|
|
|
<dt>
|
|
<b>client</b>
|
|
|
|
</dt>
|
|
<dd>the client that send this message</dd>
|
|
|
|
<dt>
|
|
<b>message</b>
|
|
|
|
</dt>
|
|
<dd>the message from the client</dd>
|
|
|
|
</dl>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<hr />
|
|
|
|
<a name="pool"> </a>
|
|
<div class="fixedFont">
|
|
|
|
|
|
<b>pool</b>(id)
|
|
|
|
</div>
|
|
<div class="description">
|
|
Returns the Attribute Pool whichs the Pad is using
|
|
|
|
<br />
|
|
<i>Defined in: </i> <a href="../symbols/src/node_PadManager.js.html">PadManager.js</a>.
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
<dl class="detailList">
|
|
<dt class="heading">Parameters:</dt>
|
|
|
|
<dt>
|
|
<b>id</b>
|
|
|
|
</dt>
|
|
<dd>The Pad id</dd>
|
|
|
|
</dl>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<hr />
|
|
|
|
<a name="text"> </a>
|
|
<div class="fixedFont">
|
|
|
|
|
|
<b>text</b>(id)
|
|
|
|
</div>
|
|
<div class="description">
|
|
Returns the plain text of a pad
|
|
|
|
<br />
|
|
<i>Defined in: </i> <a href="../symbols/src/node_PadManager.js.html">PadManager.js</a>.
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
<dl class="detailList">
|
|
<dt class="heading">Parameters:</dt>
|
|
|
|
<dt>
|
|
<b>id</b>
|
|
|
|
</dt>
|
|
<dd>The Pad id</dd>
|
|
|
|
</dl>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<hr />
|
|
|
|
<a name="throwExceptionIfAuthorNotExist"> </a>
|
|
<div class="fixedFont">
|
|
|
|
|
|
<b>throwExceptionIfAuthorNotExist</b>(author)
|
|
|
|
</div>
|
|
<div class="description">
|
|
A internal function that checks if the Author exist and throws a exception if not
|
|
|
|
<br />
|
|
<i>Defined in: </i> <a href="../symbols/src/node_AuthorManager.js.html">AuthorManager.js</a>.
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
<dl class="detailList">
|
|
<dt class="heading">Parameters:</dt>
|
|
|
|
<dt>
|
|
<b>author</b>
|
|
|
|
</dt>
|
|
<dd></dd>
|
|
|
|
</dl>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<hr />
|
|
|
|
<a name="throwExceptionIfClientOrIOisInvalid"> </a>
|
|
<div class="fixedFont">
|
|
|
|
|
|
<b>throwExceptionIfClientOrIOisInvalid</b>(client)
|
|
|
|
</div>
|
|
<div class="description">
|
|
A internal function that simply checks if client or socketio is null and throws a exception if yes
|
|
|
|
<br />
|
|
<i>Defined in: </i> <a href="../symbols/src/node_MessageHandler.js.html">MessageHandler.js</a>.
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
<dl class="detailList">
|
|
<dt class="heading">Parameters:</dt>
|
|
|
|
<dt>
|
|
<b>client</b>
|
|
|
|
</dt>
|
|
<dd></dd>
|
|
|
|
</dl>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<hr />
|
|
|
|
<a name="throwExceptionIfPadDontExist"> </a>
|
|
<div class="fixedFont">
|
|
|
|
|
|
<b>throwExceptionIfPadDontExist</b>(id)
|
|
|
|
</div>
|
|
<div class="description">
|
|
Check if the ID is a valid Pad ID and trows an Exeption if not
|
|
|
|
<br />
|
|
<i>Defined in: </i> <a href="../symbols/src/node_PadManager.js.html">PadManager.js</a>.
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
<dl class="detailList">
|
|
<dt class="heading">Parameters:</dt>
|
|
|
|
<dt>
|
|
<b>id</b>
|
|
|
|
</dt>
|
|
<dd>The Pad id</dd>
|
|
|
|
</dl>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<hr />
|
|
|
|
<a name="throwExceptionIfRevDontExist"> </a>
|
|
<div class="fixedFont">
|
|
|
|
|
|
<b>throwExceptionIfRevDontExist</b>(id, revNum)
|
|
|
|
</div>
|
|
<div class="description">
|
|
Check if the Revision of a Pad is valid and throws an Exeption if not
|
|
|
|
<br />
|
|
<i>Defined in: </i> <a href="../symbols/src/node_PadManager.js.html">PadManager.js</a>.
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
<dl class="detailList">
|
|
<dt class="heading">Parameters:</dt>
|
|
|
|
<dt>
|
|
<b>id</b>
|
|
|
|
</dt>
|
|
<dd>The Pad id</dd>
|
|
|
|
<dt>
|
|
<b>revNum</b>
|
|
|
|
</dt>
|
|
<dd></dd>
|
|
|
|
</dl>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<!-- ============================== event details ========================= -->
|
|
|
|
|
|
<hr />
|
|
</div>
|
|
|
|
|
|
<!-- ============================== footer ================================= -->
|
|
<div class="fineprint" style="clear:both">
|
|
|
|
Documentation generated by <a href="http://code.google.com/p/jsdoc-toolkit/" target="_blank">JsDoc Toolkit</a> 2.3.2 on Sat Mar 26 2011 18:26:06 GMT-0000 (GMT)
|
|
</div>
|
|
</body>
|
|
</html>
|