Class FileUploadWidgetSettings
- java.lang.Object
-
- org.hippoecm.frontend.plugins.jquery.upload.FileUploadWidgetSettings
-
- All Implemented Interfaces:
Serializable
,org.apache.wicket.util.io.IClusterable
public class FileUploadWidgetSettings extends Object implements org.apache.wicket.util.io.IClusterable
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description static String
AUTOUPLOAD_PROP
static String
FILEUPLOAD_MAX_ITEMS
static String
MAX_FILESIZE_PROP
static String
MAX_HEIGHT_PROP
static String
MAX_WIDTH_PROP
-
Constructor Summary
Constructors Constructor Description FileUploadWidgetSettings(IPluginConfig pluginConfig, FileUploadValidationService validator)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description String[]
getAllowedExtensions()
long
getMaxFileSize()
Maximal file size of allowed upload files.long
getMaxHeight()
Maximal height of allowed upload images.long
getMaxNumberOfFiles()
The maximal number of files to upload.long
getMaxWidth()
Maximal width of allowed upload images.String
getSelectionChangeNotificationUrl()
String
getUploadDoneNotificationUrl()
The url to notify on the completion of uploading.String
getUploadUrl()
The url to receive uploading files.boolean
isAutoUpload()
The setting used inFileUploadBehavior
to determine when selecting a file, the widget should upload it automatically or wait until the upload script is called.void
loadConfig(IPluginConfig pluginConfig, FileUploadValidationService validator)
void
setAutoUpload(boolean autoUpload)
void
setSelectionChangeNotificationUrl(String selectionChangeNotificationUrl)
Sets the url to notify when the file selection list has been changed.void
setUploadDoneNotificationUrl(String notificationUrl)
The url to notify on the completion of uploading.void
setUploadUrl(String url)
The url to receive uploading files.
-
-
-
Field Detail
-
MAX_WIDTH_PROP
public static final String MAX_WIDTH_PROP
- See Also:
- Constant Field Values
-
MAX_HEIGHT_PROP
public static final String MAX_HEIGHT_PROP
- See Also:
- Constant Field Values
-
MAX_FILESIZE_PROP
public static final String MAX_FILESIZE_PROP
- See Also:
- Constant Field Values
-
FILEUPLOAD_MAX_ITEMS
public static final String FILEUPLOAD_MAX_ITEMS
- See Also:
- Constant Field Values
-
AUTOUPLOAD_PROP
public static final String AUTOUPLOAD_PROP
- See Also:
- Constant Field Values
-
-
Constructor Detail
-
FileUploadWidgetSettings
public FileUploadWidgetSettings(IPluginConfig pluginConfig, FileUploadValidationService validator)
-
-
Method Detail
-
loadConfig
public void loadConfig(IPluginConfig pluginConfig, FileUploadValidationService validator)
-
getMaxWidth
public long getMaxWidth()
Maximal width of allowed upload images.
-
getMaxHeight
public long getMaxHeight()
Maximal height of allowed upload images.
-
getMaxFileSize
public long getMaxFileSize()
Maximal file size of allowed upload files.
-
getUploadUrl
public String getUploadUrl()
The url to receive uploading files. This setting is used for multi-files uploads only.
-
setUploadUrl
public void setUploadUrl(String url)
The url to receive uploading files. This setting is used for multi-files uploads only.- Parameters:
url
-
-
setUploadDoneNotificationUrl
public void setUploadDoneNotificationUrl(String notificationUrl)
The url to notify on the completion of uploading. This setting is used for multi-files uploads only.- Parameters:
notificationUrl
-
-
getUploadDoneNotificationUrl
public String getUploadDoneNotificationUrl()
The url to notify on the completion of uploading. This setting is used for multi-files uploads only.
-
getMaxNumberOfFiles
public long getMaxNumberOfFiles()
The maximal number of files to upload. This setting is used for multi-files uploads only.
-
getAllowedExtensions
public String[] getAllowedExtensions()
-
isAutoUpload
public boolean isAutoUpload()
The setting used inFileUploadBehavior
to determine when selecting a file, the widget should upload it automatically or wait until the upload script is called.
-
setAutoUpload
public final void setAutoUpload(boolean autoUpload)
- See Also:
isAutoUpload()
-
setSelectionChangeNotificationUrl
public void setSelectionChangeNotificationUrl(String selectionChangeNotificationUrl)
Sets the url to notify when the file selection list has been changed. This setting is used for multi-file uploads only.- Parameters:
selectionChangeNotificationUrl
-
-
getSelectionChangeNotificationUrl
public String getSelectionChangeNotificationUrl()
- Returns:
- the url to notify when the file selection list has been changed. This setting is used for multi-file uploads only.
-
-