@NotThreadSafe public static final class PrebuiltOcamlLibraryDescriptionArg.Builder extends Object
PrebuiltOcamlLibraryDescriptionArg
.
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 PrebuiltOcamlLibraryDescriptionArg.Builder from(PrebuiltOcamlLibraryDescriptionArg instance)
PrebuiltOcamlLibraryDescriptionArg
instance.instance
- The instance from which to copy valuesthis
builder for use in a chained invocationpublic final PrebuiltOcamlLibraryDescriptionArg.Builder from(com.facebook.buck.features.ocaml.PrebuiltOcamlLibraryDescription.AbstractPrebuiltOcamlLibraryDescriptionArg instance)
AbstractPrebuiltOcamlLibraryDescriptionArg
instance into builder.instance
- The instance from which to copy valuesthis
builder for use in a chained invocationpublic final PrebuiltOcamlLibraryDescriptionArg.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 PrebuiltOcamlLibraryDescriptionArg.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 PrebuiltOcamlLibraryDescriptionArg.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 PrebuiltOcamlLibraryDescriptionArg.Builder setLibDir(String libDir)
libDir
attribute.
If not set, this attribute will have a default value as returned by the initializer of libDir
.
libDir
- The value for libDirthis
builder for use in a chained invocationpublic final PrebuiltOcamlLibraryDescriptionArg.Builder setIncludeDir(String includeDir)
includeDir
attribute.
If not set, this attribute will have a default value as returned by the initializer of includeDir
.
includeDir
- The value for includeDirthis
builder for use in a chained invocationpublic final PrebuiltOcamlLibraryDescriptionArg.Builder setLibName(String libName)
libName
attribute.
If not set, this attribute will have a default value as returned by the initializer of libName
.
libName
- The value for libNamethis
builder for use in a chained invocationpublic final PrebuiltOcamlLibraryDescriptionArg.Builder setNativeLib(String nativeLib)
nativeLib
attribute.
If not set, this attribute will have a default value as returned by the initializer of nativeLib
.
nativeLib
- The value for nativeLibthis
builder for use in a chained invocationpublic final PrebuiltOcamlLibraryDescriptionArg.Builder setBytecodeLib(String bytecodeLib)
bytecodeLib
attribute.
If not set, this attribute will have a default value as returned by the initializer of bytecodeLib
.
bytecodeLib
- The value for bytecodeLibthis
builder for use in a chained invocationpublic final PrebuiltOcamlLibraryDescriptionArg.Builder addCLibs(String element)
cLibs
list.element
- A cLibs elementthis
builder for use in a chained invocationpublic final PrebuiltOcamlLibraryDescriptionArg.Builder addCLibs(String... elements)
cLibs
list.elements
- An array of cLibs elementsthis
builder for use in a chained invocationpublic final PrebuiltOcamlLibraryDescriptionArg.Builder setCLibs(Iterable<String> elements)
cLibs
list.elements
- An iterable of cLibs elementsthis
builder for use in a chained invocationpublic final PrebuiltOcamlLibraryDescriptionArg.Builder addAllCLibs(Iterable<String> elements)
cLibs
list.elements
- An iterable of cLibs elementsthis
builder for use in a chained invocationpublic final PrebuiltOcamlLibraryDescriptionArg.Builder addNativeCLibs(String element)
nativeCLibs
list.element
- A nativeCLibs elementthis
builder for use in a chained invocationpublic final PrebuiltOcamlLibraryDescriptionArg.Builder addNativeCLibs(String... elements)
nativeCLibs
list.elements
- An array of nativeCLibs elementsthis
builder for use in a chained invocationpublic final PrebuiltOcamlLibraryDescriptionArg.Builder setNativeCLibs(Iterable<String> elements)
nativeCLibs
list.elements
- An iterable of nativeCLibs elementsthis
builder for use in a chained invocationpublic final PrebuiltOcamlLibraryDescriptionArg.Builder addAllNativeCLibs(Iterable<String> elements)
nativeCLibs
list.elements
- An iterable of nativeCLibs elementsthis
builder for use in a chained invocationpublic final PrebuiltOcamlLibraryDescriptionArg.Builder addBytecodeCLibs(String element)
bytecodeCLibs
list.element
- A bytecodeCLibs elementthis
builder for use in a chained invocationpublic final PrebuiltOcamlLibraryDescriptionArg.Builder addBytecodeCLibs(String... elements)
bytecodeCLibs
list.elements
- An array of bytecodeCLibs elementsthis
builder for use in a chained invocationpublic final PrebuiltOcamlLibraryDescriptionArg.Builder setBytecodeCLibs(Iterable<String> elements)
bytecodeCLibs
list.elements
- An iterable of bytecodeCLibs elementsthis
builder for use in a chained invocationpublic final PrebuiltOcamlLibraryDescriptionArg.Builder addAllBytecodeCLibs(Iterable<String> elements)
bytecodeCLibs
list.elements
- An iterable of bytecodeCLibs elementsthis
builder for use in a chained invocationpublic final PrebuiltOcamlLibraryDescriptionArg.Builder setBytecodeOnly(boolean bytecodeOnly)
bytecodeOnly
attribute.
If not set, this attribute will have a default value as returned by the initializer of bytecodeOnly
.
bytecodeOnly
- The value for bytecodeOnlythis
builder for use in a chained invocationpublic final PrebuiltOcamlLibraryDescriptionArg.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 PrebuiltOcamlLibraryDescriptionArg.Builder addCompatibleWith(UnconfiguredBuildTarget element)
compatibleWith
list.element
- A compatibleWith elementthis
builder for use in a chained invocationpublic final PrebuiltOcamlLibraryDescriptionArg.Builder addCompatibleWith(UnconfiguredBuildTarget... elements)
compatibleWith
list.elements
- An array of compatibleWith elementsthis
builder for use in a chained invocationpublic final PrebuiltOcamlLibraryDescriptionArg.Builder setCompatibleWith(Iterable<? extends UnconfiguredBuildTarget> elements)
compatibleWith
list.elements
- An iterable of compatibleWith elementsthis
builder for use in a chained invocationpublic final PrebuiltOcamlLibraryDescriptionArg.Builder addAllCompatibleWith(Iterable<? extends UnconfiguredBuildTarget> elements)
compatibleWith
list.elements
- An iterable of compatibleWith elementsthis
builder for use in a chained invocationpublic final PrebuiltOcamlLibraryDescriptionArg.Builder setDefaultTargetPlatform(UnconfiguredBuildTarget defaultTargetPlatform)
defaultTargetPlatform
to defaultTargetPlatform.defaultTargetPlatform
- The value for defaultTargetPlatformthis
builder for chained invocationpublic final PrebuiltOcamlLibraryDescriptionArg.Builder setDefaultTargetPlatform(Optional<? extends UnconfiguredBuildTarget> defaultTargetPlatform)
defaultTargetPlatform
to defaultTargetPlatform.defaultTargetPlatform
- The value for defaultTargetPlatformthis
builder for use in a chained invocationpublic final PrebuiltOcamlLibraryDescriptionArg.Builder addLabels(String element)
labels
sortedSet.element
- A labels elementthis
builder for use in a chained invocationpublic final PrebuiltOcamlLibraryDescriptionArg.Builder addLabels(String... elements)
labels
sortedSet.elements
- An array of labels elementsthis
builder for use in a chained invocationpublic final PrebuiltOcamlLibraryDescriptionArg.Builder setLabels(Iterable<String> elements)
labels
sortedSet.elements
- An iterable of labels elementsthis
builder for use in a chained invocationpublic final PrebuiltOcamlLibraryDescriptionArg.Builder addAllLabels(Iterable<String> elements)
labels
sortedSet.elements
- An iterable of labels elementsthis
builder for use in a chained invocationpublic final PrebuiltOcamlLibraryDescriptionArg.Builder addLicenses(SourcePath element)
licenses
set.element
- A licenses elementthis
builder for use in a chained invocationpublic final PrebuiltOcamlLibraryDescriptionArg.Builder addLicenses(SourcePath... elements)
licenses
set.elements
- An array of licenses elementsthis
builder for use in a chained invocationpublic final PrebuiltOcamlLibraryDescriptionArg.Builder setLicenses(Iterable<? extends SourcePath> elements)
licenses
set.elements
- An iterable of licenses elementsthis
builder for use in a chained invocationpublic final PrebuiltOcamlLibraryDescriptionArg.Builder addAllLicenses(Iterable<? extends SourcePath> elements)
licenses
set.elements
- An iterable of licenses elementsthis
builder for use in a chained invocationpublic final PrebuiltOcamlLibraryDescriptionArg.Builder setName(String name)
name
attribute.name
- The value for namethis
builder for use in a chained invocationpublic final PrebuiltOcamlLibraryDescriptionArg.Builder addDeps(BuildTarget element)
deps
sortedSet.element
- A deps elementthis
builder for use in a chained invocationpublic final PrebuiltOcamlLibraryDescriptionArg.Builder addDeps(BuildTarget... elements)
deps
sortedSet.elements
- An array of deps elementsthis
builder for use in a chained invocationpublic final PrebuiltOcamlLibraryDescriptionArg.Builder setDeps(Iterable<? extends BuildTarget> elements)
deps
sortedSet.elements
- An iterable of deps elementsthis
builder for use in a chained invocationpublic final PrebuiltOcamlLibraryDescriptionArg.Builder addAllDeps(Iterable<? extends BuildTarget> elements)
deps
sortedSet.elements
- An iterable of deps elementsthis
builder for use in a chained invocationpublic PrebuiltOcamlLibraryDescriptionArg build()
PrebuiltOcamlLibraryDescriptionArg
.IllegalStateException
- if any required attributes are missing