@NotThreadSafe public static final class RemoteFileDescriptionArg.Builder extends Object
RemoteFileDescriptionArg
.
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 |
---|---|
RemoteFileDescriptionArg.Builder |
addAllCompatibleWith(Iterable<? extends UnconfiguredBuildTarget> elements)
Adds elements to
compatibleWith list. |
RemoteFileDescriptionArg.Builder |
addAllLabels(Iterable<String> elements)
Adds elements to
labels sortedSet. |
RemoteFileDescriptionArg.Builder |
addAllLicenses(Iterable<? extends SourcePath> elements)
Adds elements to
licenses set. |
RemoteFileDescriptionArg.Builder |
addCompatibleWith(UnconfiguredBuildTarget... elements)
Adds elements to
compatibleWith list. |
RemoteFileDescriptionArg.Builder |
addCompatibleWith(UnconfiguredBuildTarget element)
Adds one element to
compatibleWith list. |
RemoteFileDescriptionArg.Builder |
addLabels(String... elements)
Adds elements to
labels sortedSet. |
RemoteFileDescriptionArg.Builder |
addLabels(String element)
Adds one element to
labels sortedSet. |
RemoteFileDescriptionArg.Builder |
addLicenses(SourcePath... elements)
Adds elements to
licenses set. |
RemoteFileDescriptionArg.Builder |
addLicenses(SourcePath element)
Adds one element to
licenses set. |
RemoteFileDescriptionArg |
build()
Builds a new
RemoteFileDescriptionArg . |
RemoteFileDescriptionArg.Builder |
from(BuildRuleArg instance)
Fill a builder with attribute values from the provided
com.facebook.buck.core.description.arg.BuildRuleArg instance. |
RemoteFileDescriptionArg.Builder |
from(ConstructorArg instance)
Fill a builder with attribute values from the provided
com.facebook.buck.core.description.arg.ConstructorArg instance. |
RemoteFileDescriptionArg.Builder |
from(com.facebook.buck.file.RemoteFileDescription.AbstractRemoteFileDescriptionArg instance)
Copy abstract value type
AbstractRemoteFileDescriptionArg instance into builder. |
RemoteFileDescriptionArg.Builder |
from(RemoteFileDescriptionArg instance)
Fill a builder with attribute values from the provided
RemoteFileDescriptionArg instance. |
RemoteFileDescriptionArg.Builder |
setCompatibleWith(Iterable<? extends UnconfiguredBuildTarget> elements)
Sets or replaces all elements for
compatibleWith list. |
RemoteFileDescriptionArg.Builder |
setDefaultTargetPlatform(Optional<? extends UnconfiguredBuildTarget> defaultTargetPlatform)
Initializes the optional value
defaultTargetPlatform to defaultTargetPlatform. |
RemoteFileDescriptionArg.Builder |
setDefaultTargetPlatform(UnconfiguredBuildTarget defaultTargetPlatform)
Initializes the optional value
defaultTargetPlatform to defaultTargetPlatform. |
RemoteFileDescriptionArg.Builder |
setLabels(Iterable<String> elements)
Sets or replaces all elements for
labels sortedSet. |
RemoteFileDescriptionArg.Builder |
setLicenses(Iterable<? extends SourcePath> elements)
Sets or replaces all elements for
licenses set. |
RemoteFileDescriptionArg.Builder |
setName(String name)
Initializes the value for the
name attribute. |
RemoteFileDescriptionArg.Builder |
setOut(Optional<String> out)
Initializes the optional value
out to out. |
RemoteFileDescriptionArg.Builder |
setOut(String out)
Initializes the optional value
out to out. |
RemoteFileDescriptionArg.Builder |
setSha1(String sha1)
Initializes the value for the
sha1 attribute. |
RemoteFileDescriptionArg.Builder |
setType(Optional<? extends RemoteFile.Type> type)
Initializes the optional value
type to type. |
RemoteFileDescriptionArg.Builder |
setType(RemoteFile.Type type)
Initializes the optional value
type to type. |
RemoteFileDescriptionArg.Builder |
setUrl(URI url)
Initializes the value for the
url attribute. |
public final RemoteFileDescriptionArg.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 RemoteFileDescriptionArg.Builder from(RemoteFileDescriptionArg instance)
RemoteFileDescriptionArg
instance.instance
- The instance from which to copy valuesthis
builder for use in a chained invocationpublic final RemoteFileDescriptionArg.Builder from(com.facebook.buck.file.RemoteFileDescription.AbstractRemoteFileDescriptionArg instance)
AbstractRemoteFileDescriptionArg
instance into builder.instance
- The instance from which to copy valuesthis
builder for use in a chained invocationpublic final RemoteFileDescriptionArg.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 RemoteFileDescriptionArg.Builder setUrl(URI url)
url
attribute.url
- The value for urlthis
builder for use in a chained invocationpublic final RemoteFileDescriptionArg.Builder setSha1(String sha1)
sha1
attribute.sha1
- The value for sha1this
builder for use in a chained invocationpublic final RemoteFileDescriptionArg.Builder setOut(String out)
out
to out.out
- The value for outthis
builder for chained invocationpublic final RemoteFileDescriptionArg.Builder setOut(Optional<String> out)
out
to out.out
- The value for outthis
builder for use in a chained invocationpublic final RemoteFileDescriptionArg.Builder setType(RemoteFile.Type type)
type
to type.type
- The value for typethis
builder for chained invocationpublic final RemoteFileDescriptionArg.Builder setType(Optional<? extends RemoteFile.Type> type)
type
to type.type
- The value for typethis
builder for use in a chained invocationpublic final RemoteFileDescriptionArg.Builder addLicenses(SourcePath element)
licenses
set.element
- A licenses elementthis
builder for use in a chained invocationpublic final RemoteFileDescriptionArg.Builder addLicenses(SourcePath... elements)
licenses
set.elements
- An array of licenses elementsthis
builder for use in a chained invocationpublic final RemoteFileDescriptionArg.Builder setLicenses(Iterable<? extends SourcePath> elements)
licenses
set.elements
- An iterable of licenses elementsthis
builder for use in a chained invocationpublic final RemoteFileDescriptionArg.Builder addAllLicenses(Iterable<? extends SourcePath> elements)
licenses
set.elements
- An iterable of licenses elementsthis
builder for use in a chained invocationpublic final RemoteFileDescriptionArg.Builder addLabels(String element)
labels
sortedSet.element
- A labels elementthis
builder for use in a chained invocationpublic final RemoteFileDescriptionArg.Builder addLabels(String... elements)
labels
sortedSet.elements
- An array of labels elementsthis
builder for use in a chained invocationpublic final RemoteFileDescriptionArg.Builder setLabels(Iterable<String> elements)
labels
sortedSet.elements
- An iterable of labels elementsthis
builder for use in a chained invocationpublic final RemoteFileDescriptionArg.Builder addAllLabels(Iterable<String> elements)
labels
sortedSet.elements
- An iterable of labels elementsthis
builder for use in a chained invocationpublic final RemoteFileDescriptionArg.Builder setDefaultTargetPlatform(UnconfiguredBuildTarget defaultTargetPlatform)
defaultTargetPlatform
to defaultTargetPlatform.defaultTargetPlatform
- The value for defaultTargetPlatformthis
builder for chained invocationpublic final RemoteFileDescriptionArg.Builder setDefaultTargetPlatform(Optional<? extends UnconfiguredBuildTarget> defaultTargetPlatform)
defaultTargetPlatform
to defaultTargetPlatform.defaultTargetPlatform
- The value for defaultTargetPlatformthis
builder for use in a chained invocationpublic final RemoteFileDescriptionArg.Builder addCompatibleWith(UnconfiguredBuildTarget element)
compatibleWith
list.element
- A compatibleWith elementthis
builder for use in a chained invocationpublic final RemoteFileDescriptionArg.Builder addCompatibleWith(UnconfiguredBuildTarget... elements)
compatibleWith
list.elements
- An array of compatibleWith elementsthis
builder for use in a chained invocationpublic final RemoteFileDescriptionArg.Builder setCompatibleWith(Iterable<? extends UnconfiguredBuildTarget> elements)
compatibleWith
list.elements
- An iterable of compatibleWith elementsthis
builder for use in a chained invocationpublic final RemoteFileDescriptionArg.Builder addAllCompatibleWith(Iterable<? extends UnconfiguredBuildTarget> elements)
compatibleWith
list.elements
- An iterable of compatibleWith elementsthis
builder for use in a chained invocationpublic final RemoteFileDescriptionArg.Builder setName(String name)
name
attribute.name
- The value for namethis
builder for use in a chained invocationpublic RemoteFileDescriptionArg build()
RemoteFileDescriptionArg
.IllegalStateException
- if any required attributes are missing