com.vaadin.flow.component.upload.
Class GeneratedVaadinUpload<R extends GeneratedVaadinUpload<R>>
- java.lang.Object
-
- com.vaadin.flow.component.Component
-
- com.vaadin.flow.component.upload.GeneratedVaadinUpload<R>
-
All Implemented Interfaces:
AttachNotifier
,DetachNotifier
,HasElement
,HasStyle
,Serializable
Direct Known Subclasses:
@Tag("vaadin-upload") @NpmPackage(value="@vaadin/polymer-legacy-adapter",version="23.1.15") @NpmPackage(value="@vaadin/upload",version="23.1.15") @NpmPackage(value="@vaadin/vaadin-upload",version="23.1.15") @JsModule("@vaadin/polymer-legacy-adapter/style-modules.js") @JsModule("@vaadin/upload/src/vaadin-upload.js") public abstract class GeneratedVaadinUpload<R extends GeneratedVaadinUpload<R>> extends Component implements HasStyle
Description copied from corresponding location in WebComponent:
<vaadin-upload>
is a Web Component for uploading multiple files with drag and drop support.Example:
<vaadin-upload></vaadin-upload>
Styling
The following shadow DOM parts are available for styling:
Part name Description primary-buttons
Upload container upload-button
Upload button drop-label
Label for drop indicator drop-label-icon
Icon for drop indicator file-list
File list container The following state attributes are available for styling:
Attribute Description Part name nodrop
Set when drag and drop is disabled (e. g., on touch devices) :host
dragover
A file is being dragged over the element :host
dragover-valid
A dragged file is valid with maxFiles
andaccept
criteria:host
See ThemableMixin ? how to apply styles for shadow parts
See Also:
-
-
Nested Class Summary
-
Constructor Summary
Constructors Constructor Description GeneratedVaadinUpload()
-
Method Summary
All Methods Modifier and Type Method Description protected Registration
addFileRejectListener(ComponentEventListener<GeneratedVaadinUpload.FileRejectEvent<R>> listener)
Adds a listener for
file-reject
events fired by the webcomponent.protected Registration
addFilesChangeListener(ComponentEventListener<GeneratedVaadinUpload.FilesChangeEvent<R>> listener)
Adds a listener for
files-changed
events fired by the webcomponent.protected Registration
addMaxFilesReachedChangeListener(ComponentEventListener<GeneratedVaadinUpload.MaxFilesReachedChangeEvent<R>> listener)
Adds a listener for
max-files-reached-changed
events fired by the webcomponent.protected void
addToAddButton(Component... components)
Adds the given components as children of this component at the slot 'add-button'.
protected void
addToDropLabel(Component... components)
Adds the given components as children of this component at the slot 'drop-label'.
protected void
addToDropLabelIcon(Component... components)
Adds the given components as children of this component at the slot 'drop-label-icon'.
protected void
addToFileList(Component... components)
Adds the given components as children of this component at the slot 'file-list'.
protected Registration
addUploadAbortListener(ComponentEventListener<GeneratedVaadinUpload.UploadAbortEvent<R>> listener)
Adds a listener for
upload-abort
events fired by the webcomponent.protected Registration
addUploadBeforeListener(ComponentEventListener<GeneratedVaadinUpload.UploadBeforeEvent<R>> listener)
Adds a listener for
upload-before
events fired by the webcomponent.protected Registration
addUploadErrorListener(ComponentEventListener<GeneratedVaadinUpload.UploadErrorEvent<R>> listener)
Adds a listener for
upload-error
events fired by the webcomponent.protected Registration
addUploadProgressListener(ComponentEventListener<GeneratedVaadinUpload.UploadProgressEvent<R>> listener)
Adds a listener for
upload-progress
events fired by the webcomponent.protected Registration
addUploadRequestListener(ComponentEventListener<GeneratedVaadinUpload.UploadRequestEvent<R>> listener)
Adds a listener for
upload-request
events fired by the webcomponent.protected Registration
addUploadResponseListener(ComponentEventListener<GeneratedVaadinUpload.UploadResponseEvent<R>> listener)
Adds a listener for
upload-response
events fired by the webcomponent.protected Registration
addUploadRetryListener(ComponentEventListener<GeneratedVaadinUpload.UploadRetryEvent<R>> listener)
Adds a listener for
upload-retry
events fired by the webcomponent.protected Registration
addUploadStartListener(ComponentEventListener<GeneratedVaadinUpload.UploadStartEvent<R>> listener)
Adds a listener for
upload-start
events fired by the webcomponent.protected Registration
addUploadSuccessListener(ComponentEventListener<GeneratedVaadinUpload.UploadSuccessEvent<R>> listener)
Adds a listener for
upload-success
events fired by the webcomponent.protected String
getAcceptString()
Description copied from corresponding location in WebComponent:
protected String
getCaptureString()
Description copied from corresponding location in WebComponent:
protected elemental.json.JsonArray
getFilesJsonArray()
Description copied from corresponding location in WebComponent:
protected String
getFormDataNameString()
Description copied from corresponding location in WebComponent:
protected elemental.json.JsonObject
getHeadersJsonObject()
Description copied from corresponding location in WebComponent:
protected elemental.json.JsonObject
getI18nJsonObject()
Description copied from corresponding location in WebComponent:
protected double
getMaxFilesDouble()
Description copied from corresponding location in WebComponent:
protected double
getMaxFileSizeDouble()
Description copied from corresponding location in WebComponent:
protected String
getMethodString()
Description copied from corresponding location in WebComponent:
protected String
getTargetString()
Description copied from corresponding location in WebComponent:
protected double
getTimeoutDouble()
Description copied from corresponding location in WebComponent:
protected boolean
isMaxFilesReachedBoolean()
Description copied from corresponding location in WebComponent:
protected boolean
isNoAutoBoolean()
Description copied from corresponding location in WebComponent:
protected boolean
isNodropBoolean()
Description copied from corresponding location in WebComponent:
protected boolean
isWithCredentialsBoolean()
Description copied from corresponding location in WebComponent:
protected void
remove(Component... components)
Removes the given child components from this component.
protected void
removeAll()
Removes all contents from this component, this includes child components, text content as well as child elements that have been added directly to this component using the
Element
API.protected void
setAccept(String accept)
Description copied from corresponding location in WebComponent:
protected void
setCapture(String capture)
Description copied from corresponding location in WebComponent:
protected void
setFiles(elemental.json.JsonArray files)
Description copied from corresponding location in WebComponent:
protected void
setFormDataName(String formDataName)
Description copied from corresponding location in WebComponent:
protected void
setHeaders(elemental.json.JsonObject headers)
Description copied from corresponding location in WebComponent:
protected void
setI18n(elemental.json.JsonObject i18n)
Description copied from corresponding location in WebComponent:
protected void
setMaxFiles(double maxFiles)
Description copied from corresponding location in WebComponent:
protected void
setMaxFileSize(double maxFileSize)
Description copied from corresponding location in WebComponent:
protected void
setMethod(String method)
Description copied from corresponding location in WebComponent:
protected void
setNoAuto(boolean noAuto)
Description copied from corresponding location in WebComponent:
protected void
setNodrop(boolean nodrop)
Description copied from corresponding location in WebComponent:
protected void
setTarget(String target)
Description copied from corresponding location in WebComponent:
protected void
setTimeout(double timeout)
Description copied from corresponding location in WebComponent:
protected void
setWithCredentials(boolean withCredentials)
Description copied from corresponding location in WebComponent:
protected void
uploadFiles(elemental.json.JsonObject files)
Description copied from corresponding location in WebComponent:
-
Methods inherited from class com.vaadin.flow.component.Component
addListener, fireEvent, from, get, getChildren, getElement, getEventBus, getId, getLocale, getParent, getTranslation, getTranslation, getTranslation, getUI, hasListener, isAttached, isTemplateMapped, isVisible, onAttach, onDetach, onEnabledStateChanged, scrollIntoView, set, setElement, setId, setVisible
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface com.vaadin.flow.component.AttachNotifier
addAttachListener
-
Methods inherited from interface com.vaadin.flow.component.DetachNotifier
addDetachListener
-
Methods inherited from interface com.vaadin.flow.component.HasElement
getElement
-
Methods inherited from interface com.vaadin.flow.component.HasStyle
addClassName, addClassNames, getClassName, getClassNames, getStyle, hasClassName, removeClassName, removeClassNames, setClassName, setClassName
-
-
-
-
Method Detail
-
isNodropBoolean
protected boolean isNodropBoolean()
Description copied from corresponding location in WebComponent:
Define whether the element supports dropping files on it for uploading. By default it's enabled in desktop and disabled in touch devices because mobile devices do not support drag events in general. Setting it false means that drop is enabled even in touch-devices, and true disables drop in all devices.
This property is not synchronized automatically from the client side, so the returned value may not be the same as in client side.
Returns:
the
nodrop
property from the webcomponent
-
setNodrop
protected void setNodrop(boolean nodrop)
Description copied from corresponding location in WebComponent:
Define whether the element supports dropping files on it for uploading. By default it's enabled in desktop and disabled in touch devices because mobile devices do not support drag events in general. Setting it false means that drop is enabled even in touch-devices, and true disables drop in all devices.
Parameters:
nodrop
- the boolean value to set
-
getTargetString
protected String getTargetString()
Description copied from corresponding location in WebComponent:
The server URL. The default value is an empty string, which means that window.location will be used.
This property is not synchronized automatically from the client side, so the returned value may not be the same as in client side.
Returns:
the
target
property from the webcomponent
-
setTarget
protected void setTarget(String target)
Description copied from corresponding location in WebComponent:
The server URL. The default value is an empty string, which means that window.location will be used.
Parameters:
target
- the String value to set
-
getMethodString
protected String getMethodString()
Description copied from corresponding location in WebComponent:
HTTP Method used to send the files. Only POST and PUT are allowed.
This property is not synchronized automatically from the client side, so the returned value may not be the same as in client side.
Returns:
the
method
property from the webcomponent
-
setMethod
protected void setMethod(String method)
Description copied from corresponding location in WebComponent:
HTTP Method used to send the files. Only POST and PUT are allowed.
Parameters:
method
- the String value to set
-
getHeadersJsonObject
protected elemental.json.JsonObject getHeadersJsonObject()
Description copied from corresponding location in WebComponent:
Key-Value map to send to the server. If you set this property as an attribute, use a valid JSON string, for example:
<vaadin-upload headers=' "X-Foo": "Bar"
'>}This property is not synchronized automatically from the client side, so the returned value may not be the same as in client side.
Returns:
the
headers
property from the webcomponent
-
setHeaders
protected void setHeaders(elemental.json.JsonObject headers)
Description copied from corresponding location in WebComponent:
Key-Value map to send to the server. If you set this property as an attribute, use a valid JSON string, for example:
<vaadin-upload headers=' "X-Foo": "Bar"
'>}Parameters:
headers
- the JsonObject value to set
-
getTimeoutDouble
protected double getTimeoutDouble()
Description copied from corresponding location in WebComponent:
Max time in milliseconds for the entire upload process, if exceeded the request will be aborted. Zero means that there is no timeout.
<p>This property is not synchronized automatically from the client side, so the returned value may not be the same as in client side.
Returns:
the
timeout
property from the webcomponent
-
setTimeout
protected void setTimeout(double timeout)
Description copied from corresponding location in WebComponent:
Max time in milliseconds for the entire upload process, if exceeded the request will be aborted. Zero means that there is no timeout.
Parameters:
timeout
- the double value to set
-
getFilesJsonArray
@Synchronize(property="files", value="files-changed") protected elemental.json.JsonArray getFilesJsonArray()
Description copied from corresponding location in WebComponent:
The array of files being processed, or already uploaded.
Each element is a
File
object with a number of extra properties to track the upload process:uploadTarget
: The target URL used to upload this file.elapsed
: Elapsed time since the upload started.elapsedStr
: Human-readable elapsed time.remaining
: Number of seconds remaining for the upload to finish.remainingStr
: Human-readable remaining time for the upload to finish.progress
: Percentage of the file already uploaded.speed
: Upload speed in kB/s.size
: File size in bytes.totalStr
: Human-readable total size of the file.loaded
: Bytes transferred so far.loadedStr
: Human-readable uploaded size at the moment.status
: Status of the upload process.error
: Error message in case the upload failed.abort
: True if the file was canceled by the user.complete
: True when the file was transferred to the server.uploading
: True while transferring data to the server.This property is synchronized automatically from client side when a 'files-changed' event happens.
Returns:
the
files
property from the webcomponent
-
setFiles
protected void setFiles(elemental.json.JsonArray files)
Description copied from corresponding location in WebComponent:
The array of files being processed, or already uploaded.
Each element is a
File
object with a number of extra properties to track the upload process:uploadTarget
: The target URL used to upload this file.elapsed
: Elapsed time since the upload started.elapsedStr
: Human-readable elapsed time.remaining
: Number of seconds remaining for the upload to finish.remainingStr
: Human-readable remaining time for the upload to finish.progress
: Percentage of the file already uploaded.speed
: Upload speed in kB/s.size
: File size in bytes.totalStr
: Human-readable total size of the file.loaded
: Bytes transferred so far.loadedStr
: Human-readable uploaded size at the moment.status
: Status of the upload process.error
: Error message in case the upload failed.abort
: True if the file was canceled by the user.complete
: True when the file was transferred to the server.uploading
: True while transferring data to the server.
Parameters:
files
- the JsonArray value to set
-
getMaxFilesDouble
protected double getMaxFilesDouble()
Description copied from corresponding location in WebComponent:
Limit of files to upload, by default it is unlimited. If the value is set to one, native file browser will prevent selecting multiple files.
This property is not synchronized automatically from the client side, so the returned value may not be the same as in client side.
Returns:
the
maxFiles
property from the webcomponent
-
setMaxFiles
protected void setMaxFiles(double maxFiles)
Description copied from corresponding location in WebComponent:
Limit of files to upload, by default it is unlimited. If the value is set to one, native file browser will prevent selecting multiple files.
Parameters:
maxFiles
- the double value to set
-
isMaxFilesReachedBoolean
@Synchronize(property="maxFilesReached", value="max-files-reached-changed") protected boolean isMaxFilesReachedBoolean()
Description copied from corresponding location in WebComponent:
Specifies if the maximum number of files have been uploaded
This property is synchronized automatically from client side when a 'max-files-reached-changed' event happens.
Returns:
the
maxFilesReached
property from the webcomponent
-
getAcceptString
protected String getAcceptString()
Description copied from corresponding location in WebComponent:
Specifies the types of files that the server accepts. Syntax: a comma-separated list of MIME type patterns (wildcards are allowed) or file extensions. Notice that MIME types are widely supported, while file extensions are only implemented in certain browsers, so avoid using it. Example: accept="video/*,image/tiff" or accept=".pdf,audio/mp3"
This property is not synchronized automatically from the client side, so the returned value may not be the same as in client side.
Returns:
the
accept
property from the webcomponent
-
setAccept
protected void setAccept(String accept)
Description copied from corresponding location in WebComponent:
Specifies the types of files that the server accepts. Syntax: a comma-separated list of MIME type patterns (wildcards are allowed) or file extensions. Notice that MIME types are widely supported, while file extensions are only implemented in certain browsers, so avoid using it. Example: accept="video/*,image/tiff" or accept=".pdf,audio/mp3"
Parameters:
accept
- the String value to set
-
getMaxFileSizeDouble
protected double getMaxFileSizeDouble()
Description copied from corresponding location in WebComponent:
Specifies the maximum file size in bytes allowed to upload. Notice that it is a client-side constraint, which will be checked before sending the request. Obviously you need to do the same validation in the server-side and be sure that they are aligned.
This property is not synchronized automatically from the client side, so the returned value may not be the same as in client side.
Returns:
the
maxFileSize
property from the webcomponent
-
setMaxFileSize
protected void setMaxFileSize(double maxFileSize)
Description copied from corresponding location in WebComponent:
Specifies the maximum file size in bytes allowed to upload. Notice that it is a client-side constraint, which will be checked before sending the request. Obviously you need to do the same validation in the server-side and be sure that they are aligned.
Parameters:
maxFileSize
- the double value to set
-
getFormDataNameString
protected String getFormDataNameString()
Description copied from corresponding location in WebComponent:
Specifies the 'name' property at Content-Disposition
This property is not synchronized automatically from the client side, so the returned value may not be the same as in client side.
Returns:
the
formDataName
property from the webcomponent
-
setFormDataName
protected void setFormDataName(String formDataName)
Description copied from corresponding location in WebComponent:
Specifies the 'name' property at Content-Disposition
Parameters:
formDataName
- the String value to set
-
isNoAutoBoolean
protected boolean isNoAutoBoolean()
Description copied from corresponding location in WebComponent:
Prevents upload(s) from immediately uploading upon adding file(s). When set, you must manually trigger uploads using the
uploadFiles
methodThis property is not synchronized automatically from the client side, so the returned value may not be the same as in client side.
Returns:
the
noAuto
property from the webcomponent
-
setNoAuto
protected void setNoAuto(boolean noAuto)
Description copied from corresponding location in WebComponent:
Prevents upload(s) from immediately uploading upon adding file(s). When set, you must manually trigger uploads using the
uploadFiles
methodParameters:
noAuto
- the boolean value to set
-
isWithCredentialsBoolean
protected boolean isWithCredentialsBoolean()
Description copied from corresponding location in WebComponent:
Set the withCredentials flag on the request.
This property is not synchronized automatically from the client side, so the returned value may not be the same as in client side.
Returns:
the
withCredentials
property from the webcomponent
-
setWithCredentials
protected void setWithCredentials(boolean withCredentials)
Description copied from corresponding location in WebComponent:
Set the withCredentials flag on the request.
Parameters:
withCredentials
- the boolean value to set
-
getCaptureString
protected String getCaptureString()
Description copied from corresponding location in WebComponent:
Pass-through to input's capture attribute. Allows user to trigger device inputs such as camera or microphone immediately.
This property is not synchronized automatically from the client side, so the returned value may not be the same as in client side.
Returns:
the
capture
property from the webcomponent
-
setCapture
protected void setCapture(String capture)
Description copied from corresponding location in WebComponent:
Pass-through to input's capture attribute. Allows user to trigger device inputs such as camera or microphone immediately.
Parameters:
capture
- the String value to set
-
getI18nJsonObject
protected elemental.json.JsonObject getI18nJsonObject()
Description copied from corresponding location in WebComponent:
The object used to localize this component. For changing the default localization, change the entire i18n object or just the property you want to modify.
The object has the following JSON structure and default values:
{ dropFiles: { one: 'Drop file here many: 'Drop files here }, addFiles: { one: 'Select File...', many: 'Upload Files...' }, cancel: 'Cancel', error: { tooManyFiles: 'Too Many Files.', fileIsTooBig: 'File is Too Big.', incorrectFileType: 'Incorrect File Type.' }, uploading: { status: { connecting: 'Connecting...', stalled: 'Stalled.', processing: 'Processing File...', held: 'Queued' }, remainingTime: { prefix: 'remaining time: ', unknown: 'unknown remaining time' }, error: { serverUnavailable: 'Server Unavailable', unexpectedServerError: 'Unexpected Server Error', forbidden: 'Forbidden' } }, units: { size: ['B', 'kB', 'MB', 'GB', 'TB', 'PB', 'EB', 'ZB', 'YB'] }, formatSize: function(bytes) { // returns the size followed by the best suitable unit }, formatTime: function(seconds, [secs, mins, hours]) { // returns a 'HH:MM:SS' string } }<p>This property is not synchronized automatically from the client side, so the returned value may not be the same as in client side.
Returns:
the
i18n
property from the webcomponent
-
setI18n
protected void setI18n(elemental.json.JsonObject i18n)
Description copied from corresponding location in WebComponent:
The object used to localize this component. For changing the default localization, change the entire i18n object or just the property you want to modify.
The object has the following JSON structure and default values:
{ dropFiles: { one: 'Drop file here many: 'Drop files here }, addFiles: { one: 'Select File...', many: 'Upload Files...' }, cancel: 'Cancel', error: { tooManyFiles: 'Too Many Files.', fileIsTooBig: 'File is Too Big.', incorrectFileType: 'Incorrect File Type.' }, uploading: { status: { connecting: 'Connecting...', stalled: 'Stalled.', processing: 'Processing File...', held: 'Queued' }, remainingTime: { prefix: 'remaining time: ', unknown: 'unknown remaining time' }, error: { serverUnavailable: 'Server Unavailable', unexpectedServerError: 'Unexpected Server Error', forbidden: 'Forbidden' } }, units: { size: ['B', 'kB', 'MB', 'GB', 'TB', 'PB', 'EB', 'ZB', 'YB'] }, formatSize: function(bytes) { // returns the size followed by the best suitable unit }, formatTime: function(seconds, [secs, mins, hours]) { // returns a 'HH:MM:SS' string } }
Parameters:
i18n
- the JsonObject value to set
-
uploadFiles
protected void uploadFiles(elemental.json.JsonObject files)
Description copied from corresponding location in WebComponent:
Triggers the upload of any files that are not completed
Parameters:
files
- Missing documentation!
-
addFileRejectListener
protected Registration addFileRejectListener(ComponentEventListener<GeneratedVaadinUpload.FileRejectEvent<R>> listener)
Adds a listener for
file-reject
events fired by the webcomponent.Parameters:
listener
- the listenerReturns:
a
Registration
for removing the event listener
-
addUploadAbortListener
protected Registration addUploadAbortListener(ComponentEventListener<GeneratedVaadinUpload.UploadAbortEvent<R>> listener)
Adds a listener for
upload-abort
events fired by the webcomponent.Parameters:
listener
- the listenerReturns:
a
Registration
for removing the event listener
-
addUploadBeforeListener
protected Registration addUploadBeforeListener(ComponentEventListener<GeneratedVaadinUpload.UploadBeforeEvent<R>> listener)
Adds a listener for
upload-before
events fired by the webcomponent.Parameters:
listener
- the listenerReturns:
a
Registration
for removing the event listener
-
addUploadErrorListener
protected Registration addUploadErrorListener(ComponentEventListener<GeneratedVaadinUpload.UploadErrorEvent<R>> listener)
Adds a listener for
upload-error
events fired by the webcomponent.Parameters:
listener
- the listenerReturns:
a
Registration
for removing the event listener
-
addUploadProgressListener
protected Registration addUploadProgressListener(ComponentEventListener<GeneratedVaadinUpload.UploadProgressEvent<R>> listener)
Adds a listener for
upload-progress
events fired by the webcomponent.Parameters:
listener
- the listenerReturns:
a
Registration
for removing the event listener
-
addUploadRequestListener
protected Registration addUploadRequestListener(ComponentEventListener<GeneratedVaadinUpload.UploadRequestEvent<R>> listener)
Adds a listener for
upload-request
events fired by the webcomponent.Parameters:
listener
- the listenerReturns:
a
Registration
for removing the event listener
-
addUploadResponseListener
protected Registration addUploadResponseListener(ComponentEventListener<GeneratedVaadinUpload.UploadResponseEvent<R>> listener)
Adds a listener for
upload-response
events fired by the webcomponent.Parameters:
listener
- the listenerReturns:
a
Registration
for removing the event listener
-
addUploadRetryListener
protected Registration addUploadRetryListener(ComponentEventListener<GeneratedVaadinUpload.UploadRetryEvent<R>> listener)
Adds a listener for
upload-retry
events fired by the webcomponent.Parameters:
listener
- the listenerReturns:
a
Registration
for removing the event listener
-
addUploadStartListener
protected Registration addUploadStartListener(ComponentEventListener<GeneratedVaadinUpload.UploadStartEvent<R>> listener)
Adds a listener for
upload-start
events fired by the webcomponent.Parameters:
listener
- the listenerReturns:
a
Registration
for removing the event listener
-
addUploadSuccessListener
protected Registration addUploadSuccessListener(ComponentEventListener<GeneratedVaadinUpload.UploadSuccessEvent<R>> listener)
Adds a listener for
upload-success
events fired by the webcomponent.Parameters:
listener
- the listenerReturns:
a
Registration
for removing the event listener
-
addFilesChangeListener
protected Registration addFilesChangeListener(ComponentEventListener<GeneratedVaadinUpload.FilesChangeEvent<R>> listener)
Adds a listener for
files-changed
events fired by the webcomponent.Parameters:
listener
- the listenerReturns:
a
Registration
for removing the event listener
-
addMaxFilesReachedChangeListener
protected Registration addMaxFilesReachedChangeListener(ComponentEventListener<GeneratedVaadinUpload.MaxFilesReachedChangeEvent<R>> listener)
Adds a listener for
max-files-reached-changed
events fired by the webcomponent.Parameters:
listener
- the listenerReturns:
a
Registration
for removing the event listener
-
addToAddButton
protected void addToAddButton(Component... components)
Adds the given components as children of this component at the slot 'add-button'.
Parameters:
components
- The components to add.See Also:
-
addToDropLabelIcon
protected void addToDropLabelIcon(Component... components)
Adds the given components as children of this component at the slot 'drop-label-icon'.
Parameters:
components
- The components to add.See Also:
-
addToDropLabel
protected void addToDropLabel(Component... components)
Adds the given components as children of this component at the slot 'drop-label'.
Parameters:
components
- The components to add.See Also:
-
addToFileList
protected void addToFileList(Component... components)
Adds the given components as children of this component at the slot 'file-list'.
Parameters:
components
- The components to add.See Also:
-
remove
protected void remove(Component... components)
Removes the given child components from this component.
Parameters:
components
- The components to remove.Throws:
IllegalArgumentException
- if any of the components is not a child of this component.
-
removeAll
protected void removeAll()
Removes all contents from this component, this includes child components, text content as well as child elements that have been added directly to this component using the
Element
API.
-
-