@NotThreadSafe public static final class ImmutableFilePartitionBlock.Builder extends Object
ImmutableFilePartitionBlock
.
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 |
---|---|
ImmutableFilePartitionBlock |
build()
Builds a new
ImmutableFilePartitionBlock . |
ImmutableFilePartitionBlock.Builder |
diskFileName(String diskFileName)
Initializes the value for the
diskFileName attribute. |
ImmutableFilePartitionBlock.Builder |
from(FilePartitionBlock instance)
Fill a builder with attribute values from the provided
FilePartitionBlock instance. |
ImmutableFilePartitionBlock.Builder |
lengthBytes(long lengthBytes)
Initializes the value for the
lengthBytes attribute. |
ImmutableFilePartitionBlock.Builder |
number(long number)
Initializes the value for the
number attribute. |
ImmutableFilePartitionBlock.Builder |
offsetBytes(long offsetBytes)
Initializes the value for the
offsetBytes attribute. |
public final ImmutableFilePartitionBlock.Builder from(FilePartitionBlock instance)
FilePartitionBlock
instance.
Regular attribute values will be replaced with those from the given instance.
Absent optional values will not replace present values.instance
- The instance from which to copy valuesthis
builder for use in a chained invocationpublic final ImmutableFilePartitionBlock.Builder diskFileName(String diskFileName)
diskFileName
attribute.diskFileName
- The value for diskFileNamethis
builder for use in a chained invocationpublic final ImmutableFilePartitionBlock.Builder lengthBytes(long lengthBytes)
lengthBytes
attribute.lengthBytes
- The value for lengthBytesthis
builder for use in a chained invocationpublic final ImmutableFilePartitionBlock.Builder number(long number)
number
attribute.number
- The value for numberthis
builder for use in a chained invocationpublic final ImmutableFilePartitionBlock.Builder offsetBytes(long offsetBytes)
offsetBytes
attribute.offsetBytes
- The value for offsetBytesthis
builder for use in a chained invocationpublic ImmutableFilePartitionBlock build()
ImmutableFilePartitionBlock
.IllegalStateException
- if any required attributes are missingCopyright © 2023 iland Internet Solutions, Corp. All rights reserved.