@NotThreadSafe public static final class PlatformArg.Builder extends Object
PlatformArg.
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 |
|---|---|
PlatformArg.Builder |
addAllConstraintValues(Iterable<? extends UnconfiguredBuildTarget> elements)
Adds elements to
constraintValues sortedSet. |
PlatformArg.Builder |
addAllDeps(Iterable<? extends UnconfiguredBuildTarget> elements)
Adds elements to
deps sortedSet. |
PlatformArg.Builder |
addConstraintValues(UnconfiguredBuildTarget... elements)
Adds elements to
constraintValues sortedSet. |
PlatformArg.Builder |
addConstraintValues(UnconfiguredBuildTarget element)
Adds one element to
constraintValues sortedSet. |
PlatformArg.Builder |
addDeps(UnconfiguredBuildTarget... elements)
Adds elements to
deps sortedSet. |
PlatformArg.Builder |
addDeps(UnconfiguredBuildTarget element)
Adds one element to
deps sortedSet. |
PlatformArg |
build()
Builds a new
PlatformArg. |
PlatformArg.Builder |
from(ConstructorArg instance)
Fill a builder with attribute values from the provided
com.facebook.buck.core.description.arg.ConstructorArg instance. |
PlatformArg.Builder |
from(PlatformArg instance)
Fill a builder with attribute values from the provided
PlatformArg instance. |
PlatformArg.Builder |
from(com.facebook.buck.core.rules.platform.PlatformDescription.AbstractPlatformArg instance)
Copy abstract value type
AbstractPlatformArg instance into builder. |
PlatformArg.Builder |
setConstraintValues(Iterable<? extends UnconfiguredBuildTarget> elements)
Sets or replaces all elements for
constraintValues sortedSet. |
PlatformArg.Builder |
setDeps(Iterable<? extends UnconfiguredBuildTarget> elements)
Sets or replaces all elements for
deps sortedSet. |
PlatformArg.Builder |
setName(String name)
Initializes the value for the
name attribute. |
public final PlatformArg.Builder from(PlatformArg instance)
PlatformArg instance.instance - The instance from which to copy valuesthis builder for use in a chained invocationpublic final PlatformArg.Builder from(com.facebook.buck.core.rules.platform.PlatformDescription.AbstractPlatformArg instance)
AbstractPlatformArg instance into builder.instance - The instance from which to copy valuesthis builder for use in a chained invocationpublic final PlatformArg.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 PlatformArg.Builder addConstraintValues(UnconfiguredBuildTarget element)
constraintValues sortedSet.element - A constraintValues elementthis builder for use in a chained invocationpublic final PlatformArg.Builder addConstraintValues(UnconfiguredBuildTarget... elements)
constraintValues sortedSet.elements - An array of constraintValues elementsthis builder for use in a chained invocationpublic final PlatformArg.Builder setConstraintValues(Iterable<? extends UnconfiguredBuildTarget> elements)
constraintValues sortedSet.elements - An iterable of constraintValues elementsthis builder for use in a chained invocationpublic final PlatformArg.Builder addAllConstraintValues(Iterable<? extends UnconfiguredBuildTarget> elements)
constraintValues sortedSet.elements - An iterable of constraintValues elementsthis builder for use in a chained invocationpublic final PlatformArg.Builder addDeps(UnconfiguredBuildTarget element)
deps sortedSet.element - A deps elementthis builder for use in a chained invocationpublic final PlatformArg.Builder addDeps(UnconfiguredBuildTarget... elements)
deps sortedSet.elements - An array of deps elementsthis builder for use in a chained invocationpublic final PlatformArg.Builder setDeps(Iterable<? extends UnconfiguredBuildTarget> elements)
deps sortedSet.elements - An iterable of deps elementsthis builder for use in a chained invocationpublic final PlatformArg.Builder addAllDeps(Iterable<? extends UnconfiguredBuildTarget> elements)
deps sortedSet.elements - An iterable of deps elementsthis builder for use in a chained invocationpublic final PlatformArg.Builder setName(String name)
name attribute.name - The value for namethis builder for use in a chained invocationpublic PlatformArg build()
PlatformArg.IllegalStateException - if any required attributes are missing