grpc.credentials.html 25 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459146014611462146314641465146614671468146914701471147214731474147514761477147814791480148114821483148414851486148714881489149014911492149314941495149614971498149915001501150215031504150515061507150815091510151115121513151415151516151715181519152015211522152315241525152615271528152915301531153215331534153515361537153815391540154115421543154415451546154715481549155015511552155315541555155615571558155915601561156215631564156515661567156815691570157115721573157415751576157715781579158015811582158315841585158615871588158915901591159215931594159515961597159815991600160116021603160416051606160716081609161016111612161316141615161616171618161916201621162216231624162516261627162816291630163116321633163416351636163716381639164016411642164316441645164616471648164916501651165216531654165516561657165816591660166116621663166416651666166716681669167016711672167316741675167616771678167916801681168216831684168516861687168816891690169116921693169416951696169716981699170017011702170317041705
  1. <!DOCTYPE html>
  2. <html lang="en">
  3. <head>
  4. <meta charset="utf-8">
  5. <meta name="viewport" content="width=device-width">
  6. <title>Documentation Namespace: credentials</title>
  7. <!--[if lt IE 9]>
  8. <script src="//html5shiv.googlecode.com/svn/trunk/html5.js"></script>
  9. <![endif]-->
  10. <link type="text/css" rel="stylesheet" href="styles/sunlight.default.css">
  11. <link type="text/css" rel="stylesheet" href="styles/site.simplex.css">
  12. </head>
  13. <body>
  14. <div class="navbar navbar-default navbar-fixed-top ">
  15. <div class="container">
  16. <div class="navbar-header">
  17. <a class="navbar-brand" href="index.html">Documentation</a>
  18. <button class="navbar-toggle" type="button" data-toggle="collapse" data-target="#topNavigation">
  19. <span class="icon-bar"></span>
  20. <span class="icon-bar"></span>
  21. <span class="icon-bar"></span>
  22. </button>
  23. </div>
  24. <div class="navbar-collapse collapse" id="topNavigation">
  25. <ul class="nav navbar-nav">
  26. <li class="dropdown">
  27. <a href="namespaces.list.html" class="dropdown-toggle" data-toggle="dropdown">Namespaces<b class="caret"></b></a>
  28. <ul class="dropdown-menu ">
  29. <li><a href="grpc.html">grpc</a></li><li><a href="grpc.credentials.html">grpc.credentials</a></li>
  30. </ul>
  31. </li>
  32. <li class="dropdown">
  33. <a href="classes.list.html" class="dropdown-toggle" data-toggle="dropdown">Classes<b class="caret"></b></a>
  34. <ul class="dropdown-menu ">
  35. <li><a href="grpc.Client.html">grpc.Client</a></li><li><a href="grpc.credentials-CallCredentials.html">grpc.credentials~CallCredentials</a></li><li><a href="grpc.credentials-ChannelCredentials.html">grpc.credentials~ChannelCredentials</a></li><li><a href="grpc.Metadata.html">grpc.Metadata</a></li><li><a href="grpc.Server.html">grpc.Server</a></li><li><a href="grpc.ServerCredentials.html">grpc.ServerCredentials</a></li><li><a href="grpc-ClientDuplexStream.html">grpc~ClientDuplexStream</a></li><li><a href="grpc-ClientReadableStream.html">grpc~ClientReadableStream</a></li><li><a href="grpc-ClientUnaryCall.html">grpc~ClientUnaryCall</a></li><li><a href="grpc-ClientWritableStream.html">grpc~ClientWritableStream</a></li><li><a href="grpc-ServerDuplexStream.html">grpc~ServerDuplexStream</a></li><li><a href="grpc-ServerReadableStream.html">grpc~ServerReadableStream</a></li><li><a href="grpc-ServerUnaryCall.html">grpc~ServerUnaryCall</a></li><li><a href="grpc-ServerWritableStream.html">grpc~ServerWritableStream</a></li>
  36. </ul>
  37. </li>
  38. <li class="dropdown">
  39. <a href="events.list.html" class="dropdown-toggle" data-toggle="dropdown">Events<b class="caret"></b></a>
  40. <ul class="dropdown-menu ">
  41. <li><a href="grpc-ClientDuplexStream.html#event:metadata">grpc~ClientDuplexStream#metadata</a></li><li><a href="grpc-ClientDuplexStream.html#event:status">grpc~ClientDuplexStream#status</a></li><li><a href="grpc-ClientReadableStream.html#event:metadata">grpc~ClientReadableStream#metadata</a></li><li><a href="grpc-ClientReadableStream.html#event:status">grpc~ClientReadableStream#status</a></li><li><a href="grpc-ClientUnaryCall.html#event:metadata">grpc~ClientUnaryCall#event:metadata</a></li><li><a href="grpc-ClientUnaryCall.html#event:status">grpc~ClientUnaryCall#event:status</a></li><li><a href="grpc-ClientWritableStream.html#event:metadata">grpc~ClientWritableStream#metadata</a></li><li><a href="grpc-ClientWritableStream.html#event:status">grpc~ClientWritableStream#status</a></li><li><a href="grpc-ServerDuplexStream.html#~event:cancelled">grpc~ServerDuplexStream~event:cancelled</a></li><li><a href="grpc-ServerReadableStream.html#~event:cancelled">grpc~ServerReadableStream~event:cancelled</a></li><li><a href="grpc-ServerUnaryCall.html#~event:cancelled">grpc~ServerUnaryCall~event:cancelled</a></li><li><a href="grpc-ServerWritableStream.html#~event:cancelled">grpc~ServerWritableStream~event:cancelled</a></li>
  42. </ul>
  43. </li>
  44. <li class="dropdown">
  45. <a href="externals.list.html" class="dropdown-toggle" data-toggle="dropdown">Externals<b class="caret"></b></a>
  46. <ul class="dropdown-menu ">
  47. <li><a href="external-Duplex.html">Duplex</a></li><li><a href="external-EventEmitter.html">EventEmitter</a></li><li><a href="external-GoogleCredential.html">GoogleCredential</a></li><li><a href="external-Readable.html">Readable</a></li><li><a href="external-Writable.html">Writable</a></li>
  48. </ul>
  49. </li>
  50. </ul>
  51. <div class="col-sm-3 col-md-3">
  52. <form class="navbar-form" role="search">
  53. <div class="input-group">
  54. <input type="text" class="form-control" placeholder="Search" name="q" id="search-input">
  55. <div class="input-group-btn">
  56. <button class="btn btn-default" id="search-submit"><i class="glyphicon glyphicon-search"></i></button>
  57. </div>
  58. </div>
  59. </form>
  60. </div>
  61. </div>
  62. </div>
  63. </div>
  64. <div class="container" id="toc-content">
  65. <div class="row">
  66. <div class="col-md-8">
  67. <div id="main">
  68. <h1 class="page-title">Namespace: credentials</h1>
  69. <section>
  70. <header>
  71. <h2>
  72. <span class="ancestors"><a href="grpc.html">grpc</a>.</span>
  73. credentials
  74. </h2>
  75. </header>
  76. <article>
  77. <div class="container-overview">
  78. <div class="description"><p>Credentials module</p>
  79. <p>This module contains factory methods for two different credential types:
  80. CallCredentials and ChannelCredentials. ChannelCredentials are things like
  81. SSL credentials that can be used to secure a connection, and are used to
  82. construct a Client object. CallCredentials genrally modify metadata, so they
  83. can be attached to an individual method call.</p>
  84. <p>CallCredentials can be composed with other CallCredentials to create
  85. CallCredentials. ChannelCredentials can be composed with CallCredentials
  86. to create ChannelCredentials. No combined credential can have more than
  87. one ChannelCredentials.</p>
  88. <p>For example, to create a client secured with SSL that uses Google
  89. default application credentials to authenticate:</p></div>
  90. <dl class="details">
  91. </dl>
  92. <h3>Example</h3>
  93. <pre class="sunlight-highlight-javascript">var channel_creds = credentials.createSsl(root_certs);
  94. (new GoogleAuth()).getApplicationDefault(function(err, credential) {
  95. var call_creds = credentials.createFromGoogleCredential(credential);
  96. var combined_creds = credentials.combineChannelCredentials(
  97. channel_creds, call_creds);
  98. var client = new Client(address, combined_creds);
  99. });</pre>
  100. </div>
  101. <h3 class="subsection-title">Classes</h3>
  102. <dl>
  103. <dt><a href="grpc.credentials-CallCredentials.html">CallCredentials</a></dt>
  104. <dd></dd>
  105. <dt><a href="grpc.credentials-ChannelCredentials.html">ChannelCredentials</a></dt>
  106. <dd></dd>
  107. </dl>
  108. <h3 class="subsection-title">Methods</h3>
  109. <dl>
  110. <hr>
  111. <dt>
  112. <h4 class="name" id=".combineCallCredentials"><span class="type-signature">&lt;static> </span>combineCallCredentials(credentials)</h4>
  113. </dt>
  114. <dd>
  115. <div class="description">
  116. <p>Combine any number of CallCredentials into a single CallCredentials object</p>
  117. </div>
  118. <h5>Parameters:</h5>
  119. <table class="params table table-striped">
  120. <thead>
  121. <tr>
  122. <th>Name</th>
  123. <th>Type</th>
  124. <th>Argument</th>
  125. <th class="last">Description</th>
  126. </tr>
  127. </thead>
  128. <tbody>
  129. <tr>
  130. <td class="name"><code>credentials</code></td>
  131. <td class="type">
  132. <span class="param-type"><a href="grpc.credentials-CallCredentials.html">grpc.credentials~CallCredentials</a></span>
  133. </td>
  134. <td class="attributes">
  135. &lt;repeatable><br>
  136. </td>
  137. <td class="description last"><p>The CallCredentials to compose</p></td>
  138. </tr>
  139. </tbody>
  140. </table>
  141. <dl class="details">
  142. </dl>
  143. <h5>Returns:</h5>
  144. <div class="param-desc">
  145. <p>A credentials object that combines all of the input
  146. credentials</p>
  147. </div>
  148. <dl>
  149. <dt>
  150. Type
  151. </dt>
  152. <dd>
  153. <span class="param-type"><a href="grpc.credentials-CallCredentials.html">grpc.credentials~CallCredentials</a></span>
  154. </dd>
  155. </dl>
  156. </dd>
  157. <hr>
  158. <dt>
  159. <h4 class="name" id=".combineChannelCredentials"><span class="type-signature">&lt;static> </span>combineChannelCredentials(channel_credential, credentials)</h4>
  160. </dt>
  161. <dd>
  162. <div class="description">
  163. <p>Combine a ChannelCredentials with any number of CallCredentials into a single
  164. ChannelCredentials object.</p>
  165. </div>
  166. <h5>Parameters:</h5>
  167. <table class="params table table-striped">
  168. <thead>
  169. <tr>
  170. <th>Name</th>
  171. <th>Type</th>
  172. <th>Argument</th>
  173. <th class="last">Description</th>
  174. </tr>
  175. </thead>
  176. <tbody>
  177. <tr>
  178. <td class="name"><code>channel_credential</code></td>
  179. <td class="type">
  180. <span class="param-type"><a href="grpc.credentials-ChannelCredentials.html">grpc.credentials~ChannelCredentials</a></span>
  181. </td>
  182. <td class="attributes">
  183. </td>
  184. <td class="description last"><p>The ChannelCredentials to
  185. start with</p></td>
  186. </tr>
  187. <tr>
  188. <td class="name"><code>credentials</code></td>
  189. <td class="type">
  190. <span class="param-type"><a href="grpc.credentials-CallCredentials.html">grpc.credentials~CallCredentials</a></span>
  191. </td>
  192. <td class="attributes">
  193. &lt;repeatable><br>
  194. </td>
  195. <td class="description last"><p>The CallCredentials to compose</p></td>
  196. </tr>
  197. </tbody>
  198. </table>
  199. <dl class="details">
  200. </dl>
  201. <h5>Returns:</h5>
  202. <div class="param-desc">
  203. <p>A credentials object that combines all of the
  204. input credentials</p>
  205. </div>
  206. <dl>
  207. <dt>
  208. Type
  209. </dt>
  210. <dd>
  211. <span class="param-type"><a href="grpc.credentials-ChannelCredentials.html">grpc.credentials~ChannelCredentials</a></span>
  212. </dd>
  213. </dl>
  214. </dd>
  215. <hr>
  216. <dt>
  217. <h4 class="name" id=".createFromGoogleCredential"><span class="type-signature">&lt;static> </span>createFromGoogleCredential(google_credential)</h4>
  218. </dt>
  219. <dd>
  220. <div class="description">
  221. <p>Create a gRPC credential from a Google credential object.</p>
  222. </div>
  223. <h5>Parameters:</h5>
  224. <table class="params table table-striped">
  225. <thead>
  226. <tr>
  227. <th>Name</th>
  228. <th>Type</th>
  229. <th class="last">Description</th>
  230. </tr>
  231. </thead>
  232. <tbody>
  233. <tr>
  234. <td class="name"><code>google_credential</code></td>
  235. <td class="type">
  236. <span class="param-type"><a href="external-GoogleCredential.html">external:GoogleCredential</a></span>
  237. </td>
  238. <td class="description last"><p>The Google credential
  239. object to use</p></td>
  240. </tr>
  241. </tbody>
  242. </table>
  243. <dl class="details">
  244. </dl>
  245. <h5>Returns:</h5>
  246. <div class="param-desc">
  247. <p>The resulting credentials object</p>
  248. </div>
  249. <dl>
  250. <dt>
  251. Type
  252. </dt>
  253. <dd>
  254. <span class="param-type"><a href="grpc.credentials-CallCredentials.html">grpc.credentials~CallCredentials</a></span>
  255. </dd>
  256. </dl>
  257. </dd>
  258. <hr>
  259. <dt>
  260. <h4 class="name" id=".createFromMetadataGenerator"><span class="type-signature">&lt;static> </span>createFromMetadataGenerator(metadata_generator)</h4>
  261. </dt>
  262. <dd>
  263. <div class="description">
  264. <p>Create a gRPC credentials object from a metadata generation function. This
  265. function gets the service URL and a callback as parameters. The error
  266. passed to the callback can optionally have a 'code' value attached to it,
  267. which corresponds to a status code that this library uses.</p>
  268. </div>
  269. <h5>Parameters:</h5>
  270. <table class="params table table-striped">
  271. <thead>
  272. <tr>
  273. <th>Name</th>
  274. <th>Type</th>
  275. <th class="last">Description</th>
  276. </tr>
  277. </thead>
  278. <tbody>
  279. <tr>
  280. <td class="name"><code>metadata_generator</code></td>
  281. <td class="type">
  282. <span class="param-type"><a href="grpc.credentials.html#~generateMetadata">grpc.credentials~generateMetadata</a></span>
  283. </td>
  284. <td class="description last"><p>The function
  285. that generates metadata</p></td>
  286. </tr>
  287. </tbody>
  288. </table>
  289. <dl class="details">
  290. </dl>
  291. <h5>Returns:</h5>
  292. <div class="param-desc">
  293. <p>The credentials object</p>
  294. </div>
  295. <dl>
  296. <dt>
  297. Type
  298. </dt>
  299. <dd>
  300. <span class="param-type"><a href="grpc.credentials-CallCredentials.html">grpc.credentials~CallCredentials</a></span>
  301. </dd>
  302. </dl>
  303. </dd>
  304. <hr>
  305. <dt>
  306. <h4 class="name" id=".createInsecure"><span class="type-signature">&lt;static> </span>createInsecure()</h4>
  307. </dt>
  308. <dd>
  309. <div class="description">
  310. <p>Create an insecure credentials object. This is used to create a channel that
  311. does not use SSL. This cannot be composed with anything.</p>
  312. </div>
  313. <dl class="details">
  314. </dl>
  315. <h5>Returns:</h5>
  316. <div class="param-desc">
  317. <p>The insecure credentials object</p>
  318. </div>
  319. <dl>
  320. <dt>
  321. Type
  322. </dt>
  323. <dd>
  324. <span class="param-type"><a href="grpc.credentials-ChannelCredentials.html">grpc.credentials~ChannelCredentials</a></span>
  325. </dd>
  326. </dl>
  327. </dd>
  328. <hr>
  329. <dt>
  330. <h4 class="name" id=".createSsl"><span class="type-signature">&lt;static> </span>createSsl( [root_certs] [, private_key] [, cert_chain])</h4>
  331. </dt>
  332. <dd>
  333. <div class="description">
  334. <p>Create an SSL Credentials object. If using a client-side certificate, both
  335. the second and third arguments must be passed.</p>
  336. </div>
  337. <h5>Parameters:</h5>
  338. <table class="params table table-striped">
  339. <thead>
  340. <tr>
  341. <th>Name</th>
  342. <th>Type</th>
  343. <th>Argument</th>
  344. <th class="last">Description</th>
  345. </tr>
  346. </thead>
  347. <tbody>
  348. <tr>
  349. <td class="name"><code>root_certs</code></td>
  350. <td class="type">
  351. <span class="param-type">Buffer</span>
  352. </td>
  353. <td class="attributes">
  354. &lt;optional><br>
  355. </td>
  356. <td class="description last"><p>The root certificate data</p></td>
  357. </tr>
  358. <tr>
  359. <td class="name"><code>private_key</code></td>
  360. <td class="type">
  361. <span class="param-type">Buffer</span>
  362. </td>
  363. <td class="attributes">
  364. &lt;optional><br>
  365. </td>
  366. <td class="description last"><p>The client certificate private key, if
  367. applicable</p></td>
  368. </tr>
  369. <tr>
  370. <td class="name"><code>cert_chain</code></td>
  371. <td class="type">
  372. <span class="param-type">Buffer</span>
  373. </td>
  374. <td class="attributes">
  375. &lt;optional><br>
  376. </td>
  377. <td class="description last"><p>The client certificate cert chain, if applicable</p></td>
  378. </tr>
  379. </tbody>
  380. </table>
  381. <dl class="details">
  382. </dl>
  383. <h5>Returns:</h5>
  384. <div class="param-desc">
  385. <p>The SSL Credentials object</p>
  386. </div>
  387. <dl>
  388. <dt>
  389. Type
  390. </dt>
  391. <dd>
  392. <span class="param-type"><a href="grpc.credentials-ChannelCredentials.html">grpc.credentials~ChannelCredentials</a></span>
  393. </dd>
  394. </dl>
  395. </dd>
  396. </dl>
  397. <h3 class="subsection-title">Type Definitions</h3>
  398. <dl>
  399. <hr>
  400. <dt>
  401. <h4 class="name" id="~generateMetadata"><span class="type-signature"></span>generateMetadata(params, callback)</h4>
  402. </dt>
  403. <dd>
  404. <h5>Parameters:</h5>
  405. <table class="params table table-striped">
  406. <thead>
  407. <tr>
  408. <th>Name</th>
  409. <th>Type</th>
  410. <th class="last">Description</th>
  411. </tr>
  412. </thead>
  413. <tbody>
  414. <tr>
  415. <td class="name"><code>params</code></td>
  416. <td class="type">
  417. <span class="param-type">Object</span>
  418. </td>
  419. <td class="description last"><p>Parameters that can modify metadata generation</p>
  420. <h6 class="method-params-label method-subparams-label">Properties</h6>
  421. <table class="params table table-striped">
  422. <thead>
  423. <tr>
  424. <th>Name</th>
  425. <th>Type</th>
  426. <th class="last">Description</th>
  427. </tr>
  428. </thead>
  429. <tbody>
  430. <tr>
  431. <td class="name"><code>service_url</code></td>
  432. <td class="type">
  433. <span class="param-type">string</span>
  434. </td>
  435. <td class="description last"><p>The URL of the service that the call is
  436. going to</p></td>
  437. </tr>
  438. </tbody>
  439. </table>
  440. </td>
  441. </tr>
  442. <tr>
  443. <td class="name"><code>callback</code></td>
  444. <td class="type">
  445. <span class="param-type"><a href="grpc.credentials.html#~metadataCallback">grpc.credentials~metadataCallback</a></span>
  446. </td>
  447. <td class="description last"></td>
  448. </tr>
  449. </tbody>
  450. </table>
  451. <dl class="details">
  452. </dl>
  453. </dd>
  454. <hr>
  455. <dt>
  456. <h4 class="name" id="~metadataCallback"><span class="type-signature"></span>metadataCallback(error, metadata)</h4>
  457. </dt>
  458. <dd>
  459. <h5>Parameters:</h5>
  460. <table class="params table table-striped">
  461. <thead>
  462. <tr>
  463. <th>Name</th>
  464. <th>Type</th>
  465. <th class="last">Description</th>
  466. </tr>
  467. </thead>
  468. <tbody>
  469. <tr>
  470. <td class="name"><code>error</code></td>
  471. <td class="type">
  472. <span class="param-type">Error</span>
  473. </td>
  474. <td class="description last"><p>The error, if getting metadata failed</p></td>
  475. </tr>
  476. <tr>
  477. <td class="name"><code>metadata</code></td>
  478. <td class="type">
  479. <span class="param-type"><a href="grpc.Metadata.html">grpc.Metadata</a></span>
  480. </td>
  481. <td class="description last"><p>The metadata</p></td>
  482. </tr>
  483. </tbody>
  484. </table>
  485. <dl class="details">
  486. </dl>
  487. </dd>
  488. </dl>
  489. </article>
  490. </section>
  491. </div>
  492. </div>
  493. <div class="clearfix"></div>
  494. <div class="col-md-3">
  495. <div id="toc" class="col-md-3 hidden-xs hidden-sm hidden-md"></div>
  496. </div>
  497. </div>
  498. </div>
  499. <div class="modal fade" id="searchResults">
  500. <div class="modal-dialog">
  501. <div class="modal-content">
  502. <div class="modal-header">
  503. <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">&times;</span></button>
  504. <h4 class="modal-title">Search results</h4>
  505. </div>
  506. <div class="modal-body"></div>
  507. <div class="modal-footer">
  508. <button type="button" class="btn btn-default" data-dismiss="modal">Close</button>
  509. </div>
  510. </div><!-- /.modal-content -->
  511. </div><!-- /.modal-dialog -->
  512. </div>
  513. <footer>
  514. <span class="jsdoc-message">
  515. Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 3.5.5</a>
  516. on 2018-01-16T12:05:13-05:00
  517. using the <a href="https://github.com/docstrap/docstrap">DocStrap template</a>.
  518. </span>
  519. </footer>
  520. <script src="scripts/docstrap.lib.js"></script>
  521. <script src="scripts/toc.js"></script>
  522. <script type="text/javascript" src="scripts/fulltext-search-ui.js"></script>
  523. <script>
  524. $( function () {
  525. $( "[id*='$']" ).each( function () {
  526. var $this = $( this );
  527. $this.attr( "id", $this.attr( "id" ).replace( "$", "__" ) );
  528. } );
  529. $( ".tutorial-section pre, .readme-section pre, pre.prettyprint.source" ).each( function () {
  530. var $this = $( this );
  531. var example = $this.find( "code" );
  532. exampleText = example.html();
  533. var lang = /{@lang (.*?)}/.exec( exampleText );
  534. if ( lang && lang[1] ) {
  535. exampleText = exampleText.replace( lang[0], "" );
  536. example.html( exampleText );
  537. lang = lang[1];
  538. } else {
  539. var langClassMatch = example.parent()[0].className.match(/lang\-(\S+)/);
  540. lang = langClassMatch ? langClassMatch[1] : "javascript";
  541. }
  542. if ( lang ) {
  543. $this
  544. .addClass( "sunlight-highlight-" + lang )
  545. .addClass( "linenums" )
  546. .html( example.html() );
  547. }
  548. } );
  549. Sunlight.highlightAll( {
  550. lineNumbers : false,
  551. showMenu : true,
  552. enableDoclinks : true
  553. } );
  554. $.catchAnchorLinks( {
  555. navbarOffset: 10
  556. } );
  557. $( "#toc" ).toc( {
  558. anchorName : function ( i, heading, prefix ) {
  559. return $( heading ).attr( "id" ) || ( prefix + i );
  560. },
  561. selectors : "#toc-content h1,#toc-content h2,#toc-content h3,#toc-content h4",
  562. showAndHide : false,
  563. smoothScrolling: true
  564. } );
  565. $( "#main span[id^='toc']" ).addClass( "toc-shim" );
  566. $( '.dropdown-toggle' ).dropdown();
  567. $( "table" ).each( function () {
  568. var $this = $( this );
  569. $this.addClass('table');
  570. } );
  571. } );
  572. </script>
  573. <!--Navigation and Symbol Display-->
  574. <!--Google Analytics-->
  575. <script type="text/javascript">
  576. $(document).ready(function() {
  577. SearcherDisplay.init();
  578. });
  579. </script>
  580. </body>
  581. </html>