5 <title>JSDoc: Class: Namespace</title>
7 <script src="scripts/prettify/prettify.js"> </script>
8 <script src="scripts/prettify/lang-css.js"> </script>
10 <script src="//html5shiv.googlecode.com/svn/trunk/html5.js"></script>
12 <link type="text/css" rel="stylesheet" href="styles/prettify-tomorrow.css">
13 <link type="text/css" rel="stylesheet" href="styles/jsdoc-default.css">
20 <h1 class="page-title">Class: Namespace</h1>
32 <span class="ancestors"><a href="ProtoBuf.html">ProtoBuf</a><a href="ProtoBuf.Reflect.html">.Reflect</a>.</span>
41 <div class="container-overview">
47 <h4 class="name" id="Namespace"><span class="type-signature"></span>new Namespace<span class="signature">(builder<span class="signature-attributes">non-null</span>, parent<span class="signature-attributes">nullable</span>, name, options<span class="signature-attributes">opt</span>, syntax<span class="signature-attributes">nullable</span>)</span><span class="type-signature"></span></h4>
53 <div class="description">
54 <p>Constructs a new Namespace.</p>
68 <table class="params">
83 <th class="last">Description</th>
92 <td class="name"><code>builder</code></td>
98 <span class="param-type"><a href="ProtoBuf.Builder.html">ProtoBuf.Builder</a></span>
105 <td class="attributes">
116 <td class="description last"><p>Builder reference</p></td>
123 <td class="name"><code>parent</code></td>
129 <span class="param-type"><a href="ProtoBuf.Reflect.Namespace.html">ProtoBuf.Reflect.Namespace</a></span>
136 <td class="attributes">
149 <td class="description last"><p>Namespace parent</p></td>
156 <td class="name"><code>name</code></td>
162 <span class="param-type">string</span>
169 <td class="attributes">
180 <td class="description last"><p>Namespace name</p></td>
187 <td class="name"><code>options</code></td>
193 <span class="param-type">Object.<string, *></span>
200 <td class="attributes">
213 <td class="description last"><p>Namespace options</p></td>
220 <td class="name"><code>syntax</code></td>
226 <span class="param-type">string</span>
233 <td class="attributes">
246 <td class="description last"><p>The syntax level of this definition (e.g., proto3)</p></td>
285 <dt class="tag-source">Source:</dt>
286 <dd class="tag-source"><ul class="dummy"><li>
287 <a href="protobuf.js.html">protobuf.js</a>, <a href="protobuf.js.html#line1500">line 1500</a>
317 <h3 class="subsection-title">Extends</h3>
323 <li><a href="ProtoBuf.Reflect.T.html">ProtoBuf.Reflect.T</a></li>
338 <h3 class="subsection-title">Members</h3>
342 <h4 class="name" id="builder"><span class="type-signature">(non-null) </span>builder<span class="type-signature"> :<a href="ProtoBuf.Builder.html">ProtoBuf.Builder</a></span></h4>
347 <div class="description">
348 <p>Builder reference.</p>
357 <span class="param-type"><a href="ProtoBuf.Builder.html">ProtoBuf.Builder</a></span>
374 <dt class="inherited-from">Inherited From:</dt>
375 <dd class="inherited-from"><ul class="dummy"><li>
376 <a href="ProtoBuf.Reflect.T.html#builder">ProtoBuf.Reflect.T#builder</a>
399 <dt class="tag-source">Source:</dt>
400 <dd class="tag-source"><ul class="dummy"><li>
401 <a href="protobuf.js.html">protobuf.js</a>, <a href="protobuf.js.html#line1417">line 1417</a>
419 <h4 class="name" id="children"><span class="type-signature">(non-null) </span>children<span class="type-signature"> :Array.<<a href="ProtoBuf.Reflect.T.html">ProtoBuf.Reflect.T</a>></span></h4>
424 <div class="description">
425 <p>Children inside the namespace.</p>
434 <span class="param-type">Array.<<a href="ProtoBuf.Reflect.T.html">ProtoBuf.Reflect.T</a>></span>
471 <dt class="tag-source">Source:</dt>
472 <dd class="tag-source"><ul class="dummy"><li>
473 <a href="protobuf.js.html">protobuf.js</a>, <a href="protobuf.js.html#line1512">line 1512</a>
491 <h4 class="name" id="className"><span class="type-signature"></span>className<span class="type-signature"> :string</span></h4>
496 <div class="description">
497 <p>Fully qualified class name</p>
506 <span class="param-type">string</span>
525 <dt class="tag-overrides">Overrides:</dt>
526 <dd class="tag-overrides"><ul class="dummy"><li>
527 <a href="ProtoBuf.Reflect.T.html#className">ProtoBuf.Reflect.T#className</a>
548 <dt class="tag-source">Source:</dt>
549 <dd class="tag-source"><ul class="dummy"><li>
550 <a href="protobuf.js.html">protobuf.js</a>, <a href="protobuf.js.html#line1438">line 1438</a>
568 <h4 class="name" id="name"><span class="type-signature"></span>name<span class="type-signature"> :string</span></h4>
573 <div class="description">
574 <p>Object name in namespace.</p>
583 <span class="param-type">string</span>
600 <dt class="inherited-from">Inherited From:</dt>
601 <dd class="inherited-from"><ul class="dummy"><li>
602 <a href="ProtoBuf.Reflect.T.html#name">ProtoBuf.Reflect.T#name</a>
625 <dt class="tag-source">Source:</dt>
626 <dd class="tag-source"><ul class="dummy"><li>
627 <a href="protobuf.js.html">protobuf.js</a>, <a href="protobuf.js.html#line1431">line 1431</a>
645 <h4 class="name" id="options"><span class="type-signature">(non-null) </span>options<span class="type-signature"> :Object.<string, *></span></h4>
650 <div class="description">
660 <span class="param-type">Object.<string, *></span>
697 <dt class="tag-source">Source:</dt>
698 <dd class="tag-source"><ul class="dummy"><li>
699 <a href="protobuf.js.html">protobuf.js</a>, <a href="protobuf.js.html#line1518">line 1518</a>
717 <h4 class="name" id="parent"><span class="type-signature">(nullable) </span>parent<span class="type-signature"> :<a href="ProtoBuf.Reflect.T.html">ProtoBuf.Reflect.T</a></span></h4>
722 <div class="description">
723 <p>Parent object.</p>
732 <span class="param-type"><a href="ProtoBuf.Reflect.T.html">ProtoBuf.Reflect.T</a></span>
749 <dt class="inherited-from">Inherited From:</dt>
750 <dd class="inherited-from"><ul class="dummy"><li>
751 <a href="ProtoBuf.Reflect.T.html#parent">ProtoBuf.Reflect.T#parent</a>
774 <dt class="tag-source">Source:</dt>
775 <dd class="tag-source"><ul class="dummy"><li>
776 <a href="protobuf.js.html">protobuf.js</a>, <a href="protobuf.js.html#line1424">line 1424</a>
794 <h4 class="name" id="syntax"><span class="type-signature">(non-null) </span>syntax<span class="type-signature"> :string</span></h4>
799 <div class="description">
800 <p>Syntax level (e.g., proto2 or proto3).</p>
809 <span class="param-type">string</span>
846 <dt class="tag-source">Source:</dt>
847 <dd class="tag-source"><ul class="dummy"><li>
848 <a href="protobuf.js.html">protobuf.js</a>, <a href="protobuf.js.html#line1524">line 1524</a>
868 <h3 class="subsection-title">Methods</h3>
875 <h4 class="name" id="addChild"><span class="type-signature"></span>addChild<span class="signature">(child)</span><span class="type-signature"></span></h4>
881 <div class="description">
882 <p>Adds a child to the namespace.</p>
896 <table class="params">
909 <th class="last">Description</th>
918 <td class="name"><code>child</code></td>
924 <span class="param-type"><a href="ProtoBuf.Reflect.T.html">ProtoBuf.Reflect.T</a></span>
934 <td class="description last"><p>Child</p></td>
973 <dt class="tag-source">Source:</dt>
974 <dd class="tag-source"><ul class="dummy"><li>
975 <a href="protobuf.js.html">protobuf.js</a>, <a href="protobuf.js.html#line1556">line 1556</a>
1002 <div class="param-desc">
1003 <p>If the child cannot be added (duplicate)</p>
1014 <span class="param-type">Error</span>
1035 <h4 class="name" id="build"><span class="type-signature"></span>build<span class="signature">()</span><span class="type-signature"> → {Object.<string, (function()|Object)>}</span></h4>
1041 <div class="description">
1042 <p>Builds the namespace and returns the runtime counterpart.</p>
1057 <dl class="details">
1066 <dt class="tag-overrides">Overrides:</dt>
1067 <dd class="tag-overrides"><ul class="dummy"><li>
1068 <a href="ProtoBuf.Reflect.T.html#build">ProtoBuf.Reflect.T#build</a>
1089 <dt class="tag-source">Source:</dt>
1090 <dd class="tag-source"><ul class="dummy"><li>
1091 <a href="protobuf.js.html">protobuf.js</a>, <a href="protobuf.js.html#line1648">line 1648</a>
1117 <div class="param-desc">
1118 <p>Runtime namespace</p>
1129 <span class="param-type">Object.<string, (function()|Object)></span>
1144 <h4 class="name" id="buildOpt"><span class="type-signature"></span>buildOpt<span class="signature">()</span><span class="type-signature"> → {Object.<string, *>}</span></h4>
1150 <div class="description">
1151 <p>Builds the namespace's '$options' property.</p>
1166 <dl class="details">
1193 <dt class="tag-source">Source:</dt>
1194 <dd class="tag-source"><ul class="dummy"><li>
1195 <a href="protobuf.js.html">protobuf.js</a>, <a href="protobuf.js.html#line1666">line 1666</a>
1229 <span class="param-type">Object.<string, *></span>
1244 <h4 class="name" id="fqn"><span class="type-signature"></span>fqn<span class="signature">()</span><span class="type-signature"> → {string}</span></h4>
1250 <div class="description">
1251 <p>Returns the fully qualified name of this object.</p>
1266 <dl class="details">
1273 <dt class="inherited-from">Inherited From:</dt>
1274 <dd class="inherited-from"><ul class="dummy"><li>
1275 <a href="ProtoBuf.Reflect.T.html#fqn">ProtoBuf.Reflect.T#fqn</a>
1298 <dt class="tag-source">Source:</dt>
1299 <dd class="tag-source"><ul class="dummy"><li>
1300 <a href="protobuf.js.html">protobuf.js</a>, <a href="protobuf.js.html#line1452">line 1452</a>
1326 <div class="param-desc">
1327 <p>Fully qualified name as of ".PATH.TO.THIS"</p>
1338 <span class="param-type">string</span>
1353 <h4 class="name" id="getChild"><span class="type-signature"></span>getChild<span class="signature">(nameOrId)</span><span class="type-signature"> → (nullable) {<a href="ProtoBuf.Reflect.T.html">ProtoBuf.Reflect.T</a>}</span></h4>
1359 <div class="description">
1360 <p>Gets a child by its name or id.</p>
1371 <h5>Parameters:</h5>
1374 <table class="params">
1387 <th class="last">Description</th>
1396 <td class="name"><code>nameOrId</code></td>
1402 <span class="param-type">string</span>
1405 <span class="param-type">number</span>
1415 <td class="description last"><p>Child name or id</p></td>
1427 <dl class="details">
1454 <dt class="tag-source">Source:</dt>
1455 <dd class="tag-source"><ul class="dummy"><li>
1456 <a href="protobuf.js.html">protobuf.js</a>, <a href="protobuf.js.html#line1576">line 1576</a>
1482 <div class="param-desc">
1483 <p>The child or null if not found</p>
1494 <span class="param-type"><a href="ProtoBuf.Reflect.T.html">ProtoBuf.Reflect.T</a></span>
1509 <h4 class="name" id="getChildren"><span class="type-signature"></span>getChildren<span class="signature">(type<span class="signature-attributes">opt</span>)</span><span class="type-signature"> → {Array.<<a href="ProtoBuf.Reflect.T.html">ProtoBuf.Reflect.T</a>>}</span></h4>
1515 <div class="description">
1516 <p>Returns an array of the namespace's children.</p>
1527 <h5>Parameters:</h5>
1530 <table class="params">
1545 <th class="last">Description</th>
1554 <td class="name"><code>type</code></td>
1560 <span class="param-type"><a href="ProtoBuf.Reflect.T.html">ProtoBuf.Reflect.T</a></span>
1567 <td class="attributes">
1580 <td class="description last"><p>Filter type (returns instances of this type only). Defaults to null (all children).</p></td>
1592 <dl class="details">
1619 <dt class="tag-source">Source:</dt>
1620 <dd class="tag-source"><ul class="dummy"><li>
1621 <a href="protobuf.js.html">protobuf.js</a>, <a href="protobuf.js.html#line1539">line 1539</a>
1655 <span class="param-type">Array.<<a href="ProtoBuf.Reflect.T.html">ProtoBuf.Reflect.T</a>></span>
1670 <h4 class="name" id="getOption"><span class="type-signature"></span>getOption<span class="signature">(name<span class="signature-attributes">opt</span>)</span><span class="type-signature"> → {*|Object.<string, *>}</span></h4>
1676 <div class="description">
1677 <p>Gets the value assigned to the option with the specified name.</p>
1688 <h5>Parameters:</h5>
1691 <table class="params">
1706 <th class="last">Description</th>
1715 <td class="name"><code>name</code></td>
1721 <span class="param-type">string</span>
1728 <td class="attributes">
1741 <td class="description last"><p>Returns the option value if specified, otherwise all options are returned.</p></td>
1753 <dl class="details">
1780 <dt class="tag-source">Source:</dt>
1781 <dd class="tag-source"><ul class="dummy"><li>
1782 <a href="protobuf.js.html">protobuf.js</a>, <a href="protobuf.js.html#line1687">line 1687</a>
1808 <div class="param-desc">
1809 <p>null} Option value or NULL if there is no such option</p>
1820 <span class="param-type">*</span>
1823 <span class="param-type">Object.<string, *></span>
1838 <h4 class="name" id="qn"><span class="type-signature"></span>qn<span class="signature">(t<span class="signature-attributes">non-null</span>)</span><span class="type-signature"> → {string}</span></h4>
1844 <div class="description">
1845 <p>Determines the shortest qualified name of the specified type, if any, relative to this namespace.</p>
1856 <h5>Parameters:</h5>
1859 <table class="params">
1872 <th class="last">Description</th>
1881 <td class="name"><code>t</code></td>
1887 <span class="param-type"><a href="ProtoBuf.Reflect.T.html">ProtoBuf.Reflect.T</a></span>
1897 <td class="description last"><p>Reflection type</p></td>
1909 <dl class="details">
1936 <dt class="tag-source">Source:</dt>
1937 <dd class="tag-source"><ul class="dummy"><li>
1938 <a href="protobuf.js.html">protobuf.js</a>, <a href="protobuf.js.html#line1629">line 1629</a>
1964 <div class="param-desc">
1965 <p>The shortest qualified name or, if there is none, the fqn</p>
1976 <span class="param-type">string</span>
1991 <h4 class="name" id="resolve"><span class="type-signature"></span>resolve<span class="signature">(qn, excludeNonNamespace<span class="signature-attributes">opt</span>)</span><span class="type-signature"> → (nullable) {<a href="ProtoBuf.Reflect.Namespace.html">ProtoBuf.Reflect.Namespace</a>}</span></h4>
1997 <div class="description">
1998 <p>Resolves a reflect object inside of this namespace.</p>
2009 <h5>Parameters:</h5>
2012 <table class="params">
2027 <th class="last">Description</th>
2036 <td class="name"><code>qn</code></td>
2042 <span class="param-type">string</span>
2045 <span class="param-type">!Array.<string></span>
2052 <td class="attributes">
2063 <td class="description last"><p>Qualified name to resolve</p></td>
2070 <td class="name"><code>excludeNonNamespace</code></td>
2076 <span class="param-type">boolean</span>
2083 <td class="attributes">
2096 <td class="description last"><p>Excludes non-namespace types, defaults to <code>false</code></p></td>
2108 <dl class="details">
2135 <dt class="tag-source">Source:</dt>
2136 <dd class="tag-source"><ul class="dummy"><li>
2137 <a href="protobuf.js.html">protobuf.js</a>, <a href="protobuf.js.html#line1591">line 1591</a>
2163 <div class="param-desc">
2164 <p>The resolved type or null if not found</p>
2175 <span class="param-type"><a href="ProtoBuf.Reflect.Namespace.html">ProtoBuf.Reflect.Namespace</a></span>
2190 <h4 class="name" id="toString"><span class="type-signature"></span>toString<span class="signature">(includeClass<span class="signature-attributes">opt</span>)</span><span class="type-signature"></span></h4>
2196 <div class="description">
2197 <p>Returns a string representation of this Reflect object (its fully qualified name).</p>
2208 <h5>Parameters:</h5>
2211 <table class="params">
2226 <th class="last">Description</th>
2235 <td class="name"><code>includeClass</code></td>
2241 <span class="param-type">boolean</span>
2248 <td class="attributes">
2261 <td class="description last"><p>Set to true to include the class name. Defaults to false.</p></td>
2273 <dl class="details">
2280 <dt class="inherited-from">Inherited From:</dt>
2281 <dd class="inherited-from"><ul class="dummy"><li>
2282 <a href="ProtoBuf.Reflect.T.html#toString">ProtoBuf.Reflect.T#toString</a>
2305 <dt class="tag-source">Source:</dt>
2306 <dd class="tag-source"><ul class="dummy"><li>
2307 <a href="protobuf.js.html">protobuf.js</a>, <a href="protobuf.js.html#line1470">line 1470</a>
2333 <div class="param-desc">
2334 <p>String representation</p>
2359 <h2><a href="index.html">Home</a></h2><h3>Classes</h3><ul><li><a href="ProtoBuf.Builder.html">Builder</a></li><li><a href="ProtoBuf.Builder.Message.html">Message</a></li><li><a href="ProtoBuf.Builder.Service.html">Service</a></li><li><a href="ProtoBuf.DotProto.Parser.html">Parser</a></li><li><a href="ProtoBuf.DotProto.Tokenizer.html">Tokenizer</a></li><li><a href="ProtoBuf.Map.html">Map</a></li><li><a href="ProtoBuf.Reflect.Element.html">Element</a></li><li><a href="ProtoBuf.Reflect.Enum.html">Enum</a></li><li><a href="ProtoBuf.Reflect.Enum.Value.html">Value</a></li><li><a href="ProtoBuf.Reflect.Extension.html">Extension</a></li><li><a href="ProtoBuf.Reflect.Message.html">Message</a></li><li><a href="ProtoBuf.Reflect.Message.ExtensionField.html">ExtensionField</a></li><li><a href="ProtoBuf.Reflect.Message.Field.html">Field</a></li><li><a href="ProtoBuf.Reflect.Message.OneOf.html">OneOf</a></li><li><a href="ProtoBuf.Reflect.Namespace.html">Namespace</a></li><li><a href="ProtoBuf.Reflect.Service.html">Service</a></li><li><a href="ProtoBuf.Reflect.Service.Method.html">Method</a></li><li><a href="ProtoBuf.Reflect.Service.RPCMethod.html">RPCMethod</a></li><li><a href="ProtoBuf.Reflect.T.html">T</a></li></ul><h3>Namespaces</h3><ul><li><a href="ProtoBuf.html">ProtoBuf</a></li><li><a href="ProtoBuf.DotProto.html">DotProto</a></li><li><a href="ProtoBuf.Reflect.html">Reflect</a></li><li><a href="ProtoBuf.Util.html">Util</a></li></ul>
2365 Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 3.3.3</a> on Fri Jan 27 2017 17:03:55 GMT+0100 (Mitteleuropäische Zeit)
2368 <script> prettyPrint(); </script>
2369 <script src="scripts/linenumber.js"> </script>