SunSPOT API V5.0


com.sun.spot.service
Interface ISpotRadioHelper

All Superinterfaces:
IService
All Known Implementing Classes:
LowPanSpotRadioHelper

public interface ISpotRadioHelper
extends IService

Interface for a generic SPOT Radio Manager service.

Author:
Ron Goldman

Field Summary
 
Fields inherited from interface com.sun.spot.service.IService
PAUSED, PAUSING, READY, RESUMING, RUNNING, STARTING, STOPPED, STOPPING
 
Method Summary
 String getDatagramConnectionProtocol()
          Tell others the Datagram protocol name for use with GCF.
 int getLinkQuality(Datagram dg)
          Returns the link quality for the received datagram.
 int getLinkStrength(Datagram dg)
          Returns the link strength for the received datagram.
 RouteInfo[] getRouteInfo()
          Return an array of the current route info to all known addresses.
 RouteInfo[] getRouteInfo(long address)
          Return information on the current route(s) to the specified destination address.
 String getRoutingManagerName()
          Return the name of the current Routing Manager.
 String getStreamConnectionProtocol()
          Tell others the Stream protocol name for use with GCF.
 long getTimestamp(Datagram dg)
          Return the time that a Datagram packet was actually received/sent.
 boolean isBroadcast(Datagram dg)
          Tell if datagram was sent as a broadcast message.
 boolean isMutableRoutingManager()
          Check whether this Routing Manager allows writing to the Routing Table.
 
Methods inherited from interface com.sun.spot.service.IService
getEnabled, getServiceName, getStatus, isRunning, pause, resume, setEnabled, setServiceName, start, stop
 

Method Detail

getDatagramConnectionProtocol

String getDatagramConnectionProtocol()
Tell others the Datagram protocol name for use with GCF.

Returns:
Datagram protocol name for use with GCF

getStreamConnectionProtocol

String getStreamConnectionProtocol()
Tell others the Stream protocol name for use with GCF.

Returns:
Stream protocol name for use with GCF

getLinkQuality

int getLinkQuality(Datagram dg)
Returns the link quality for the received datagram. Values should range from 0 (unreadable) to 100 (perfect). If transport layer does not have a link quality metric then return -1.

Parameters:
dg - Datagram
Returns:
link quality or -1

getLinkStrength

int getLinkStrength(Datagram dg)
Returns the link strength for the received datagram. Values should range from 0 (weak) to 100 (strong). If transport layer does not have a link strength metric then return -1.

Parameters:
dg - Datagram
Returns:
link strength or -1

getTimestamp

long getTimestamp(Datagram dg)
Return the time that a Datagram packet was actually received/sent.

Parameters:
dg - the Datagram to check
Returns:
time that the Datagram packet was actually received/sent

isBroadcast

boolean isBroadcast(Datagram dg)
Tell if datagram was sent as a broadcast message.

Parameters:
dg - the Datagram to check
Returns:
true if the Datagram had been broadcast

getRoutingManagerName

String getRoutingManagerName()
Return the name of the current Routing Manager.

Returns:
the name of the current Routing Manager

getRouteInfo

RouteInfo[] getRouteInfo(long address)
Return information on the current route(s) to the specified destination address.

Parameters:
address - the specified destination address
Returns:
the current route(s) to the specified destination address

getRouteInfo

RouteInfo[] getRouteInfo()
Return an array of the current route info to all known addresses.

Returns:
the current route info to all known addresses

isMutableRoutingManager

boolean isMutableRoutingManager()
Check whether this Routing Manager allows writing to the Routing Table.

Returns:
true if Routing Table is mutable

SunSPOT API V5.0


Copyright � 2006-2008 Sun Microsystems, Inc. All Rights Reserved.