Interface TypeDraft
TypeDraft
Example to create an instance using the builder pattern
Example to create an instance using the builder pattern
TypeDraft typeDraft = TypeDraft.builder()
.key("{key}")
.name(nameBuilder -> nameBuilder)
.plusResourceTypeIds(resourceTypeIdsBuilder -> resourceTypeIdsBuilder)
.build()
-
Method Summary
Modifier and TypeMethodDescriptionstatic TypeDraftBuilder
builder()
builder factory method for TypeDraftstatic TypeDraftBuilder
create builder for TypeDraft instancestatic TypeDraft
factory method to create a deep copy of TypeDraft@Valid LocalizedString
Description of the Type.@Valid List<FieldDefinition>
Defines Custom Fields.@NotNull String
getKey()
User-defined unique identifier for the Type.@NotNull @Valid LocalizedString
getName()
Name of the Type.@NotNull List<ResourceTypeId>
Resources and/or data types for which the Type is defined.static TypeDraft
of()
factory methodstatic TypeDraft
factory method to create a shallow copy TypeDraftvoid
setDescription
(LocalizedString description) Description of the Type.void
setFieldDefinitions
(FieldDefinition... fieldDefinitions) Defines Custom Fields.void
setFieldDefinitions
(List<FieldDefinition> fieldDefinitions) Defines Custom Fields.void
User-defined unique identifier for the Type.void
setName
(LocalizedString name) Name of the Type.void
setResourceTypeIds
(ResourceTypeId... resourceTypeIds) Resources and/or data types for which the Type is defined.void
setResourceTypeIds
(List<ResourceTypeId> resourceTypeIds) Resources and/or data types for which the Type is defined.static com.fasterxml.jackson.core.type.TypeReference<TypeDraft>
gives a TypeReference for usage with Jackson DataBinddefault <T> T
withTypeDraft
(Function<TypeDraft, T> helper) accessor map function
-
Method Details
-
getKey
User-defined unique identifier for the Type.
-
getName
Name of the Type.
- Returns:
- name
-
getDescription
Description of the Type.
- Returns:
- description
-
getResourceTypeIds
Resources and/or data types for which the Type is defined.
- Returns:
- resourceTypeIds
-
getFieldDefinitions
Defines Custom Fields.
- Returns:
- fieldDefinitions
-
setKey
User-defined unique identifier for the Type.
- Parameters:
key
- value to be set
-
setName
Name of the Type.
- Parameters:
name
- value to be set
-
setDescription
Description of the Type.
- Parameters:
description
- value to be set
-
setResourceTypeIds
Resources and/or data types for which the Type is defined.
- Parameters:
resourceTypeIds
- values to be set
-
setResourceTypeIds
Resources and/or data types for which the Type is defined.
- Parameters:
resourceTypeIds
- values to be set
-
setFieldDefinitions
Defines Custom Fields.
- Parameters:
fieldDefinitions
- values to be set
-
setFieldDefinitions
Defines Custom Fields.
- Parameters:
fieldDefinitions
- values to be set
-
of
factory method- Returns:
- instance of TypeDraft
-
of
factory method to create a shallow copy TypeDraft- Parameters:
template
- instance to be copied- Returns:
- copy instance
-
deepCopy
factory method to create a deep copy of TypeDraft- Parameters:
template
- instance to be copied- Returns:
- copy instance
-
builder
builder factory method for TypeDraft- Returns:
- builder
-
builder
create builder for TypeDraft instance- Parameters:
template
- instance with prefilled values for the builder- Returns:
- builder
-
withTypeDraft
accessor map function- Type Parameters:
T
- mapped type- Parameters:
helper
- function to map the object- Returns:
- mapped value
-
typeReference
gives a TypeReference for usage with Jackson DataBind- Returns:
- TypeReference
-