# LowpanIdentity.Builder

Summary:[Ctors](https://developer.android.com/reference/com/google/android/things/lowpan/LowpanIdentity.Builder#pubctors)\|[Methods](https://developer.android.com/reference/com/google/android/things/lowpan/LowpanIdentity.Builder#pubmethods)\|[Inherited Methods](https://developer.android.com/reference/com/google/android/things/lowpan/LowpanIdentity.Builder#inhmethods)\|[\[Expand All\]](https://developer.android.com/reference/com/google/android/things/lowpan/LowpanIdentity.Builder#)  

# LowpanIdentity.Builder

`
public
static


class
LowpanIdentity.Builder
`  
`

extends `[Object](https://developer.android.com/reference/java/lang/Object)`


``


`

|---|---------------------------------------------------------|
| [java.lang.Object](https://developer.android.com/reference/java/lang/Object) ||
| ↳ | com.google.android.things.lowpan.LowpanIdentity.Builder |

<br />

*** ** * ** ***

Builder class for constructing instances of LowpanIdentity.

## Summary

|                                                                    ### Public constructors                                                                    ||
|------------------------------------------------------------------------------------------------------------------------------------------------------------|---|
| ` `[LowpanIdentity.Builder](https://developer.android.com/reference/com/google/android/things/lowpan/LowpanIdentity.Builder#LowpanIdentity.Builder())`() ` |

|                                                                                                                                                                               ### Public methods                                                                                                                                                                               ||
|------------------------------------------------------------------------------------------------------------------------------|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| ` `[LowpanIdentity](https://developer.android.com/reference/com/google/android/things/lowpan/LowpanIdentity)                 | ` `[build](https://developer.android.com/reference/com/google/android/things/lowpan/LowpanIdentity.Builder#build())`() ` Builds a LowpanIdentity object based on the previously set criteria.                                                    |
| ` `[LowpanIdentity.Builder](https://developer.android.com/reference/com/google/android/things/lowpan/LowpanIdentity.Builder) | ` `[setChannel](https://developer.android.com/reference/com/google/android/things/lowpan/LowpanIdentity.Builder#setChannel(int))`(int x) ` Sets the channel of the network.                                                                      |
| ` `[LowpanIdentity.Builder](https://developer.android.com/reference/com/google/android/things/lowpan/LowpanIdentity.Builder) | ` `[setName](https://developer.android.com/reference/com/google/android/things/lowpan/LowpanIdentity.Builder#setName(java.lang.String))`(`[String](https://developer.android.com/reference/java/lang/String)` x) ` Sets the name of the network. |
| ` `[LowpanIdentity.Builder](https://developer.android.com/reference/com/google/android/things/lowpan/LowpanIdentity.Builder) | ` `[setPanid](https://developer.android.com/reference/com/google/android/things/lowpan/LowpanIdentity.Builder#setPanid(int))`(int x) ` Sets the PANID of the network.                                                                            |
| ` `[LowpanIdentity.Builder](https://developer.android.com/reference/com/google/android/things/lowpan/LowpanIdentity.Builder) | ` `[setRawName](https://developer.android.com/reference/com/google/android/things/lowpan/LowpanIdentity.Builder#setRawName(byte[]))`(byte[] x) ` Sets the name of the network using raw bytes.                                                   |
| ` `[LowpanIdentity.Builder](https://developer.android.com/reference/com/google/android/things/lowpan/LowpanIdentity.Builder) | ` `[setXpanid](https://developer.android.com/reference/com/google/android/things/lowpan/LowpanIdentity.Builder#setXpanid(byte[]))`(byte[] x) ` Sets the XPANID of the network.                                                                   |

| ### Inherited methods |
|-----------------------|---|
| [![](https://developer.android.com/static/assets/images/styles/disclosure_down.png)](https://developer.android.com/reference/com/google/android/things/lowpan/LowpanIdentity.Builder#)From class` `[java.lang.Object](https://developer.android.com/reference/java/lang/Object)` ` |--------------------------------------------------------------------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------| | ` `[Object](https://developer.android.com/reference/java/lang/Object)          | ` `[clone](https://developer.android.com/reference/java/lang/Object#clone())`() ` Creates and returns a copy of this object.                                                                                                                                                                                                                                                                                                                                                                      | | ` boolean`                                                                     | ` `[equals](https://developer.android.com/reference/java/lang/Object#equals(java.lang.Object))`(`[Object](https://developer.android.com/reference/java/lang/Object)` obj) ` Indicates whether some other object is "equal to" this one.                                                                                                                                                                                                                                                           | | ` void`                                                                        | ` `[finalize](https://developer.android.com/reference/java/lang/Object#finalize())`() ` Called by the garbage collector on an object when garbage collection determines that there are no more references to the object.                                                                                                                                                                                                                                                                          | | ` final `[Class](https://developer.android.com/reference/java/lang/Class)`<?>` | ` `[getClass](https://developer.android.com/reference/java/lang/Object#getClass())`() ` Returns the runtime class of this`Object`.                                                                                                                                                                                                                                                                                                                                                                | | ` int`                                                                         | ` `[hashCode](https://developer.android.com/reference/java/lang/Object#hashCode())`() ` Returns a hash code value for the object.                                                                                                                                                                                                                                                                                                                                                                 | | ` final void`                                                                  | ` `[notify](https://developer.android.com/reference/java/lang/Object#notify())`() ` Wakes up a single thread that is waiting on this object's monitor.                                                                                                                                                                                                                                                                                                                                            | | ` final void`                                                                  | ` `[notifyAll](https://developer.android.com/reference/java/lang/Object#notifyAll())`() ` Wakes up all threads that are waiting on this object's monitor.                                                                                                                                                                                                                                                                                                                                         | | ` `[String](https://developer.android.com/reference/java/lang/String)          | ` `[toString](https://developer.android.com/reference/java/lang/Object#toString())`() ` Returns a string representation of the object.                                                                                                                                                                                                                                                                                                                                                            | | ` final void`                                                                  | ` `[wait](https://developer.android.com/reference/java/lang/Object#wait(long, int))`(long millis, int nanos) ` Causes the current thread to wait until another thread invokes the[notify()](https://developer.android.com/reference/java/lang/Object.html#notify())method or the[notifyAll()](https://developer.android.com/reference/java/lang/Object.html#notifyAll())method for this object, or some other thread interrupts the current thread, or a certain amount of real time has elapsed. | | ` final void`                                                                  | ` `[wait](https://developer.android.com/reference/java/lang/Object#wait(long))`(long millis) ` Causes the current thread to wait until either another thread invokes the[notify()](https://developer.android.com/reference/java/lang/Object.html#notify())method or the[notifyAll()](https://developer.android.com/reference/java/lang/Object.html#notifyAll())method for this object, or a specified amount of time has elapsed.                                                                 | | ` final void`                                                                  | ` `[wait](https://developer.android.com/reference/java/lang/Object#wait())`() ` Causes the current thread to wait until another thread invokes the[notify()](https://developer.android.com/reference/java/lang/Object.html#notify())method or the[notifyAll()](https://developer.android.com/reference/java/lang/Object.html#notifyAll())method for this object.                                                                                                                                  | ||

## Public constructors

### LowpanIdentity.Builder

```
LowpanIdentity.Builder ()
```

<br />

<br />

## Public methods

### build

```
LowpanIdentity build ()
```

Builds a LowpanIdentity object based on the previously set criteria.

<br />

|                                                      Returns                                                      ||
|-----------------------------------------------------------------------------------------------------------|--------|
| [LowpanIdentity](https://developer.android.com/reference/com/google/android/things/lowpan/LowpanIdentity) | <br /> |

### setChannel

```
LowpanIdentity.Builder setChannel (int x)
```

Sets the channel of the network.

<br />

|    Parameters     ||
|-----|--------------|
| `x` | `int` <br /> |

|                                                              Returns                                                              ||
|---------------------------------------------------------------------------------------------------------------------------|--------|
| [LowpanIdentity.Builder](https://developer.android.com/reference/com/google/android/things/lowpan/LowpanIdentity.Builder) | <br /> |

### setName

```
LowpanIdentity.Builder setName (String x)
```

Sets the name of the network.

If the given string isn't normalized, the actual name set will be normalized automatically. If you need to set the exact byte value for the network name, use #setRawName instead.

<br />

|      Parameters      ||
|-----|-----------------|
| `x` | `String` <br /> |

|                                                              Returns                                                              ||
|---------------------------------------------------------------------------------------------------------------------------|--------|
| [LowpanIdentity.Builder](https://developer.android.com/reference/com/google/android/things/lowpan/LowpanIdentity.Builder) | <br /> |

**See also:**

- [setRawName(byte[])](https://developer.android.com/reference/com/google/android/things/lowpan/LowpanIdentity.Builder#setRawName(byte[]))  

### setPanid

```
LowpanIdentity.Builder setPanid (int x)
```

Sets the PANID of the network.

<br />

|    Parameters     ||
|-----|--------------|
| `x` | `int` <br /> |

|                                                              Returns                                                              ||
|---------------------------------------------------------------------------------------------------------------------------|--------|
| [LowpanIdentity.Builder](https://developer.android.com/reference/com/google/android/things/lowpan/LowpanIdentity.Builder) | <br /> |

### setRawName

```
LowpanIdentity.Builder setRawName (byte[] x)
```

Sets the name of the network using raw bytes.

The use of this method should only be necessary in extraordinary circumstances. In almost all cases, you should use #setName instead.

<br />

|     Parameters     ||
|-----|---------------|
| `x` | `byte` <br /> |

|                                                              Returns                                                              ||
|---------------------------------------------------------------------------------------------------------------------------|--------|
| [LowpanIdentity.Builder](https://developer.android.com/reference/com/google/android/things/lowpan/LowpanIdentity.Builder) | <br /> |

**See also:**

- [setName(String)](https://developer.android.com/reference/com/google/android/things/lowpan/LowpanIdentity.Builder#setName(java.lang.String))  

### setXpanid

```
LowpanIdentity.Builder setXpanid (byte[] x)
```

Sets the XPANID of the network.

<br />

|     Parameters     ||
|-----|---------------|
| `x` | `byte` <br /> |

|                                                              Returns                                                              ||
|---------------------------------------------------------------------------------------------------------------------------|--------|
| [LowpanIdentity.Builder](https://developer.android.com/reference/com/google/android/things/lowpan/LowpanIdentity.Builder) | <br /> |

-

  ## Classes

  - [LowpanBeaconInfo](https://developer.android.com/reference/com/google/android/things/lowpan/LowpanBeaconInfo)
  - [LowpanCredential](https://developer.android.com/reference/com/google/android/things/lowpan/LowpanCredential)
  - [LowpanEnergyScanResult](https://developer.android.com/reference/com/google/android/things/lowpan/LowpanEnergyScanResult)
  - [LowpanIdentity](https://developer.android.com/reference/com/google/android/things/lowpan/LowpanIdentity)
  - [LowpanIdentity.Builder](https://developer.android.com/reference/com/google/android/things/lowpan/LowpanIdentity.Builder)
  - [LowpanInterface](https://developer.android.com/reference/com/google/android/things/lowpan/LowpanInterface)
  - [LowpanInterface.Callback](https://developer.android.com/reference/com/google/android/things/lowpan/LowpanInterface.Callback)
  - [LowpanManager](https://developer.android.com/reference/com/google/android/things/lowpan/LowpanManager)
  - [LowpanManager.Callback](https://developer.android.com/reference/com/google/android/things/lowpan/LowpanManager.Callback)
  - [LowpanProvisioningParams](https://developer.android.com/reference/com/google/android/things/lowpan/LowpanProvisioningParams)
  - [LowpanProvisioningParams.Builder](https://developer.android.com/reference/com/google/android/things/lowpan/LowpanProvisioningParams.Builder)
  - [LowpanScanner](https://developer.android.com/reference/com/google/android/things/lowpan/LowpanScanner)
  - [LowpanScanner.Callback](https://developer.android.com/reference/com/google/android/things/lowpan/LowpanScanner.Callback)
-

  ## Exceptions

  - [InterfaceDisabledException](https://developer.android.com/reference/com/google/android/things/lowpan/InterfaceDisabledException)
  - [JoinFailedAtAuthException](https://developer.android.com/reference/com/google/android/things/lowpan/JoinFailedAtAuthException)
  - [JoinFailedAtScanException](https://developer.android.com/reference/com/google/android/things/lowpan/JoinFailedAtScanException)
  - [JoinFailedException](https://developer.android.com/reference/com/google/android/things/lowpan/JoinFailedException)
  - [LowpanException](https://developer.android.com/reference/com/google/android/things/lowpan/LowpanException)
  - [LowpanRuntimeException](https://developer.android.com/reference/com/google/android/things/lowpan/LowpanRuntimeException)
  - [NetworkAlreadyExistsException](https://developer.android.com/reference/com/google/android/things/lowpan/NetworkAlreadyExistsException)
  - [OperationCanceledException](https://developer.android.com/reference/com/google/android/things/lowpan/OperationCanceledException)
  - [WrongStateException](https://developer.android.com/reference/com/google/android/things/lowpan/WrongStateException)