T - the type of the attachment that can queued for uploading.public abstract class ERAttachmentUploadQueue<T extends ERAttachment & ERRemoteAttachment> extends ERXAsyncQueue<ERAttachmentQueueEntry<T>>
ERAttachmentUploadQueue is a queue to upload attachments.
Only ERRemoteAttachments can be upload using this queue.
ERRemoteAttachmentThread.State, Thread.UncaughtExceptionHandler| Modifier and Type | Field and Description |
|---|---|
protected ERAttachmentProcessor<T> |
_processor |
MAX_PRIORITY, MIN_PRIORITY, NORM_PRIORITY| Constructor and Description |
|---|
ERAttachmentUploadQueue(String name,
ERAttachmentProcessor<T> processor) |
| Modifier and Type | Method and Description |
|---|---|
void |
enqueue(T attachment)
Adds an attachment to the end of the queue.
|
protected abstract void |
performUpload(com.webobjects.eocontrol.EOEditingContext editingContext,
T attachment,
File uploadedFile)
Perform the upload of the attachment to the remote server.
|
void |
process(ERAttachmentQueueEntry<T> entry) |
enqueue, runactiveCount, checkAccess, clone, countStackFrames, currentThread, destroy, dumpStack, enumerate, getAllStackTraces, getContextClassLoader, getDefaultUncaughtExceptionHandler, getId, getName, getPriority, getStackTrace, getState, getThreadGroup, getUncaughtExceptionHandler, holdsLock, interrupt, interrupted, isAlive, isDaemon, isInterrupted, join, join, join, resume, setContextClassLoader, setDaemon, setDefaultUncaughtExceptionHandler, setName, setPriority, setUncaughtExceptionHandler, sleep, sleep, start, stop, stop, suspend, toString, yieldprotected final ERAttachmentProcessor<T extends ERAttachment & ERRemoteAttachment> _processor
public ERAttachmentUploadQueue(String name, ERAttachmentProcessor<T> processor)
public void enqueue(T attachment)
attachment - the attachment to uploadpublic void process(ERAttachmentQueueEntry<T> entry)
process in class ERXAsyncQueue<ERAttachmentQueueEntry<T extends ERAttachment & ERRemoteAttachment>>protected abstract void performUpload(com.webobjects.eocontrol.EOEditingContext editingContext,
T attachment,
File uploadedFile)
throws Exception
attachment - the attachment to uploaduploadedFile - the file to uploadExceptionCopyright © 2002 – 2020 Project Wonder.