Interface PartitionAttributesBuilder
-
- All Known Implementing Classes:
DefaultPartitionAttributesBuilder
public interface PartitionAttributesBuilderA builder forPartitionAttributesobjects. Duplicates are not necessarily detected/enforced via theadd(PartitionAttributes.Key, Object)method.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description <T> PartitionAttributesBuilderadd(PartitionAttributes.Key<T> key, T value)Add a key/value pair to this builder.PartitionAttributesbuild()Build aPartitionAttributescorresponding to the previousadd(PartitionAttributes.Key, Object)calls.
-
-
-
Method Detail
-
add
<T> PartitionAttributesBuilder add(PartitionAttributes.Key<T> key, T value)
Add a key/value pair to this builder.Duplicate keys are not necessarily detected, and this will instead just add.
- Type Parameters:
T- The value type.- Parameters:
key- The key.value- The value.- Returns:
this.- Throws:
DuplicateAttributeException- A best effort will be made to detect adding duplicate keys, and if a duplicate key is detected this exception will be thrown.
-
build
PartitionAttributes build()
Build aPartitionAttributescorresponding to the previousadd(PartitionAttributes.Key, Object)calls.- Returns:
- a
PartitionAttributescorresponding to the previousadd(PartitionAttributes.Key, Object)calls. - Throws:
DuplicateAttributeException- If a duplicate key is detected this exception will be thrown.
-
-