@NotThreadSafe public static final class CommandAliasDescriptionArg.Builder extends Object
CommandAliasDescriptionArg
.
Initialize attributes and then invoke the build()
method to create an
immutable instance.
Builder
is not thread-safe and generally should not be stored in a field or collection,
but instead used immediately to create instances.
public final CommandAliasDescriptionArg.Builder from(CommandAliasDescriptionArg instance)
CommandAliasDescriptionArg
instance.instance
- The instance from which to copy valuesthis
builder for use in a chained invocationpublic final CommandAliasDescriptionArg.Builder from(com.facebook.buck.shell.CommandAliasDescription.AbstractCommandAliasDescriptionArg instance)
AbstractCommandAliasDescriptionArg
instance into builder.instance
- The instance from which to copy valuesthis
builder for use in a chained invocationpublic final CommandAliasDescriptionArg.Builder from(BuildRuleArg instance)
com.facebook.buck.core.description.arg.BuildRuleArg
instance.instance
- The instance from which to copy valuesthis
builder for use in a chained invocationpublic final CommandAliasDescriptionArg.Builder from(ConstructorArg instance)
com.facebook.buck.core.description.arg.ConstructorArg
instance.instance
- The instance from which to copy valuesthis
builder for use in a chained invocationpublic final CommandAliasDescriptionArg.Builder addArgs(StringWithMacros element)
args
list.element
- A args elementthis
builder for use in a chained invocationpublic final CommandAliasDescriptionArg.Builder addArgs(StringWithMacros... elements)
args
list.elements
- An array of args elementsthis
builder for use in a chained invocationpublic final CommandAliasDescriptionArg.Builder setArgs(Iterable<? extends StringWithMacros> elements)
args
list.elements
- An iterable of args elementsthis
builder for use in a chained invocationpublic final CommandAliasDescriptionArg.Builder addAllArgs(Iterable<? extends StringWithMacros> elements)
args
list.elements
- An iterable of args elementsthis
builder for use in a chained invocationpublic final CommandAliasDescriptionArg.Builder setExe(BuildTarget exe)
exe
to exe.exe
- The value for exethis
builder for chained invocationpublic final CommandAliasDescriptionArg.Builder setExe(Optional<? extends BuildTarget> exe)
exe
to exe.exe
- The value for exethis
builder for use in a chained invocationpublic final CommandAliasDescriptionArg.Builder putPlatformExe(Platform key, BuildTarget value)
platformExe
map.key
- The key in the platformExe mapvalue
- The associated value in the platformExe mapthis
builder for use in a chained invocationpublic final CommandAliasDescriptionArg.Builder putPlatformExe(Map.Entry<? extends Platform,? extends BuildTarget> entry)
platformExe
map. Nulls are not permittedentry
- The key and value entrythis
builder for use in a chained invocationpublic final CommandAliasDescriptionArg.Builder setPlatformExe(Map<? extends Platform,? extends BuildTarget> entries)
platformExe
map. Nulls are not permittedentries
- The entries that will be added to the platformExe mapthis
builder for use in a chained invocationpublic final CommandAliasDescriptionArg.Builder putAllPlatformExe(Map<? extends Platform,? extends BuildTarget> entries)
platformExe
map. Nulls are not permittedentries
- The entries that will be added to the platformExe mapthis
builder for use in a chained invocationpublic final CommandAliasDescriptionArg.Builder putEnv(String key, StringWithMacros value)
env
map.key
- The key in the env mapvalue
- The associated value in the env mapthis
builder for use in a chained invocationpublic final CommandAliasDescriptionArg.Builder putEnv(Map.Entry<String,? extends StringWithMacros> entry)
env
map. Nulls are not permittedentry
- The key and value entrythis
builder for use in a chained invocationpublic final CommandAliasDescriptionArg.Builder setEnv(Map<String,? extends StringWithMacros> entries)
env
map. Nulls are not permittedentries
- The entries that will be added to the env mapthis
builder for use in a chained invocationpublic final CommandAliasDescriptionArg.Builder putAllEnv(Map<String,? extends StringWithMacros> entries)
env
map. Nulls are not permittedentries
- The entries that will be added to the env mapthis
builder for use in a chained invocationpublic final CommandAliasDescriptionArg.Builder addLicenses(SourcePath element)
licenses
set.element
- A licenses elementthis
builder for use in a chained invocationpublic final CommandAliasDescriptionArg.Builder addLicenses(SourcePath... elements)
licenses
set.elements
- An array of licenses elementsthis
builder for use in a chained invocationpublic final CommandAliasDescriptionArg.Builder setLicenses(Iterable<? extends SourcePath> elements)
licenses
set.elements
- An iterable of licenses elementsthis
builder for use in a chained invocationpublic final CommandAliasDescriptionArg.Builder addAllLicenses(Iterable<? extends SourcePath> elements)
licenses
set.elements
- An iterable of licenses elementsthis
builder for use in a chained invocationpublic final CommandAliasDescriptionArg.Builder addLabels(String element)
labels
sortedSet.element
- A labels elementthis
builder for use in a chained invocationpublic final CommandAliasDescriptionArg.Builder addLabels(String... elements)
labels
sortedSet.elements
- An array of labels elementsthis
builder for use in a chained invocationpublic final CommandAliasDescriptionArg.Builder setLabels(Iterable<String> elements)
labels
sortedSet.elements
- An iterable of labels elementsthis
builder for use in a chained invocationpublic final CommandAliasDescriptionArg.Builder addAllLabels(Iterable<String> elements)
labels
sortedSet.elements
- An iterable of labels elementsthis
builder for use in a chained invocationpublic final CommandAliasDescriptionArg.Builder setDefaultTargetPlatform(UnconfiguredBuildTarget defaultTargetPlatform)
defaultTargetPlatform
to defaultTargetPlatform.defaultTargetPlatform
- The value for defaultTargetPlatformthis
builder for chained invocationpublic final CommandAliasDescriptionArg.Builder setDefaultTargetPlatform(Optional<? extends UnconfiguredBuildTarget> defaultTargetPlatform)
defaultTargetPlatform
to defaultTargetPlatform.defaultTargetPlatform
- The value for defaultTargetPlatformthis
builder for use in a chained invocationpublic final CommandAliasDescriptionArg.Builder addCompatibleWith(UnconfiguredBuildTarget element)
compatibleWith
list.element
- A compatibleWith elementthis
builder for use in a chained invocationpublic final CommandAliasDescriptionArg.Builder addCompatibleWith(UnconfiguredBuildTarget... elements)
compatibleWith
list.elements
- An array of compatibleWith elementsthis
builder for use in a chained invocationpublic final CommandAliasDescriptionArg.Builder setCompatibleWith(Iterable<? extends UnconfiguredBuildTarget> elements)
compatibleWith
list.elements
- An iterable of compatibleWith elementsthis
builder for use in a chained invocationpublic final CommandAliasDescriptionArg.Builder addAllCompatibleWith(Iterable<? extends UnconfiguredBuildTarget> elements)
compatibleWith
list.elements
- An iterable of compatibleWith elementsthis
builder for use in a chained invocationpublic final CommandAliasDescriptionArg.Builder setName(String name)
name
attribute.name
- The value for namethis
builder for use in a chained invocationpublic CommandAliasDescriptionArg build()
CommandAliasDescriptionArg
.IllegalStateException
- if any required attributes are missing