balena-cli/doc/file/lib/resin/device/device.coffee.html
2014-12-09 09:05:37 -04:00

260 lines
5.8 KiB
HTML

<!DOCTYPE html>
<html>
<head>
<meta charset='UTF-8'>
<title>CoffeeScript API Documentation</title>
<script src='../../../../javascript/application.js'></script>
<script src='../../../../javascript/search.js'></script>
<link rel='stylesheet' href='../../../../stylesheets/application.css' type='text/css'>
</head>
<body>
<div id='base' data-path='../../../../'></div>
<div id='header'>
<div id='menu'>
<a href='../../../../alphabetical_index.html' title='Index'>
Index
</a>
&raquo;
<span class='title'>lib</span>
&raquo;
<span class='title'>resin</span>
&raquo;
<span class='title'>device</span>
&raquo;
<span class='title'>device.coffee</span>
</div>
</div>
<div id='content'>
<h1>
File:
device.coffee
</h1>
<table class='box'>
<tr>
<td>Defined in:</td>
<td>lib&#47;resin&#47;device</td>
</tr>
</table>
<h2>Method Summary</h2>
<ul class='summary'>
<li>
<span class='signature'>
<a href='#getDisplayName-'>
~
(String)
<b>getDisplayName</b><span>(device)</span>
</a>
</span>
<span class='desc'>
Get display name for a device <p>For a list of supported devices, see getSupportedDevices()</p><pre><code>console.log resin.device.getDisplayName(&#39;raspberry-pi&#39;)
</code></pre>
</span>
</li>
<li>
<span class='signature'>
<a href='#getDeviceSlug-'>
~
(String)
<b>getDeviceSlug</b><span>(device)</span>
</a>
</span>
<span class='desc'>
Get device slug <pre><code>console.log resin.device.getDeviceSlug(&#39;Raspberry Pi&#39;)
</code></pre>
</span>
</li>
<li>
<span class='signature'>
<a href='#getSupportedDevices-'>
~
(Array&lt;String&gt;)
<b>getSupportedDevices</b><span>()</span>
</a>
</span>
<span class='desc'>
Get a list of supported devices <pre><code>devices = resin.device.getSupportedDevices()
console.log(devices)
</code></pre>
</span>
</li>
</ul>
<h2>Method Details</h2>
<div class='methods'>
<div class='method_details'>
<p class='signature' id='getDisplayName-'>
~
(String)
<b>getDisplayName</b><span>(device)</span>
<br>
</p>
<div class='docstring'>
<p>Get display name for a device</p><p>For a list of supported devices, see getSupportedDevices()</p><pre><code>console.log resin.device.getDisplayName(&#39;raspberry-pi&#39;) # Raspberry Pi
console.log resin.device.getDisplayName(&#39;rpi&#39;) # Raspberry Pi
</code></pre>
</div>
<div class='tags'>
<h3>Parameters:</h3>
<ul class='param'>
<li>
<span class='name'>device</span>
<span class='type'>
(
<tt>String</tt>
)
</span>
&mdash;
<span class='desc'>device name </span>
</li>
</ul>
<h3>Returns:</h3>
<ul class='return'>
<li>
<span class='type'></span>
(
<tt>String</tt>
)
&mdash;
<span class='desc'>device display name or &#39;Unknown&#39; </span>
</li>
</ul>
</div>
</div>
<div class='method_details'>
<p class='signature' id='getDeviceSlug-'>
~
(String)
<b>getDeviceSlug</b><span>(device)</span>
<br>
</p>
<div class='docstring'>
<p>Get device slug</p><pre><code>console.log resin.device.getDeviceSlug(&#39;Raspberry Pi&#39;) # raspberry-pi
</code></pre>
</div>
<div class='tags'>
<h3>Parameters:</h3>
<ul class='param'>
<li>
<span class='name'>device</span>
<span class='type'>
(
<tt>String</tt>
)
</span>
&mdash;
<span class='desc'>device name </span>
</li>
</ul>
<h3>Returns:</h3>
<ul class='return'>
<li>
<span class='type'></span>
(
<tt>String</tt>
)
&mdash;
<span class='desc'>device slug or &#39;unknown&#39; </span>
</li>
</ul>
</div>
</div>
<div class='method_details'>
<p class='signature' id='getSupportedDevices-'>
~
(Array&lt;String&gt;)
<b>getSupportedDevices</b><span>()</span>
<br>
</p>
<div class='docstring'>
<p>Get a list of supported devices</p><pre><code>devices = resin.device.getSupportedDevices()
console.log(devices)
</code></pre>
</div>
<div class='tags'>
<h3>Returns:</h3>
<ul class='return'>
<li>
<span class='type'></span>
(
<tt>Array&lt;String&gt;</tt>
)
&mdash;
<span class='desc'>a list of all supported devices, by their display names </span>
</li>
</ul>
</div>
</div>
</div>
</div>
<div id='footer'>
December 09, 14 09:05:26 by
<a href='https://github.com/coffeedoc/codo' title='CoffeeScript API documentation generator'>
Codo
</a>
2.0.9
&#10034;
Press H to see the keyboard shortcuts
&#10034;
<a href='http://twitter.com/netzpirat' target='_parent'>@netzpirat</a>
&#10034;
<a href='http://twitter.com/_inossidabile' target='_parent'>@_inossidabile</a>
</div>
<iframe id='search_frame'></iframe>
<div id='fuzzySearch'>
<input type='text'>
<ol></ol>
</div>
<div id='help'>
<p>
Quickly fuzzy find classes, mixins, methods, file:
</p>
<ul>
<li>
<span>T</span>
Open fuzzy finder dialog
</li>
</ul>
<p>
Control the navigation frame:
</p>
<ul>
<li>
<span>L</span>
Toggle list view
</li>
<li>
<span>C</span>
Show class list
</li>
<li>
<span>I</span>
Show mixin list
</li>
<li>
<span>F</span>
Show file list
</li>
<li>
<span>M</span>
Show method list
</li>
<li>
<span>E</span>
Show extras list
</li>
</ul>
<p>
You can focus and blur the search input:
</p>
<ul>
<li>
<span>S</span>
Focus search input
</li>
<li>
<span>Esc</span>
Blur search input
</li>
</ul>
</div>
</body>
</html>