@@ -178,8 +178,8 @@ public List<RemoteXBeeDevice> discoverDevices(IList<string> ids)/*throws XBeeExc
178178 * @throws InterfaceNotOpenException if the device is not open.
179179 * @throws ArgumentNullException if {@code listeners == null}.
180180 *
181- * @see #isRunning ()
182- * @see #stopDiscoveryProcess ()
181+ * @see #IsRunning ()
182+ * @see #StopDiscoveryProcess ()
183183 */
184184 public void startDiscoveryProcess ( IList < IDiscoveryListener > listeners )
185185 {
@@ -211,26 +211,25 @@ public void startDiscoveryProcess(IList<IDiscoveryListener> listeners)
211211 /**
212212 * Stops the discovery process if it is running.
213213 *
214- * @see #isRunning ()
214+ * @see #IsRunning ()
215215 * @see #startDiscoveryProcess(List)
216216 */
217- public void stopDiscoveryProcess ( )
217+ public void StopDiscoveryProcess ( )
218218 {
219219 discovering = false ;
220220 }
221221
222- /**
223- * Retrieves whether the discovery process is running.
224- *
225- * @return {@code true} if the discovery process is running, {@code false}
226- * otherwise.
227- *
228- * @see #startDiscoveryProcess(List)
229- * @see #stopDiscoveryProcess()
230- */
231- public bool isRunning ( )
222+ /// <summary>
223+ /// Indicates whether the discovery process is running.
224+ /// </summary>
225+ /// <see cref="StartDiscoveryProcess"/>
226+ /// <see cref="StopDiscoveryProcess"/>
227+ public bool IsRunning
232228 {
233- return running ;
229+ get
230+ {
231+ return running ;
232+ }
234233 }
235234
236235 /**
@@ -292,7 +291,7 @@ public async void PacketReceived(XBeePacket receivedPacket)
292291 _node . deviceList . Add ( rdevice ) ;
293292 }
294293 // If the local device is 802.15.4 wait until the 'end' command is received.
295- if ( _node . xbeeDevice . GetXBeeProtocol ( ) != XBeeProtocol . RAW_802_15_4 )
294+ if ( _node . xbeeDevice . XBeeProtocol != XBeeProtocol . RAW_802_15_4 )
296295 _node . discovering = false ;
297296 }
298297 }
@@ -327,12 +326,12 @@ private void DiscoverDevicesAPI(IList<IDiscoveryListener> listeners, string id)/
327326
328327 // In 802.15.4 devices, the discovery finishes when the 'end' command
329328 // is received, so it's not necessary to calculate the timeout.
330- if ( xbeeDevice . GetXBeeProtocol ( ) != XBeeProtocol . RAW_802_15_4 )
329+ if ( xbeeDevice . XBeeProtocol != XBeeProtocol . RAW_802_15_4 )
331330 deadLine += CalculateTimeout ( listeners ) ;
332331
333332 sendNodeDiscoverCommand ( id ) ;
334333
335- if ( xbeeDevice . GetXBeeProtocol ( ) != XBeeProtocol . RAW_802_15_4 )
334+ if ( xbeeDevice . XBeeProtocol != XBeeProtocol . RAW_802_15_4 )
336335 {
337336 // Wait for scan timeout.
338337 while ( discovering )
@@ -411,17 +410,17 @@ private long CalculateTimeout(IList<IDiscoveryListener> listeners)
411410 // In DigiMesh/DigiPoint the network discovery timeout is NT + the
412411 // network propagation time. It means that if the user sends an AT
413412 // command just after NT ms, s/he will receive a timeout exception.
414- if ( xbeeDevice . GetXBeeProtocol ( ) == XBeeProtocol . DIGI_MESH )
413+ if ( xbeeDevice . XBeeProtocol == XBeeProtocol . DIGI_MESH )
415414 {
416415 timeout += 3000 ;
417416 }
418- else if ( xbeeDevice . GetXBeeProtocol ( ) == XBeeProtocol . DIGI_POINT )
417+ else if ( xbeeDevice . XBeeProtocol == XBeeProtocol . DIGI_POINT )
419418 {
420419 timeout += 8000 ;
421420 }
422421 }
423422
424- if ( xbeeDevice . GetXBeeProtocol ( ) == XBeeProtocol . DIGI_MESH )
423+ if ( xbeeDevice . XBeeProtocol == XBeeProtocol . DIGI_MESH )
425424 {
426425 try
427426 {
@@ -513,7 +512,7 @@ private async Task<RemoteXBeeDevice> ParseDiscoveryAPIData(byte[] data, XBeeDevi
513512 addr64 = new XBee64BitAddress ( await ByteUtils . ReadBytes ( 8 , inputStream ) ) ;
514513
515514
516- switch ( localDevice . GetXBeeProtocol ( ) )
515+ switch ( localDevice . XBeeProtocol )
517516 {
518517 case XBeeProtocol . ZIGBEE :
519518 case XBeeProtocol . DIGI_MESH :
@@ -537,7 +536,7 @@ private async Task<RemoteXBeeDevice> ParseDiscoveryAPIData(byte[] data, XBeeDevi
537536 manufacturerID = await ByteUtils . ReadBytes ( 2 , inputStream ) ;
538537
539538 logger . DebugFormat ( "{0}Discovered {1} device: 16-bit[{2}], 64-bit[{3}], id[{4}], parent[{5}], profile[{6}], manufacturer[{7}]." ,
540- xbeeDevice . ToString ( ) , localDevice . GetXBeeProtocol ( ) . GetDescription ( ) , addr16 ,
539+ xbeeDevice . ToString ( ) , localDevice . XBeeProtocol . GetDescription ( ) , addr16 ,
541540 addr64 , id , parentAddress , HexUtils . ByteArrayToHexString ( profileID ) ,
542541 HexUtils . ByteArrayToHexString ( manufacturerID ) ) ;
543542
@@ -549,18 +548,18 @@ private async Task<RemoteXBeeDevice> ParseDiscoveryAPIData(byte[] data, XBeeDevi
549548 id = ByteUtils . ReadString ( inputStream ) ;
550549
551550 logger . DebugFormat ( "{0}Discovered {1} device: 16-bit[{2}], 64-bit[{3}], id[{4}], rssi[{5}]." ,
552- xbeeDevice . ToString ( ) , localDevice . GetXBeeProtocol ( ) . GetDescription ( ) , addr16 , addr64 , id , signalStrength ) ;
551+ xbeeDevice . ToString ( ) , localDevice . XBeeProtocol . GetDescription ( ) , addr16 , addr64 , id , signalStrength ) ;
553552
554553 break ;
555554 case XBeeProtocol . UNKNOWN :
556555 default :
557556 logger . DebugFormat ( "{0}Discovered {1} device: 16-bit[{2}], 64-bit[{3}]." ,
558- xbeeDevice . ToString ( ) , localDevice . GetXBeeProtocol ( ) . GetDescription ( ) , addr16 , addr64 ) ;
557+ xbeeDevice . ToString ( ) , localDevice . XBeeProtocol . GetDescription ( ) , addr16 , addr64 ) ;
559558 break ;
560559 }
561560
562561 // Create device and fill with parameters.
563- switch ( localDevice . GetXBeeProtocol ( ) )
562+ switch ( localDevice . XBeeProtocol )
564563 {
565564 case XBeeProtocol . ZIGBEE :
566565 device = new RemoteZigBeeDevice ( localDevice , addr64 , addr16 , id /*, role*/ ) ;
0 commit comments