Interface AssociateRole

All Superinterfaces:
BaseResource, Identifiable<AssociateRole>

public interface AssociateRole extends BaseResource, Identifiable<AssociateRole>
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()
 
  • Method Details

    • getId

      @NotNull @NotNull String getId()

      Unique identifier of the AssociateRole.

      Specified by:
      getId in interface BaseResource
      Specified by:
      getId in interface Identifiable<AssociateRole>
      Returns:
      id
    • getVersion

      @NotNull @NotNull Long getVersion()

      Current version of the AssociateRole.

      Specified by:
      getVersion in interface BaseResource
      Returns:
      version
    • getCreatedAt

      @NotNull @NotNull ZonedDateTime getCreatedAt()

      Date and time (UTC) the AssociateRole was initially created.

      Specified by:
      getCreatedAt in interface BaseResource
      Returns:
      createdAt
    • getLastModifiedAt

      @NotNull @NotNull ZonedDateTime getLastModifiedAt()

      Date and time (UTC) the AssociateRole was last updated.

      Specified by:
      getLastModifiedAt in interface BaseResource
      Returns:
      lastModifiedAt
    • getLastModifiedBy

      @Valid @Valid LastModifiedBy getLastModifiedBy()

      IDs and references that last modified the AssociateRole.

      Returns:
      lastModifiedBy
    • getCreatedBy

      @Valid @Valid CreatedBy getCreatedBy()

      IDs and references that created the AssociateRole.

      Returns:
      createdBy
    • getKey

      @NotNull @NotNull String getKey()

      User-defined unique and immutable identifier of the AssociateRole.

      Returns:
      key
    • getBuyerAssignable

      @NotNull @NotNull Boolean 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

      String getName()

      Name of the AssociateRole.

      Returns:
      name
    • getPermissions

      @NotNull @NotNull List<Permission> getPermissions()

      List of Permissions for the AssociateRole.

      Returns:
      permissions
    • getCustom

      @Valid @Valid CustomFields getCustom()

      Custom Fields for the AssociateRole.

      Returns:
      custom
    • setId

      void setId(String id)

      Unique identifier of the AssociateRole.

      Specified by:
      setId in interface BaseResource
      Parameters:
      id - value to be set
    • setVersion

      void setVersion(Long version)

      Current version of the AssociateRole.

      Specified by:
      setVersion in interface BaseResource
      Parameters:
      version - value to be set
    • setCreatedAt

      void setCreatedAt(ZonedDateTime createdAt)

      Date and time (UTC) the AssociateRole was initially created.

      Specified by:
      setCreatedAt in interface BaseResource
      Parameters:
      createdAt - value to be set
    • setLastModifiedAt

      void setLastModifiedAt(ZonedDateTime lastModifiedAt)

      Date and time (UTC) the AssociateRole was last updated.

      Specified by:
      setLastModifiedAt in interface BaseResource
      Parameters:
      lastModifiedAt - value to be set
    • setLastModifiedBy

      void setLastModifiedBy(LastModifiedBy lastModifiedBy)

      IDs and references that last modified the AssociateRole.

      Parameters:
      lastModifiedBy - value to be set
    • setCreatedBy

      void setCreatedBy(CreatedBy createdBy)

      IDs and references that created the AssociateRole.

      Parameters:
      createdBy - value to be set
    • setKey

      void setKey(String key)

      User-defined unique and immutable identifier of the AssociateRole.

      Parameters:
      key - value to be set
    • setBuyerAssignable

      void setBuyerAssignable(Boolean 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
    • setName

      void setName(String name)

      Name of the AssociateRole.

      Parameters:
      name - value to be set
    • setPermissions

      void setPermissions(Permission... permissions)

      List of Permissions for the AssociateRole.

      Parameters:
      permissions - values to be set
    • setPermissions

      void setPermissions(List<Permission> permissions)

      List of Permissions for the AssociateRole.

      Parameters:
      permissions - values to be set
    • setCustom

      void setCustom(CustomFields custom)

      Custom Fields for the AssociateRole.

      Parameters:
      custom - value to be set
    • of

      static AssociateRole of()
      factory method
      Returns:
      instance of AssociateRole
    • of

      static AssociateRole of(AssociateRole template)
      factory method to create a shallow copy AssociateRole
      Parameters:
      template - instance to be copied
      Returns:
      copy instance
    • deepCopy

      @Nullable static AssociateRole deepCopy(@Nullable AssociateRole template)
      factory method to create a deep copy of AssociateRole
      Parameters:
      template - instance to be copied
      Returns:
      copy instance
    • builder

      static AssociateRoleBuilder builder()
      builder factory method for AssociateRole
      Returns:
      builder
    • builder

      static AssociateRoleBuilder builder(AssociateRole template)
      create builder for AssociateRole instance
      Parameters:
      template - instance with prefilled values for the builder
      Returns:
      builder
    • withAssociateRole

      default <T> T withAssociateRole(Function<AssociateRole,T> helper)
      accessor map function
      Type Parameters:
      T - mapped type
      Parameters:
      helper - function to map the object
      Returns:
      mapped value
    • typeReference

      static com.fasterxml.jackson.core.type.TypeReference<AssociateRole> typeReference()
      gives a TypeReference for usage with Jackson DataBind
      Returns:
      TypeReference