blob: 96975206060009d0fbd44817187c0965990e8ef3 [file] [log] [blame]
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>JSDoc: Class: EnumItem</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">Class: EnumItem</h1>
<section>
<header>
<h2><span class="attribs"><span class="type-signature"></span></span>EnumItem<span class="signature">(typeId)</span><span class="type-signature"></span></h2>
<div class="class-description"><p>Class representing an item of Ignite enum type.</p>
<p>The item is defined by:</p>
<ul>
<li>type Id (mandatory) - Id of the Ignite enum type.</li>
<li>ordinal (optional) - ordinal of the item in the Ignite enum type.</li>
<li>name (optional) - name of the item (field name in the Ignite enum type).</li>
<li>value (optional) - value of the item.
Usually, at least one from the optional ordinal, name or value must be specified
in order to use an instance of this class in Ignite operations.</li>
</ul>
<p>To distinguish one item from another, the Ignite client analyzes the optional fields in the following order:
ordinal, name, value.</p></div>
</header>
<article>
<div class="container-overview">
<h2>Constructor</h2>
<h4 class="name" id="EnumItem"><span class="type-signature"></span>new EnumItem<span class="signature">(typeId)</span><span class="type-signature"></span></h4>
<div class="description">
<p>Public constructor.</p>
</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>typeId</code></td>
<td class="type">
<span class="param-type">number</span>
</td>
<td class="description last"><p>Id of the Ignite enum type.</p></td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="EnumItem.js.html">EnumItem.js</a>, <a href="EnumItem.js.html#line37">line 37</a>
</li></ul></dd>
</dl>
</div>
<h3 class="subsection-title">Methods</h3>
<h4 class="name" id="getName"><span class="type-signature"></span>getName<span class="signature">()</span><span class="type-signature"> &rarr; {string}</span></h4>
<div class="description">
<p>Returns name of the item
or null if name is not set.</p>
</div>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="EnumItem.js.html">EnumItem.js</a>, <a href="EnumItem.js.html#line110">line 110</a>
</li></ul></dd>
</dl>
<h5>Returns:</h5>
<div class="param-desc">
<ul>
<li>name of the item.</li>
</ul>
</div>
<dl>
<dt>
Type
</dt>
<dd>
<span class="param-type">string</span>
</dd>
</dl>
<h4 class="name" id="getOrdinal"><span class="type-signature"></span>getOrdinal<span class="signature">()</span><span class="type-signature"> &rarr; {number}</span></h4>
<div class="description">
<p>Returns ordinal of the item in the Ignite enum type
or null if ordinal is not set.</p>
</div>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="EnumItem.js.html">EnumItem.js</a>, <a href="EnumItem.js.html#line85">line 85</a>
</li></ul></dd>
</dl>
<h5>Returns:</h5>
<div class="param-desc">
<ul>
<li>ordinal of the item in the Ignite enum type.</li>
</ul>
</div>
<dl>
<dt>
Type
</dt>
<dd>
<span class="param-type">number</span>
</dd>
</dl>
<h4 class="name" id="getTypeId"><span class="type-signature"></span>getTypeId<span class="signature">()</span><span class="type-signature"> &rarr; {number}</span></h4>
<div class="description">
<p>Returns Id of the Ignite enum type.</p>
</div>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="EnumItem.js.html">EnumItem.js</a>, <a href="EnumItem.js.html#line60">line 60</a>
</li></ul></dd>
</dl>
<h5>Returns:</h5>
<div class="param-desc">
<ul>
<li>Id of the enum type.</li>
</ul>
</div>
<dl>
<dt>
Type
</dt>
<dd>
<span class="param-type">number</span>
</dd>
</dl>
<h4 class="name" id="getValue"><span class="type-signature"></span>getValue<span class="signature">()</span><span class="type-signature"> &rarr; {number}</span></h4>
<div class="description">
<p>Returns value of the item
or null if value is not set.</p>
</div>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="EnumItem.js.html">EnumItem.js</a>, <a href="EnumItem.js.html#line135">line 135</a>
</li></ul></dd>
</dl>
<h5>Returns:</h5>
<div class="param-desc">
<ul>
<li>value of the item.</li>
</ul>
</div>
<dl>
<dt>
Type
</dt>
<dd>
<span class="param-type">number</span>
</dd>
</dl>
<h4 class="name" id="setName"><span class="type-signature"></span>setName<span class="signature">(name)</span><span class="type-signature"> &rarr; {<a href="EnumItem.html">EnumItem</a>}</span></h4>
<div class="description">
<p>Sets or updates name of the item.</p>
</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>name</code></td>
<td class="type">
<span class="param-type">string</span>
</td>
<td class="description last"><p>name of the item.</p></td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="EnumItem.js.html">EnumItem.js</a>, <a href="EnumItem.js.html#line123">line 123</a>
</li></ul></dd>
</dl>
<h5>Throws:</h5>
<dl>
<dt>
<div class="param-desc">
<p>if error.</p>
</div>
</dt>
<dd></dd>
<dt>
<dl>
<dt>
Type
</dt>
<dd>
<span class="param-type"><a href="IgniteClientError.html">IgniteClientError</a></span>
</dd>
</dl>
</dt>
<dd></dd>
</dl>
<h5>Returns:</h5>
<div class="param-desc">
<ul>
<li>the same instance of EnumItem</li>
</ul>
</div>
<dl>
<dt>
Type
</dt>
<dd>
<span class="param-type"><a href="EnumItem.html">EnumItem</a></span>
</dd>
</dl>
<h4 class="name" id="setOrdinal"><span class="type-signature"></span>setOrdinal<span class="signature">(ordinal)</span><span class="type-signature"> &rarr; {<a href="EnumItem.html">EnumItem</a>}</span></h4>
<div class="description">
<p>Sets or updates ordinal of the item in the Ignite enum type.</p>
</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>ordinal</code></td>
<td class="type">
<span class="param-type">number</span>
</td>
<td class="description last"><p>ordinal of the item in the Ignite enum type.</p></td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="EnumItem.js.html">EnumItem.js</a>, <a href="EnumItem.js.html#line98">line 98</a>
</li></ul></dd>
</dl>
<h5>Throws:</h5>
<dl>
<dt>
<div class="param-desc">
<p>if error.</p>
</div>
</dt>
<dd></dd>
<dt>
<dl>
<dt>
Type
</dt>
<dd>
<span class="param-type"><a href="IgniteClientError.html">IgniteClientError</a></span>
</dd>
</dl>
</dt>
<dd></dd>
</dl>
<h5>Returns:</h5>
<div class="param-desc">
<ul>
<li>the same instance of EnumItem</li>
</ul>
</div>
<dl>
<dt>
Type
</dt>
<dd>
<span class="param-type"><a href="EnumItem.html">EnumItem</a></span>
</dd>
</dl>
<h4 class="name" id="setTypeId"><span class="type-signature"></span>setTypeId<span class="signature">(typeId)</span><span class="type-signature"> &rarr; {<a href="EnumItem.html">EnumItem</a>}</span></h4>
<div class="description">
<p>Updates Id of the Ignite enum type.</p>
</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>typeId</code></td>
<td class="type">
<span class="param-type">number</span>
</td>
<td class="description last"><p>new Id of the Ignite enum type.</p></td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="EnumItem.js.html">EnumItem.js</a>, <a href="EnumItem.js.html#line73">line 73</a>
</li></ul></dd>
</dl>
<h5>Throws:</h5>
<dl>
<dt>
<div class="param-desc">
<p>if error.</p>
</div>
</dt>
<dd></dd>
<dt>
<dl>
<dt>
Type
</dt>
<dd>
<span class="param-type"><a href="IgniteClientError.html">IgniteClientError</a></span>
</dd>
</dl>
</dt>
<dd></dd>
</dl>
<h5>Returns:</h5>
<div class="param-desc">
<ul>
<li>the same instance of EnumItem</li>
</ul>
</div>
<dl>
<dt>
Type
</dt>
<dd>
<span class="param-type"><a href="EnumItem.html">EnumItem</a></span>
</dd>
</dl>
<h4 class="name" id="setValue"><span class="type-signature"></span>setValue<span class="signature">(value)</span><span class="type-signature"> &rarr; {<a href="EnumItem.html">EnumItem</a>}</span></h4>
<div class="description">
<p>Sets or updates value of the item.</p>
</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>value</code></td>
<td class="type">
<span class="param-type">number</span>
</td>
<td class="description last"><p>value of the item.</p></td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="EnumItem.js.html">EnumItem.js</a>, <a href="EnumItem.js.html#line148">line 148</a>
</li></ul></dd>
</dl>
<h5>Throws:</h5>
<dl>
<dt>
<div class="param-desc">
<p>if error.</p>
</div>
</dt>
<dd></dd>
<dt>
<dl>
<dt>
Type
</dt>
<dd>
<span class="param-type"><a href="IgniteClientError.html">IgniteClientError</a></span>
</dd>
</dl>
</dt>
<dd></dd>
</dl>
<h5>Returns:</h5>
<div class="param-desc">
<ul>
<li>the same instance of EnumItem</li>
</ul>
</div>
<dl>
<dt>
Type
</dt>
<dd>
<span class="param-type"><a href="EnumItem.html">EnumItem</a></span>
</dd>
</dl>
</article>
</section>
</div>
<nav>
<h2><a href="index.html">Home</a></h2><h3>Classes</h3><ul><li><a href="BinaryObject.html">BinaryObject</a></li><li><a href="CacheClient.html">CacheClient</a></li><li><a href="CacheConfiguration.html">CacheConfiguration</a></li><li><a href="CacheEntry.html">CacheEntry</a></li><li><a href="CacheKeyConfiguration.html">CacheKeyConfiguration</a></li><li><a href="CollectionObjectType.html">CollectionObjectType</a></li><li><a href="ComplexObjectType.html">ComplexObjectType</a></li><li><a href="CompositeType.html">CompositeType</a></li><li><a href="Cursor.html">Cursor</a></li><li><a href="EnumItem.html">EnumItem</a></li><li><a href="IgniteClient.html">IgniteClient</a></li><li><a href="IgniteClientConfiguration.html">IgniteClientConfiguration</a></li><li><a href="IgniteClientError.html">IgniteClientError</a></li><li><a href="IllegalStateError.html">IllegalStateError</a></li><li><a href="LostConnectionError.html">LostConnectionError</a></li><li><a href="MapObjectType.html">MapObjectType</a></li><li><a href="ObjectArrayType.html">ObjectArrayType</a></li><li><a href="ObjectType.html">ObjectType</a></li><li><a href="OperationError.html">OperationError</a></li><li><a href="Query.html">Query</a></li><li><a href="QueryEntity.html">QueryEntity</a></li><li><a href="QueryField.html">QueryField</a></li><li><a href="QueryIndex.html">QueryIndex</a></li><li><a href="ScanQuery.html">ScanQuery</a></li><li><a href="SqlFieldsCursor.html">SqlFieldsCursor</a></li><li><a href="SqlFieldsQuery.html">SqlFieldsQuery</a></li><li><a href="SqlQuery.html">SqlQuery</a></li><li><a href="Timestamp.html">Timestamp</a></li></ul>
</nav>
<br class="clear">
<footer>
Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 3.5.5</a> on Tue May 22 2018 12:08:49 GMT+0300 (Russia TZ 2 Standard Time)
</footer>
<script> prettyPrint(); </script>
<script src="scripts/linenumber.js"> </script>
</body>
</html>