Skip to content

Most visited

Recently visited

navigation

LowpanIdentity

LowpanIdentity

public class LowpanIdentity
extends Object

java.lang.Object
   ↳ com.google.android.things.lowpan.LowpanIdentity


Describes an instance of a LoWPAN network.

See also:

Summary

Nested classes

class LowpanIdentity.Builder

Builder class for constructing instances of LowpanIdentity. 

Constants

int UNSPECIFIED_CHANNEL

Value returned from getChannel() when no channel was specified.

int UNSPECIFIED_PANID

Value returned from getPanid() when no PANID was specified.

Public methods

boolean equals(Object rhs)
int getChannel()

Returns the channel index for this LowpanIdentity.

String getName()

Returns the name of the network.

int getPanid()

Returns the PANID for this LowpanIdentity.

byte[] getRawName()

Returns the raw bytes for the network name.

byte[] getXpanid()

Returns the XPANID for this LowpanIdentity.

int hashCode()
boolean isNameValid()

Indicates if the raw network name is a valid and normalized UTF8 encoding.

String toString()

Inherited methods

From class java.lang.Object

Constants

UNSPECIFIED_CHANNEL

int UNSPECIFIED_CHANNEL

Value returned from getChannel() when no channel was specified.

Constant Value: -1 (0xffffffff)

UNSPECIFIED_PANID

int UNSPECIFIED_PANID

Value returned from getPanid() when no PANID was specified.

Constant Value: -1 (0xffffffff)

Public methods

equals

boolean equals (Object rhs)

Parameters
rhs Object
Returns
boolean

getChannel

int getChannel ()

Returns the channel index for this LowpanIdentity.

If not set, will return UNSPECIFIED_CHANNEL.

Returns
int

See also:

getName

String getName ()

Returns the name of the network.

Note that if the name of this network is not considered normal or ambiguous, the returned string will be escaped into a non-ambigous form. To get the actual byte values for the network name, use getRawName().

Returns
String

See also:

getPanid

int getPanid ()

Returns the PANID for this LowpanIdentity.

If not set, will return UNSPECIFIED_PANID.

Returns
int

See also:

getRawName

byte[] getRawName ()

Returns the raw bytes for the network name.

These bytes may differ from the UTF8 encoding of the result from getName() if the network name is not considered normal or ambiguous.

Returns
byte[]

See also:

getXpanid

byte[] getXpanid ()

Returns the XPANID for this LowpanIdentity.

If not set, will return an empty array.

Returns
byte[]

hashCode

int hashCode ()

Returns
int

isNameValid

boolean isNameValid ()

Indicates if the raw network name is a valid and normalized UTF8 encoding.

Returns
boolean true if the network name is valid and normalized UTF8. false otherwise.

See also:

toString

String toString ()

Returns
String
This site uses cookies to store your preferences for site-specific language and display options.

Get the latest Android developer news and tips that will help you find success on Google Play.

* Required Fields

Hooray!

Follow Google Developers on WeChat

Browse this site in ?

You requested a page in , but your language preference for this site is .

Would you like to change your language preference and browse this site in ? If you want to change your language preference later, use the language menu at the bottom of each page.

This class requires API level or higher

This doc is hidden because your selected API level for the documentation is . You can change the documentation API level with the selector above the left navigation.

For more information about specifying the API level your app requires, read Supporting Different Platform Versions.

Take a short survey?
Help us improve the Android developer experience. (April 2018 — Developer Survey)