@@ -81,37 +81,35 @@ raidar.request()
8181
8282Representation of a ReadyNAS device.
8383
84- ### APIs
85-
86- #### Device info
84+ ### Device info APIs
8785
88- ##### mac() : {String}
86+ #### mac() : {String}
8987
9088Get device MAC address.
9189
92- ##### hostname() : {String}
90+ #### hostname() : {String}
9391
9492Get device hostname.
9593
96- ##### ip() : {String}
94+ #### ip() : {String}
9795
9896Get device IP.
9997
100- ##### serial() : {String}
98+ #### serial() : {String}
10199
102100Get device serial number.
103101
104- ##### version() : {String}
102+ #### version() : {String}
105103
106104Get loaded firmware version.
107105
108- #### Disks info
106+ ### Disks info APIs
109107
110- ##### diskCount() : {Number}
108+ #### diskCount() : {Number}
111109
112110Get number of loaded disks.
113111
114- ##### diskInfo({Number} index, {String} [ attribute='status'] ) : {String|Number}
112+ #### diskInfo({Number} index, {String} [ attribute='status'] ) : {String|Number}
115113
116114Get info of a particular disk.
117115
@@ -123,13 +121,13 @@ Get info of a particular disk.
123121| celsius | {Number} | temperature in celsius |
124122| fahrenheit | {Number} | temperature in fahrenheit |
125123
126- #### Volumes info
124+ ### Volumes info APIs
127125
128- ##### volumeCount() : {Number}
126+ #### volumeCount() : {Number}
129127
130128Get number of configured volumes.
131129
132- ##### volumeInfo({Number} index, {String} [ attribute='status'] ) : {String|Number}
130+ #### volumeInfo({Number} index, {String} [ attribute='status'] ) : {String|Number}
133131
134132Get info of a particular volume.
135133
@@ -142,21 +140,21 @@ Get info of a particular volume.
142140| used | {Number} | Used space in bytes |
143141| free | {Number} | Free space in bytes |
144142
145- #### Other info
143+ ### Other APIs
146144
147- ##### getEntities() : {Array}
145+ #### getEntities() : {Array}
148146
149147Get all device entities.
150148
151- ##### getEntity({String} entity, {Number} [ index] ) : {Object}
149+ #### getEntity({String} entity, {Number} [ index] ) : {Object}
152150
153151Get entity data.
154152
155- ##### getEntityAttribute({String} entity, {Number} [ index] , {String} attribute) : {* }
153+ #### getEntityAttribute({String} entity, {Number} [ index] , {String} attribute) : {* }
156154
157155Get single entity attribute.
158156
159- ##### toJSON() : {Object}
157+ #### toJSON() : {Object}
160158
161159Get {Object} representation of ReadyNAS device.
162160
@@ -168,19 +166,19 @@ Handle network data collection.
168166
169167### APIs
170168
171- ##### raidar.isOpen() : {Boolean}
169+ #### raidar.isOpen() : {Boolean}
172170
173171Check if the UDP socket is open.
174172
175- ##### raidar.open({Function} [ callback] )
173+ #### raidar.open({Function} [ callback] )
176174
177175Open a new UPD socket, * callback* has no arguments.
178176
179- ##### raidar.close({Function} [ callback] )
177+ #### raidar.close({Function} [ callback] )
180178
181179Close the UDP socket, * callback* has no arguments.
182180
183- ##### raidar.request({Object} [ options] , {Function} [ callback] )
181+ #### raidar.request({Object} [ options] , {Function} [ callback] )
184182
185183Perform a new ReadyNAS request, if the socket is closed it will be opened.
186184
@@ -193,39 +191,39 @@ Perform a new ReadyNAS request, if the socket is closed it will be opened.
193191
194192### Events
195193
196- ##### raidar.on('listening', function () { ... })
194+ #### raidar.on('listening', function () { ... })
197195
198196Triggered whenever a socket begins listening for datagram messages.
199197
200- ##### raidar.on('close', function () { ... })
198+ #### raidar.on('close', function () { ... })
201199
202200Triggered after a socket is closed with * #close()* API.
203201
204- ##### raidar.on('error', function ({Error} err) { ... })
202+ #### raidar.on('error', function ({Error} err) { ... })
205203
206204Triggered where an error occurs.
207205
208- ##### raidar.on('fail', function ({Error} err, {Buffer} message) { ... })
206+ #### raidar.on('fail', function ({Error} err, {Buffer} message) { ... })
209207
210208Triggered after a error on ReadyNAS instance.
211209
212- ##### raidar.on('message', function ({Buffer} message) { ... })
210+ #### raidar.on('message', function ({Buffer} message) { ... })
213211
214212Clean reponse from a ReadyNAS device.
215213
216- ##### raidar.on('device', function (device) { ... })
214+ #### raidar.on('device', function (device) { ... })
217215
218216Triggered when a ReadyNAS device is found, with a instance of ReadyNAS class.
219217
220- ##### raidar.on('[ IP] ', function (device) { ... })
218+ #### raidar.on('[ IP] ', function (device) { ... })
221219
222220Same as * device* event, but triggered when a specific device is found.
223221
224- ##### raidar.on('[ hostname] ', function (device) { ... })
222+ #### raidar.on('[ hostname] ', function (device) { ... })
225223
226224Same as * device* event, but triggered when a specific device is found.
227225
228- ##### raidar.on('[ MAC address] ', function (device) { ... })
226+ #### raidar.on('[ MAC address] ', function (device) { ... })
229227
230228Same as * device* event, but triggered when a specific device is found.
231229
0 commit comments