public static final class CategoryTypes.UpdateSpec.Builder
extends java.lang.Object
CategoryTypes.UpdateSpec
.Constructor and Description |
---|
Builder()
Constructor with parameters for the required properties of
CategoryTypes.UpdateSpec . |
Modifier and Type | Method and Description |
---|---|
CategoryTypes.UpdateSpec |
build() |
CategoryTypes.UpdateSpec.Builder |
setAssociableTypes(java.util.Set<java.lang.String> associableTypes)
Object types to which this category's tags can be attached.
|
CategoryTypes.UpdateSpec.Builder |
setCardinality(CategoryModel.Cardinality cardinality)
The associated cardinality (SINGLE, MULTIPLE) of the category.
|
CategoryTypes.UpdateSpec.Builder |
setDescription(java.lang.String description)
The description of the category.
|
CategoryTypes.UpdateSpec.Builder |
setName(java.lang.String name)
The display name of the category.
|
public Builder()
CategoryTypes.UpdateSpec
.public CategoryTypes.UpdateSpec.Builder setName(java.lang.String name)
null
the name will not be modified.name
- New value for the property.public CategoryTypes.UpdateSpec.Builder setDescription(java.lang.String description)
null
the description will not be modified.description
- New value for the property.public CategoryTypes.UpdateSpec.Builder setCardinality(CategoryModel.Cardinality cardinality)
null
the cardinality will not be modified.cardinality
- New value for the property.public CategoryTypes.UpdateSpec.Builder setAssociableTypes(java.util.Set<java.lang.String> associableTypes)
The Set
of associable types cannot be updated incrementally. For example,
if CategoryTypes.UpdateSpec.getAssociableTypes()
originally contains {A,B,C} and you want to add D, then you need to pass
{A,B,C,D} in your update specification. You also cannot remove any item from
this Set
. For example, if you have {A,B,C}, then you cannot
remove say {A} from it. Similarly, if you start with an empty Set
, then that implies that you can tag any object and hence you
cannot later pass say {A}, because that would be restricting the type of objects
you want to tag. Thus, associable types can only grow and not shrink.
null
the associable types will not be modified.associableTypes
- New value for the property.public CategoryTypes.UpdateSpec build()