@NotThreadSafe public static final class LuaBinaryDescriptionArg.Builder extends Object
LuaBinaryDescriptionArg
.
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.
Modifier and Type | Method and Description |
---|---|
LuaBinaryDescriptionArg.Builder |
addAllCompatibleWith(Iterable<? extends UnconfiguredBuildTarget> elements)
Adds elements to
compatibleWith list. |
LuaBinaryDescriptionArg.Builder |
addAllDeps(Iterable<? extends BuildTarget> elements)
Adds elements to
deps sortedSet. |
LuaBinaryDescriptionArg.Builder |
addAllLabels(Iterable<String> elements)
Adds elements to
labels sortedSet. |
LuaBinaryDescriptionArg.Builder |
addAllLicenses(Iterable<? extends SourcePath> elements)
Adds elements to
licenses set. |
LuaBinaryDescriptionArg.Builder |
addCompatibleWith(UnconfiguredBuildTarget... elements)
Adds elements to
compatibleWith list. |
LuaBinaryDescriptionArg.Builder |
addCompatibleWith(UnconfiguredBuildTarget element)
Adds one element to
compatibleWith list. |
LuaBinaryDescriptionArg.Builder |
addDeps(BuildTarget... elements)
Adds elements to
deps sortedSet. |
LuaBinaryDescriptionArg.Builder |
addDeps(BuildTarget element)
Adds one element to
deps sortedSet. |
LuaBinaryDescriptionArg.Builder |
addLabels(String... elements)
Adds elements to
labels sortedSet. |
LuaBinaryDescriptionArg.Builder |
addLabels(String element)
Adds one element to
labels sortedSet. |
LuaBinaryDescriptionArg.Builder |
addLicenses(SourcePath... elements)
Adds elements to
licenses set. |
LuaBinaryDescriptionArg.Builder |
addLicenses(SourcePath element)
Adds one element to
licenses set. |
LuaBinaryDescriptionArg |
build()
Builds a new
LuaBinaryDescriptionArg . |
LuaBinaryDescriptionArg.Builder |
from(BuildRuleArg instance)
Fill a builder with attribute values from the provided
com.facebook.buck.core.description.arg.BuildRuleArg instance. |
LuaBinaryDescriptionArg.Builder |
from(ConstructorArg instance)
Fill a builder with attribute values from the provided
com.facebook.buck.core.description.arg.ConstructorArg instance. |
LuaBinaryDescriptionArg.Builder |
from(HasDeclaredDeps instance)
Fill a builder with attribute values from the provided
com.facebook.buck.core.description.arg.HasDeclaredDeps instance. |
LuaBinaryDescriptionArg.Builder |
from(com.facebook.buck.features.lua.LuaBinaryDescription.AbstractLuaBinaryDescriptionArg instance)
Copy abstract value type
AbstractLuaBinaryDescriptionArg instance into builder. |
LuaBinaryDescriptionArg.Builder |
from(LuaBinaryDescriptionArg instance)
Fill a builder with attribute values from the provided
LuaBinaryDescriptionArg instance. |
LuaBinaryDescriptionArg.Builder |
setCompatibleWith(Iterable<? extends UnconfiguredBuildTarget> elements)
Sets or replaces all elements for
compatibleWith list. |
LuaBinaryDescriptionArg.Builder |
setDefaultTargetPlatform(Optional<? extends UnconfiguredBuildTarget> defaultTargetPlatform)
Initializes the optional value
defaultTargetPlatform to defaultTargetPlatform. |
LuaBinaryDescriptionArg.Builder |
setDefaultTargetPlatform(UnconfiguredBuildTarget defaultTargetPlatform)
Initializes the optional value
defaultTargetPlatform to defaultTargetPlatform. |
LuaBinaryDescriptionArg.Builder |
setDeps(Iterable<? extends BuildTarget> elements)
Sets or replaces all elements for
deps sortedSet. |
LuaBinaryDescriptionArg.Builder |
setLabels(Iterable<String> elements)
Sets or replaces all elements for
labels sortedSet. |
LuaBinaryDescriptionArg.Builder |
setLicenses(Iterable<? extends SourcePath> elements)
Sets or replaces all elements for
licenses set. |
LuaBinaryDescriptionArg.Builder |
setMainModule(String mainModule)
Initializes the value for the
mainModule attribute. |
LuaBinaryDescriptionArg.Builder |
setName(String name)
Initializes the value for the
name attribute. |
LuaBinaryDescriptionArg.Builder |
setNativeStarterLibrary(BuildTarget nativeStarterLibrary)
Initializes the optional value
nativeStarterLibrary to nativeStarterLibrary. |
LuaBinaryDescriptionArg.Builder |
setNativeStarterLibrary(Optional<? extends BuildTarget> nativeStarterLibrary)
Initializes the optional value
nativeStarterLibrary to nativeStarterLibrary. |
LuaBinaryDescriptionArg.Builder |
setPackageStyle(LuaPlatform.PackageStyle packageStyle)
Initializes the optional value
packageStyle to packageStyle. |
LuaBinaryDescriptionArg.Builder |
setPackageStyle(Optional<? extends LuaPlatform.PackageStyle> packageStyle)
Initializes the optional value
packageStyle to packageStyle. |
LuaBinaryDescriptionArg.Builder |
setPlatform(Flavor platform)
Initializes the optional value
platform to platform. |
LuaBinaryDescriptionArg.Builder |
setPlatform(Optional<? extends Flavor> platform)
Initializes the optional value
platform to platform. |
LuaBinaryDescriptionArg.Builder |
setPlatformDeps(PatternMatchedCollection<com.google.common.collect.ImmutableSortedSet<BuildTarget>> platformDeps)
Initializes the value for the
platformDeps attribute. |
LuaBinaryDescriptionArg.Builder |
setPythonPlatform(Optional<String> pythonPlatform)
Initializes the optional value
pythonPlatform to pythonPlatform. |
LuaBinaryDescriptionArg.Builder |
setPythonPlatform(String pythonPlatform)
Initializes the optional value
pythonPlatform to pythonPlatform. |
public final LuaBinaryDescriptionArg.Builder from(HasDeclaredDeps instance)
com.facebook.buck.core.description.arg.HasDeclaredDeps
instance.instance
- The instance from which to copy valuesthis
builder for use in a chained invocationpublic final LuaBinaryDescriptionArg.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 LuaBinaryDescriptionArg.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 LuaBinaryDescriptionArg.Builder from(LuaBinaryDescriptionArg instance)
LuaBinaryDescriptionArg
instance.instance
- The instance from which to copy valuesthis
builder for use in a chained invocationpublic final LuaBinaryDescriptionArg.Builder from(com.facebook.buck.features.lua.LuaBinaryDescription.AbstractLuaBinaryDescriptionArg instance)
AbstractLuaBinaryDescriptionArg
instance into builder.instance
- The instance from which to copy valuesthis
builder for use in a chained invocationpublic final LuaBinaryDescriptionArg.Builder setMainModule(String mainModule)
mainModule
attribute.mainModule
- The value for mainModulethis
builder for use in a chained invocationpublic final LuaBinaryDescriptionArg.Builder setNativeStarterLibrary(BuildTarget nativeStarterLibrary)
nativeStarterLibrary
to nativeStarterLibrary.nativeStarterLibrary
- The value for nativeStarterLibrarythis
builder for chained invocationpublic final LuaBinaryDescriptionArg.Builder setNativeStarterLibrary(Optional<? extends BuildTarget> nativeStarterLibrary)
nativeStarterLibrary
to nativeStarterLibrary.nativeStarterLibrary
- The value for nativeStarterLibrarythis
builder for use in a chained invocationpublic final LuaBinaryDescriptionArg.Builder setPythonPlatform(String pythonPlatform)
pythonPlatform
to pythonPlatform.pythonPlatform
- The value for pythonPlatformthis
builder for chained invocationpublic final LuaBinaryDescriptionArg.Builder setPythonPlatform(Optional<String> pythonPlatform)
pythonPlatform
to pythonPlatform.pythonPlatform
- The value for pythonPlatformthis
builder for use in a chained invocationpublic final LuaBinaryDescriptionArg.Builder setPlatform(Flavor platform)
platform
to platform.platform
- The value for platformthis
builder for chained invocationpublic final LuaBinaryDescriptionArg.Builder setPlatform(Optional<? extends Flavor> platform)
platform
to platform.platform
- The value for platformthis
builder for use in a chained invocationpublic final LuaBinaryDescriptionArg.Builder setPackageStyle(LuaPlatform.PackageStyle packageStyle)
packageStyle
to packageStyle.packageStyle
- The value for packageStylethis
builder for chained invocationpublic final LuaBinaryDescriptionArg.Builder setPackageStyle(Optional<? extends LuaPlatform.PackageStyle> packageStyle)
packageStyle
to packageStyle.packageStyle
- The value for packageStylethis
builder for use in a chained invocationpublic final LuaBinaryDescriptionArg.Builder setPlatformDeps(PatternMatchedCollection<com.google.common.collect.ImmutableSortedSet<BuildTarget>> platformDeps)
platformDeps
attribute.
If not set, this attribute will have a default value as returned by the initializer of platformDeps
.
platformDeps
- The value for platformDepsthis
builder for use in a chained invocationpublic final LuaBinaryDescriptionArg.Builder addCompatibleWith(UnconfiguredBuildTarget element)
compatibleWith
list.element
- A compatibleWith elementthis
builder for use in a chained invocationpublic final LuaBinaryDescriptionArg.Builder addCompatibleWith(UnconfiguredBuildTarget... elements)
compatibleWith
list.elements
- An array of compatibleWith elementsthis
builder for use in a chained invocationpublic final LuaBinaryDescriptionArg.Builder setCompatibleWith(Iterable<? extends UnconfiguredBuildTarget> elements)
compatibleWith
list.elements
- An iterable of compatibleWith elementsthis
builder for use in a chained invocationpublic final LuaBinaryDescriptionArg.Builder addAllCompatibleWith(Iterable<? extends UnconfiguredBuildTarget> elements)
compatibleWith
list.elements
- An iterable of compatibleWith elementsthis
builder for use in a chained invocationpublic final LuaBinaryDescriptionArg.Builder setDefaultTargetPlatform(UnconfiguredBuildTarget defaultTargetPlatform)
defaultTargetPlatform
to defaultTargetPlatform.defaultTargetPlatform
- The value for defaultTargetPlatformthis
builder for chained invocationpublic final LuaBinaryDescriptionArg.Builder setDefaultTargetPlatform(Optional<? extends UnconfiguredBuildTarget> defaultTargetPlatform)
defaultTargetPlatform
to defaultTargetPlatform.defaultTargetPlatform
- The value for defaultTargetPlatformthis
builder for use in a chained invocationpublic final LuaBinaryDescriptionArg.Builder addLabels(String element)
labels
sortedSet.element
- A labels elementthis
builder for use in a chained invocationpublic final LuaBinaryDescriptionArg.Builder addLabels(String... elements)
labels
sortedSet.elements
- An array of labels elementsthis
builder for use in a chained invocationpublic final LuaBinaryDescriptionArg.Builder setLabels(Iterable<String> elements)
labels
sortedSet.elements
- An iterable of labels elementsthis
builder for use in a chained invocationpublic final LuaBinaryDescriptionArg.Builder addAllLabels(Iterable<String> elements)
labels
sortedSet.elements
- An iterable of labels elementsthis
builder for use in a chained invocationpublic final LuaBinaryDescriptionArg.Builder addLicenses(SourcePath element)
licenses
set.element
- A licenses elementthis
builder for use in a chained invocationpublic final LuaBinaryDescriptionArg.Builder addLicenses(SourcePath... elements)
licenses
set.elements
- An array of licenses elementsthis
builder for use in a chained invocationpublic final LuaBinaryDescriptionArg.Builder setLicenses(Iterable<? extends SourcePath> elements)
licenses
set.elements
- An iterable of licenses elementsthis
builder for use in a chained invocationpublic final LuaBinaryDescriptionArg.Builder addAllLicenses(Iterable<? extends SourcePath> elements)
licenses
set.elements
- An iterable of licenses elementsthis
builder for use in a chained invocationpublic final LuaBinaryDescriptionArg.Builder setName(String name)
name
attribute.name
- The value for namethis
builder for use in a chained invocationpublic final LuaBinaryDescriptionArg.Builder addDeps(BuildTarget element)
deps
sortedSet.element
- A deps elementthis
builder for use in a chained invocationpublic final LuaBinaryDescriptionArg.Builder addDeps(BuildTarget... elements)
deps
sortedSet.elements
- An array of deps elementsthis
builder for use in a chained invocationpublic final LuaBinaryDescriptionArg.Builder setDeps(Iterable<? extends BuildTarget> elements)
deps
sortedSet.elements
- An iterable of deps elementsthis
builder for use in a chained invocationpublic final LuaBinaryDescriptionArg.Builder addAllDeps(Iterable<? extends BuildTarget> elements)
deps
sortedSet.elements
- An iterable of deps elementsthis
builder for use in a chained invocationpublic LuaBinaryDescriptionArg build()
LuaBinaryDescriptionArg
.IllegalStateException
- if any required attributes are missing