Class AssociateRoleBuilder
- All Implemented Interfaces:
Builder<AssociateRole>
Example to create an instance using the builder pattern
AssociateRole associateRole = AssociateRole.builder()
.id("{id}")
.version(0.3)
.createdAt(ZonedDateTime.parse("2022-01-01T12:00:00.301Z"))
.lastModifiedAt(ZonedDateTime.parse("2022-01-01T12:00:00.301Z"))
.key("{key}")
.buyerAssignable(true)
.plusPermissions(permissionsBuilder -> permissionsBuilder)
.build()
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionbuild()
builds AssociateRole with checking for non-null required valuesbuilds AssociateRole without checking for non-null required valuesbuyerAssignable
(Boolean buyerAssignable) Whether the AssociateRole can be assigned to an Associate by a buyer.createdAt
(ZonedDateTime createdAt) Date and time (UTC) the AssociateRole was initially created.IDs and references that created the AssociateRole.createdBy
(Function<CreatedByBuilder, CreatedByBuilder> builder) IDs and references that created the AssociateRole.custom
(CustomFields custom) Custom Fields for the AssociateRole.custom
(Function<CustomFieldsBuilder, CustomFieldsBuilder> builder) Custom Fields for the AssociateRole.Whether the AssociateRole can be assigned to an Associate by a buyer.Date and time (UTC) the AssociateRole was initially created.IDs and references that created the AssociateRole.Custom Fields for the AssociateRole.getId()
Unique identifier of the AssociateRole.getKey()
User-defined unique and immutable identifier of the AssociateRole.Date and time (UTC) the AssociateRole was last updated.IDs and references that last modified the AssociateRole.getName()
Name of the AssociateRole.List of Permissions for the AssociateRole.Current version of the AssociateRole.Unique identifier of the AssociateRole.User-defined unique and immutable identifier of the AssociateRole.lastModifiedAt
(ZonedDateTime lastModifiedAt) Date and time (UTC) the AssociateRole was last updated.lastModifiedBy
(LastModifiedBy lastModifiedBy) IDs and references that last modified the AssociateRole.IDs and references that last modified the AssociateRole.Name of the AssociateRole.static AssociateRoleBuilder
of()
factory method for an instance of AssociateRoleBuilderstatic AssociateRoleBuilder
of
(AssociateRole template) create builder for AssociateRole instancepermissions
(Permission... permissions) List of Permissions for the AssociateRole.permissions
(List<Permission> permissions) List of Permissions for the AssociateRole.plusPermissions
(Permission... permissions) List of Permissions for the AssociateRole.Current version of the AssociateRole.withCreatedBy
(Function<CreatedByBuilder, CreatedBy> builder) IDs and references that created the AssociateRole.withCustom
(Function<CustomFieldsBuilder, CustomFields> builder) Custom Fields for the AssociateRole.IDs and references that last modified the AssociateRole.
-
Constructor Details
-
AssociateRoleBuilder
public AssociateRoleBuilder()
-
-
Method Details
-
id
Unique identifier of the AssociateRole.
- Parameters:
id
- value to be set- Returns:
- Builder
-
version
Current version of the AssociateRole.
- Parameters:
version
- value to be set- Returns:
- Builder
-
createdAt
Date and time (UTC) the AssociateRole was initially created.
- Parameters:
createdAt
- value to be set- Returns:
- Builder
-
lastModifiedAt
Date and time (UTC) the AssociateRole was last updated.
- Parameters:
lastModifiedAt
- value to be set- Returns:
- Builder
-
lastModifiedBy
public AssociateRoleBuilder lastModifiedBy(Function<LastModifiedByBuilder, LastModifiedByBuilder> builder) IDs and references that last modified the AssociateRole.
- Parameters:
builder
- function to build the lastModifiedBy value- Returns:
- Builder
-
withLastModifiedBy
public AssociateRoleBuilder withLastModifiedBy(Function<LastModifiedByBuilder, LastModifiedBy> builder) IDs and references that last modified the AssociateRole.
- Parameters:
builder
- function to build the lastModifiedBy value- Returns:
- Builder
-
lastModifiedBy
IDs and references that last modified the AssociateRole.
- Parameters:
lastModifiedBy
- value to be set- Returns:
- Builder
-
createdBy
IDs and references that created the AssociateRole.
- Parameters:
builder
- function to build the createdBy value- Returns:
- Builder
-
withCreatedBy
IDs and references that created the AssociateRole.
- Parameters:
builder
- function to build the createdBy value- Returns:
- Builder
-
createdBy
IDs and references that created the AssociateRole.
- Parameters:
createdBy
- value to be set- Returns:
- Builder
-
key
User-defined unique and immutable identifier of the AssociateRole.
- Parameters:
key
- value to be set- Returns:
- Builder
-
buyerAssignable
Whether the AssociateRole can be assigned to an Associate by a buyer. If false, the AssociateRole can only be assigned using the general endpoint.
- Parameters:
buyerAssignable
- value to be set- Returns:
- Builder
-
name
Name of the AssociateRole.
- Parameters:
name
- value to be set- Returns:
- Builder
-
permissions
List of Permissions for the AssociateRole.
- Parameters:
permissions
- value to be set- Returns:
- Builder
-
permissions
List of Permissions for the AssociateRole.
- Parameters:
permissions
- value to be set- Returns:
- Builder
-
plusPermissions
List of Permissions for the AssociateRole.
- Parameters:
permissions
- value to be set- Returns:
- Builder
-
custom
Custom Fields for the AssociateRole.
- Parameters:
builder
- function to build the custom value- Returns:
- Builder
-
withCustom
Custom Fields for the AssociateRole.
- Parameters:
builder
- function to build the custom value- Returns:
- Builder
-
custom
Custom Fields for the AssociateRole.
- Parameters:
custom
- value to be set- Returns:
- Builder
-
getId
Unique identifier of the AssociateRole.
- Returns:
- id
-
getVersion
Current version of the AssociateRole.
- Returns:
- version
-
getCreatedAt
Date and time (UTC) the AssociateRole was initially created.
- Returns:
- createdAt
-
getLastModifiedAt
Date and time (UTC) the AssociateRole was last updated.
- Returns:
- lastModifiedAt
-
getLastModifiedBy
IDs and references that last modified the AssociateRole.
- Returns:
- lastModifiedBy
-
getCreatedBy
IDs and references that created the AssociateRole.
- Returns:
- createdBy
-
getKey
User-defined unique and immutable identifier of the AssociateRole.
- Returns:
- key
-
getBuyerAssignable
Whether the AssociateRole can be assigned to an Associate by a buyer. If false, the AssociateRole can only be assigned using the general endpoint.
- Returns:
- buyerAssignable
-
getName
Name of the AssociateRole.
- Returns:
- name
-
getPermissions
List of Permissions for the AssociateRole.
- Returns:
- permissions
-
getCustom
Custom Fields for the AssociateRole.
- Returns:
- custom
-
build
builds AssociateRole with checking for non-null required values- Specified by:
build
in interfaceBuilder<AssociateRole>
- Returns:
- AssociateRole
-
buildUnchecked
builds AssociateRole without checking for non-null required values- Returns:
- AssociateRole
-
of
factory method for an instance of AssociateRoleBuilder- Returns:
- builder
-
of
create builder for AssociateRole instance- Parameters:
template
- instance with prefilled values for the builder- Returns:
- builder
-