# addStringOption

open fun addStringOption(option: String): JavadocOptionFileOption<String>(source)

Adds an option that will have one string value supplied as a separate argument. Calling this method behaves exactly like calling `addStringOption(option, null)`.

`addStringOption("foo")` will not produce any arguments.

`addStringOption("foo").setValue("bar baz")` will produce the command-line

        -foo 'bar baz'

Content copied to clipboard

#### Return

an option object to further configure the value

#### Parameters

option

command-line option

open fun addStringOption(option: String, value: String): JavadocOptionFileOption<String>(source)

Adds an option that will have one string value supplied as a separate argument.

`addStringOption("foo", "bar baz")` will produce the command-line

        -foo 'bar baz'

Content copied to clipboard

A value of `null` will make the option not be supplied and can be used to unset an option that previously was set.

The returned option object can also be used to further configure the value.

`addStringOption("foo", "bar baz").setValue("bam")` will produce the command-line

        -foo bam

Content copied to clipboard

#### Return

an option object to further configure the value

#### Parameters

option

command-line option

value

the value to supply or `null` to suppress the option