Class DefaultFulfillRequestedUploadRequest
java.lang.Object
de.xima.fc.common.form_record.chat.DefaultFulfillRequestedUploadRequest
- All Implemented Interfaces:
IFulfillRequestedUploadRequest, Serializable
public final class DefaultFulfillRequestedUploadRequest
extends Object
implements IFulfillRequestedUploadRequest
Simple POJO implementation of
IFulfillRequestedUploadRequest with a builder.- Since:
- 8.2.0
- See Also:
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classDefaultFulfillRequestedUploadRequest.BaseBuilder<Request, Self extends DefaultFulfillRequestedUploadRequest.BaseBuilder<Request,Self>> Builder for the data needed to fulfill a pending upload request.static final classBuilder for anIFulfillRequestedUploadRequest. -
Method Summary
Modifier and TypeMethodDescriptionApplies only when theupload requestdoes not reference anupload element.When given, enforces that theIFulfillRequestedUploadRequest.uploadRequestUuid()matches the given chat UUID, i.e. that the chat contains the upload request.booleanWhen true, enforces that thefileshave an explicit content type.booleanWhen given, enforces that theIFulfillRequestedUploadRequest.uploadRequestUuid()matches the given message UUID, i.e. that the message contains the upload request.files()The files to use for fulfilling the upload request.fulfillUploadRequestBuilder(FormRecordMessageUploadRequest uploadRequest) Creates a new builder for the data need to fulfill a pending upload request.fulfillUploadRequestBuilder(UUID uploadRequestUuid) Creates a new builder for the data need to fulfill a pending upload request.booleanWhen true, initializes all fields in the response entities (i.e. ensures referenced child entities are loaded from the database).locale()The locale to use for the response.booleanWhether to make the newly created attachments accessible to the end user.The user who provided the upload to fulfill the request.The UUID of apendingupload request.
-
Method Details
-
attachmentSource
Description copied from interface:IFulfillRequestedUploadRequestApplies only when theupload requestdoes not reference anupload element. Thesourceof the attachments to create. Defaults toUNKNOWN. Note that when the upload request references an upload element, the source is always set toFORM_UPLOAD.- Specified by:
attachmentSourcein interfaceIFulfillRequestedUploadRequest- Returns:
- The source of the attachments to create.
-
enforceChatUuid
Description copied from interface:IFulfillRequestedUploadRequestWhen given, enforces that theIFulfillRequestedUploadRequest.uploadRequestUuid()matches the given chat UUID, i.e. that the chat contains the upload request.- Specified by:
enforceChatUuidin interfaceIFulfillRequestedUploadRequest- Returns:
- The UUID of the message to enforce.
-
enforceExplicitContentType
public boolean enforceExplicitContentType()Description copied from interface:IFulfillRequestedUploadRequestWhen true, enforces that thefileshave an explicit content type. Defaults to false.- Specified by:
enforceExplicitContentTypein interfaceIFulfillRequestedUploadRequest- Returns:
- Whether to enforce that the files have an explicit content type.
-
enforceMatchingUser
public boolean enforceMatchingUser()Description copied from interface:IFulfillRequestedUploadRequestWhen true, enforces that theuserfulfilling the request matches one ofmembersof the chat containing the message with the upload request. Defaults to false.- Specified by:
enforceMatchingUserin interfaceIFulfillRequestedUploadRequest- Returns:
- When true, enforces that the user fulfilling the request matches one of the chat members.
-
enforceMessageUuid
Description copied from interface:IFulfillRequestedUploadRequestWhen given, enforces that theIFulfillRequestedUploadRequest.uploadRequestUuid()matches the given message UUID, i.e. that the message contains the upload request.- Specified by:
enforceMessageUuidin interfaceIFulfillRequestedUploadRequest- Returns:
- The UUID of the message to enforce.
-
files
Description copied from interface:IFulfillRequestedUploadRequestThe files to use for fulfilling the upload request. When the files do not have an explicit content type, attempts to guess the type, unless an explicit content type isenforced.- Specified by:
filesin interfaceIFulfillRequestedUploadRequest- Returns:
- The files to use for fulfilling the upload request.
-
initializeResponse
public boolean initializeResponse()Description copied from interface:IFulfillRequestedUploadRequestWhen true, initializes all fields in the response entities (i.e. ensures referenced child entities are loaded from the database). Defaults to false.- Specified by:
initializeResponsein interfaceIFulfillRequestedUploadRequest- Returns:
- When true, initializes all fields in the response entities.
-
makeFilesAccessibleToEndUser
public boolean makeFilesAccessibleToEndUser()Description copied from interface:IFulfillRequestedUploadRequestWhether to make the newly created attachments accessible to the end user. Defaults to false.- Specified by:
makeFilesAccessibleToEndUserin interfaceIFulfillRequestedUploadRequest- Returns:
- Whether to make the newly created attachments accessible to the end user.
-
oathKeeper
Description copied from interface:IFulfillRequestedUploadRequestThe user who provided the upload to fulfill the request. Uses an (unspecified) default when not given.- Specified by:
oathKeeperin interfaceIFulfillRequestedUploadRequest- Returns:
- The user who provided the upload to fulfill the request.
-
uploadRequestUuid
Description copied from interface:IFulfillRequestedUploadRequestThe UUID of apendingupload request. Since the UUID must be globally unique within the system, this is sufficient to identify the request.- Specified by:
uploadRequestUuidin interfaceIFulfillRequestedUploadRequest- Returns:
- The UUID of the upload request.
-
locale
Description copied from interface:IFulfillRequestedUploadRequestThe locale to use for the response.- Specified by:
localein interfaceIFulfillRequestedUploadRequest- Returns:
- The locale to use for the response.
-
fulfillUploadRequestBuilder
public static DefaultFulfillRequestedUploadRequest.Builder fulfillUploadRequestBuilder(UUID uploadRequestUuid) Creates a new builder for the data need to fulfill a pending upload request.- Parameters:
uploadRequestUuid- The UUID of the pending upload request.- Returns:
- A new builder for the data need to fulfill a pending upload request.
-
fulfillUploadRequestBuilder
public static DefaultFulfillRequestedUploadRequest.Builder fulfillUploadRequestBuilder(FormRecordMessageUploadRequest uploadRequest) Creates a new builder for the data need to fulfill a pending upload request.- Parameters:
uploadRequest- The pending upload request.- Returns:
- A new builder for the data need to fulfill a pending upload request.
-