# Data.Builder

# Data.Builder

Artifact:[androidx.work:work-runtime](https://developer.android.com/jetpack/androidx/releases/work)  
[View Source](https://cs.android.com/search?q=file:androidx/work/Data_.kt+class:androidx.work.Data.Builder)  
Added in[1.0.0](https://developer.android.com/jetpack/androidx/releases/work#1.0.0)

*** ** * ** ***

Kotlin\|[Java](https://developer.android.com/reference/androidx/work/Data.Builder "View this page in Java")

<br />

```
class Data.Builder
```

<br />

*** ** * ** ***

A builder for[Data](https://developer.android.com/reference/kotlin/androidx/work/Data)objects.

## Summary

|                                      ### Public constructors                                       |
|----------------------------------------------------------------------------------------------------|
| [Builder](https://developer.android.com/reference/kotlin/androidx/work/Data.Builder#Builder())`()` |

|                                   ### Public functions                                    |
|-------------------------------------------------------------------------------------------|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| [Data](https://developer.android.com/reference/kotlin/androidx/work/Data)                 | [build](https://developer.android.com/reference/kotlin/androidx/work/Data.Builder#build())`()` Builds a[Data](https://developer.android.com/reference/kotlin/androidx/work/Data)object.                                                                                                                                                                                                                                                                                                                                                    |
| [Data.Builder](https://developer.android.com/reference/kotlin/androidx/work/Data.Builder) | [putAll](https://developer.android.com/reference/kotlin/androidx/work/Data.Builder#putAll(androidx.work.Data))`(data: `[Data](https://developer.android.com/reference/kotlin/androidx/work/Data)`)` Puts all input key-value pairs from a[Data](https://developer.android.com/reference/kotlin/androidx/work/Data)into the Builder.                                                                                                                                                                                                        |
| [Data.Builder](https://developer.android.com/reference/kotlin/androidx/work/Data.Builder) | [putAll](https://developer.android.com/reference/kotlin/androidx/work/Data.Builder#putAll(kotlin.collections.Map))`(values: `[Map](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin.collections/-map/index.html)`<`[String](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html)`, `[Any](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-any/index.html)`?>)` Puts all input key-value pairs from a[Map](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin.collections/-map/index.html)into the Builder. |
| [Data.Builder](https://developer.android.com/reference/kotlin/androidx/work/Data.Builder) | [putBoolean](https://developer.android.com/reference/kotlin/androidx/work/Data.Builder#putBoolean(kotlin.String,kotlin.Boolean))`(key: `[String](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html)`, value: `[Boolean](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-boolean/index.html)`)` Puts a boolean into the arguments.                                                                                                                                                                              |
| [Data.Builder](https://developer.android.com/reference/kotlin/androidx/work/Data.Builder) | [putBooleanArray](https://developer.android.com/reference/kotlin/androidx/work/Data.Builder#putBooleanArray(kotlin.String,kotlin.BooleanArray))`(key: `[String](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html)`, value: `[BooleanArray](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-boolean-array/index.html)`)` Puts a boolean array into the arguments.                                                                                                                                              |
| [Data.Builder](https://developer.android.com/reference/kotlin/androidx/work/Data.Builder) | [putByte](https://developer.android.com/reference/kotlin/androidx/work/Data.Builder#putByte(kotlin.String,kotlin.Byte))`(key: `[String](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html)`, value: `[Byte](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-byte/index.html)`)` Puts an byte into the arguments.                                                                                                                                                                                               |
| [Data.Builder](https://developer.android.com/reference/kotlin/androidx/work/Data.Builder) | [putByteArray](https://developer.android.com/reference/kotlin/androidx/work/Data.Builder#putByteArray(kotlin.String,kotlin.ByteArray))`(key: `[String](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html)`, value: `[ByteArray](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-byte-array/index.html)`)` Puts an integer array into the arguments.                                                                                                                                                            |
| [Data.Builder](https://developer.android.com/reference/kotlin/androidx/work/Data.Builder) | [putDouble](https://developer.android.com/reference/kotlin/androidx/work/Data.Builder#putDouble(kotlin.String,kotlin.Double))`(key: `[String](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html)`, value: `[Double](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-double/index.html)`)` Puts a double into the arguments.                                                                                                                                                                                    |
| [Data.Builder](https://developer.android.com/reference/kotlin/androidx/work/Data.Builder) | [putDoubleArray](https://developer.android.com/reference/kotlin/androidx/work/Data.Builder#putDoubleArray(kotlin.String,kotlin.DoubleArray))`(key: `[String](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html)`, value: `[DoubleArray](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-double-array/index.html)`)` Puts a double array into the arguments.                                                                                                                                                    |
| [Data.Builder](https://developer.android.com/reference/kotlin/androidx/work/Data.Builder) | [putFloat](https://developer.android.com/reference/kotlin/androidx/work/Data.Builder#putFloat(kotlin.String,kotlin.Float))`(key: `[String](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html)`, value: `[Float](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html)`)` Puts a float into the arguments.                                                                                                                                                                                          |
| [Data.Builder](https://developer.android.com/reference/kotlin/androidx/work/Data.Builder) | [putFloatArray](https://developer.android.com/reference/kotlin/androidx/work/Data.Builder#putFloatArray(kotlin.String,kotlin.FloatArray))`(key: `[String](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html)`, value: `[FloatArray](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float-array/index.html)`)` Puts a float array into the arguments.                                                                                                                                                          |
| [Data.Builder](https://developer.android.com/reference/kotlin/androidx/work/Data.Builder) | [putInt](https://developer.android.com/reference/kotlin/androidx/work/Data.Builder#putInt(kotlin.String,kotlin.Int))`(key: `[String](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html)`, value: `[Int](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html)`)` Puts an integer into the arguments.                                                                                                                                                                                                 |
| [Data.Builder](https://developer.android.com/reference/kotlin/androidx/work/Data.Builder) | [putIntArray](https://developer.android.com/reference/kotlin/androidx/work/Data.Builder#putIntArray(kotlin.String,kotlin.IntArray))`(key: `[String](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html)`, value: `[IntArray](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int-array/index.html)`)` Puts an integer array into the arguments.                                                                                                                                                                 |
| [Data.Builder](https://developer.android.com/reference/kotlin/androidx/work/Data.Builder) | [putLong](https://developer.android.com/reference/kotlin/androidx/work/Data.Builder#putLong(kotlin.String,kotlin.Long))`(key: `[String](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html)`, value: `[Long](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-long/index.html)`)` Puts a long into the arguments.                                                                                                                                                                                                |
| [Data.Builder](https://developer.android.com/reference/kotlin/androidx/work/Data.Builder) | [putLongArray](https://developer.android.com/reference/kotlin/androidx/work/Data.Builder#putLongArray(kotlin.String,kotlin.LongArray))`(key: `[String](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html)`, value: `[LongArray](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-long-array/index.html)`)` Puts a long array into the arguments.                                                                                                                                                                |
| [Data.Builder](https://developer.android.com/reference/kotlin/androidx/work/Data.Builder) | [putString](https://developer.android.com/reference/kotlin/androidx/work/Data.Builder#putString(kotlin.String,kotlin.String))`(key: `[String](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html)`, value: `[String](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html)`?)` Puts a String into the arguments.                                                                                                                                                                                   |
| [Data.Builder](https://developer.android.com/reference/kotlin/androidx/work/Data.Builder) | [putStringArray](https://developer.android.com/reference/kotlin/androidx/work/Data.Builder#putStringArray(kotlin.String,kotlin.Array))`(key: `[String](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html)`, value: `[Array](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-array/index.html)`<`[String](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html)`?>)` Puts a String array into the arguments.                                                                                 |

## Public constructors

### Builder

Added in[1.0.0](https://developer.android.com/jetpack/androidx/releases/work#1.0.0)  

```
Builder()
```  

## Public functions

### build

Added in[1.0.0](https://developer.android.com/jetpack/androidx/releases/work#1.0.0)  

```
fun build(): Data
```

Builds a[Data](https://developer.android.com/reference/kotlin/androidx/work/Data)object.  

|                                  Returns                                  |
|---------------------------------------------------------------------------|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| [Data](https://developer.android.com/reference/kotlin/androidx/work/Data) | The[Data](https://developer.android.com/reference/kotlin/androidx/work/Data)object containing all key-value pairs specified by this[Builder](https://developer.android.com/reference/kotlin/androidx/work/Data.Builder). |

### putAll

Added in[1.0.0](https://developer.android.com/jetpack/androidx/releases/work#1.0.0)  

```
fun putAll(data: Data): Data.Builder
```

Puts all input key-value pairs from a[Data](https://developer.android.com/reference/kotlin/androidx/work/Data)into the Builder.

Valid value types are: Boolean, Integer, Long, Float, Double, String, and their array versions. Invalid types will throw an[IllegalArgumentException](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-illegal-argument-exception/index.html).  

|                                    Parameters                                     |
|-----------------------------------------------------------------------------------|------------------------------------------------------------------------------------------------------------|
| `data: `[Data](https://developer.android.com/reference/kotlin/androidx/work/Data) | [Data](https://developer.android.com/reference/kotlin/androidx/work/Data)containing key-value pairs to add |

|                                          Returns                                          |
|-------------------------------------------------------------------------------------------|-----------------------------------------------------------------------------------------|
| [Data.Builder](https://developer.android.com/reference/kotlin/androidx/work/Data.Builder) | The[Builder](https://developer.android.com/reference/kotlin/androidx/work/Data.Builder) |

### putAll

Added in[1.0.0](https://developer.android.com/jetpack/androidx/releases/work#1.0.0)  

```
fun putAll(values: Map<String, Any?>): Data.Builder
```

Puts all input key-value pairs from a[Map](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin.collections/-map/index.html)into the Builder.

Valid value types are: Boolean, Integer, Long, Float, Double, String, and their array versions. Invalid types will throw an[IllegalArgumentException](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-illegal-argument-exception/index.html).  

|                                                                                                                                Parameters                                                                                                                                |
|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|-------------------------------------------------------------------------------------------------------------------|
| `values: `[Map](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin.collections/-map/index.html)`<`[String](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html)`, `[Any](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-any/index.html)`?>` | A[Map](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin.collections/-map/index.html)of key-value pairs to add |

|                                          Returns                                          |
|-------------------------------------------------------------------------------------------|-----------------------------------------------------------------------------------------|
| [Data.Builder](https://developer.android.com/reference/kotlin/androidx/work/Data.Builder) | The[Builder](https://developer.android.com/reference/kotlin/androidx/work/Data.Builder) |

### putBoolean

Added in[1.0.0](https://developer.android.com/jetpack/androidx/releases/work#1.0.0)  

```
fun putBoolean(key: String, value: Boolean): Data.Builder
```

Puts a boolean into the arguments.  

|                                          Parameters                                          |
|----------------------------------------------------------------------------------------------|-----------------------------|
| `key: `[String](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html)     | The key for this argument   |
| `value: `[Boolean](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-boolean/index.html) | The value for this argument |

|                                          Returns                                          |
|-------------------------------------------------------------------------------------------|-----------------------------------------------------------------------------------------|
| [Data.Builder](https://developer.android.com/reference/kotlin/androidx/work/Data.Builder) | The[Builder](https://developer.android.com/reference/kotlin/androidx/work/Data.Builder) |

### putBooleanArray

Added in[1.0.0](https://developer.android.com/jetpack/androidx/releases/work#1.0.0)  

```
fun putBooleanArray(key: String, value: BooleanArray): Data.Builder
```

Puts a boolean array into the arguments.  

|                                               Parameters                                                |
|---------------------------------------------------------------------------------------------------------|-----------------------------|
| `key: `[String](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html)                | The key for this argument   |
| `value: `[BooleanArray](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-boolean-array/index.html) | The value for this argument |

|                                          Returns                                          |
|-------------------------------------------------------------------------------------------|-----------------------------------------------------------------------------------------|
| [Data.Builder](https://developer.android.com/reference/kotlin/androidx/work/Data.Builder) | The[Builder](https://developer.android.com/reference/kotlin/androidx/work/Data.Builder) |

### putByte

Added in[2.1.0](https://developer.android.com/jetpack/androidx/releases/work#2.1.0)  

```
fun putByte(key: String, value: Byte): Data.Builder
```

Puts an byte into the arguments.  

|                                        Parameters                                        |
|------------------------------------------------------------------------------------------|-----------------------------|
| `key: `[String](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html) | The key for this argument   |
| `value: `[Byte](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-byte/index.html)   | The value for this argument |

|                                          Returns                                          |
|-------------------------------------------------------------------------------------------|-----------------------------------------------------------------------------------------|
| [Data.Builder](https://developer.android.com/reference/kotlin/androidx/work/Data.Builder) | The[Builder](https://developer.android.com/reference/kotlin/androidx/work/Data.Builder) |

### putByteArray

Added in[2.1.0](https://developer.android.com/jetpack/androidx/releases/work#2.1.0)  

```
fun putByteArray(key: String, value: ByteArray): Data.Builder
```

Puts an integer array into the arguments.  

|                                            Parameters                                             |
|---------------------------------------------------------------------------------------------------|-----------------------------|
| `key: `[String](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html)          | The key for this argument   |
| `value: `[ByteArray](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-byte-array/index.html) | The value for this argument |

|                                          Returns                                          |
|-------------------------------------------------------------------------------------------|-----------------------------------------------------------------------------------------|
| [Data.Builder](https://developer.android.com/reference/kotlin/androidx/work/Data.Builder) | The[Builder](https://developer.android.com/reference/kotlin/androidx/work/Data.Builder) |

### putDouble

Added in[1.0.0](https://developer.android.com/jetpack/androidx/releases/work#1.0.0)  

```
fun putDouble(key: String, value: Double): Data.Builder
```

Puts a double into the arguments.  

|                                         Parameters                                         |
|--------------------------------------------------------------------------------------------|-----------------------------|
| `key: `[String](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html)   | The key for this argument   |
| `value: `[Double](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-double/index.html) | The value for this argument |

|                                          Returns                                          |
|-------------------------------------------------------------------------------------------|-----------------------------------------------------------------------------------------|
| [Data.Builder](https://developer.android.com/reference/kotlin/androidx/work/Data.Builder) | The[Builder](https://developer.android.com/reference/kotlin/androidx/work/Data.Builder) |

### putDoubleArray

Added in[1.0.0](https://developer.android.com/jetpack/androidx/releases/work#1.0.0)  

```
fun putDoubleArray(key: String, value: DoubleArray): Data.Builder
```

Puts a double array into the arguments.  

|                                              Parameters                                               |
|-------------------------------------------------------------------------------------------------------|-----------------------------|
| `key: `[String](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html)              | The key for this argument   |
| `value: `[DoubleArray](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-double-array/index.html) | The value for this argument |

|                                          Returns                                          |
|-------------------------------------------------------------------------------------------|-----------------------------------------------------------------------------------------|
| [Data.Builder](https://developer.android.com/reference/kotlin/androidx/work/Data.Builder) | The[Builder](https://developer.android.com/reference/kotlin/androidx/work/Data.Builder) |

### putFloat

Added in[1.0.0](https://developer.android.com/jetpack/androidx/releases/work#1.0.0)  

```
fun putFloat(key: String, value: Float): Data.Builder
```

Puts a float into the arguments.  

|                                        Parameters                                        |
|------------------------------------------------------------------------------------------|-----------------------------|
| `key: `[String](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html) | The key for this argument   |
| `value: `[Float](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html) | The value for this argument |

|                                          Returns                                          |
|-------------------------------------------------------------------------------------------|-----------------------------------------------------------------------------------------|
| [Data.Builder](https://developer.android.com/reference/kotlin/androidx/work/Data.Builder) | The[Builder](https://developer.android.com/reference/kotlin/androidx/work/Data.Builder) |

### putFloatArray

Added in[1.0.0](https://developer.android.com/jetpack/androidx/releases/work#1.0.0)  

```
fun putFloatArray(key: String, value: FloatArray): Data.Builder
```

Puts a float array into the arguments.  

|                                             Parameters                                              |
|-----------------------------------------------------------------------------------------------------|-----------------------------|
| `key: `[String](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html)            | The key for this argument   |
| `value: `[FloatArray](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float-array/index.html) | The value for this argument |

|                                          Returns                                          |
|-------------------------------------------------------------------------------------------|-----------------------------------------------------------------------------------------|
| [Data.Builder](https://developer.android.com/reference/kotlin/androidx/work/Data.Builder) | The[Builder](https://developer.android.com/reference/kotlin/androidx/work/Data.Builder) |

### putInt

Added in[1.0.0](https://developer.android.com/jetpack/androidx/releases/work#1.0.0)  

```
fun putInt(key: String, value: Int): Data.Builder
```

Puts an integer into the arguments.  

|                                        Parameters                                        |
|------------------------------------------------------------------------------------------|-----------------------------|
| `key: `[String](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html) | The key for this argument   |
| `value: `[Int](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html)     | The value for this argument |

|                                          Returns                                          |
|-------------------------------------------------------------------------------------------|-----------------------------------------------------------------------------------------|
| [Data.Builder](https://developer.android.com/reference/kotlin/androidx/work/Data.Builder) | The[Builder](https://developer.android.com/reference/kotlin/androidx/work/Data.Builder) |

### putIntArray

Added in[1.0.0](https://developer.android.com/jetpack/androidx/releases/work#1.0.0)  

```
fun putIntArray(key: String, value: IntArray): Data.Builder
```

Puts an integer array into the arguments.  

|                                           Parameters                                            |
|-------------------------------------------------------------------------------------------------|-----------------------------|
| `key: `[String](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html)        | The key for this argument   |
| `value: `[IntArray](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int-array/index.html) | The value for this argument |

|                                          Returns                                          |
|-------------------------------------------------------------------------------------------|-----------------------------------------------------------------------------------------|
| [Data.Builder](https://developer.android.com/reference/kotlin/androidx/work/Data.Builder) | The[Builder](https://developer.android.com/reference/kotlin/androidx/work/Data.Builder) |

### putLong

Added in[1.0.0](https://developer.android.com/jetpack/androidx/releases/work#1.0.0)  

```
fun putLong(key: String, value: Long): Data.Builder
```

Puts a long into the arguments.  

|                                        Parameters                                        |
|------------------------------------------------------------------------------------------|-----------------------------|
| `key: `[String](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html) | The key for this argument   |
| `value: `[Long](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-long/index.html)   | The value for this argument |

|                                          Returns                                          |
|-------------------------------------------------------------------------------------------|-----------------------------------------------------------------------------------------|
| [Data.Builder](https://developer.android.com/reference/kotlin/androidx/work/Data.Builder) | The[Builder](https://developer.android.com/reference/kotlin/androidx/work/Data.Builder) |

### putLongArray

Added in[1.0.0](https://developer.android.com/jetpack/androidx/releases/work#1.0.0)  

```
fun putLongArray(key: String, value: LongArray): Data.Builder
```

Puts a long array into the arguments.  

|                                            Parameters                                             |
|---------------------------------------------------------------------------------------------------|-----------------------------|
| `key: `[String](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html)          | The key for this argument   |
| `value: `[LongArray](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-long-array/index.html) | The value for this argument |

|                                          Returns                                          |
|-------------------------------------------------------------------------------------------|-----------------------------------------------------------------------------------------|
| [Data.Builder](https://developer.android.com/reference/kotlin/androidx/work/Data.Builder) | The[Builder](https://developer.android.com/reference/kotlin/androidx/work/Data.Builder) |

### putString

Added in[1.0.0](https://developer.android.com/jetpack/androidx/releases/work#1.0.0)  

```
fun putString(key: String, value: String?): Data.Builder
```

Puts a String into the arguments.  

|                                          Parameters                                           |
|-----------------------------------------------------------------------------------------------|-----------------------------|
| `key: `[String](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html)      | The key for this argument   |
| `value: `[String](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html)`?` | The value for this argument |

|                                          Returns                                          |
|-------------------------------------------------------------------------------------------|-----------------------------------------------------------------------------------------|
| [Data.Builder](https://developer.android.com/reference/kotlin/androidx/work/Data.Builder) | The[Builder](https://developer.android.com/reference/kotlin/androidx/work/Data.Builder) |

### putStringArray

Added in[1.0.0](https://developer.android.com/jetpack/androidx/releases/work#1.0.0)  

```
fun putStringArray(key: String, value: Array<String?>): Data.Builder
```

Puts a String array into the arguments.  

|                                                                                    Parameters                                                                                    |
|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|-----------------------------|
| `key: `[String](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html)                                                                                         | The key for this argument   |
| `value: `[Array](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-array/index.html)`<`[String](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html)`?>` | The value for this argument |

|                                          Returns                                          |
|-------------------------------------------------------------------------------------------|-----------------------------------------------------------------------------------------|
| [Data.Builder](https://developer.android.com/reference/kotlin/androidx/work/Data.Builder) | The[Builder](https://developer.android.com/reference/kotlin/androidx/work/Data.Builder) |