com.liferay.faces.alloy.component.inputfile
Class InputFileBase

java.lang.Object
  extended by javax.faces.component.UIComponent
      extended by javax.faces.component.UIComponentBase
          extended by javax.faces.component.UIOutput
              extended by javax.faces.component.UIInput
                  extended by javax.faces.component.html.HtmlInputFile
                      extended by com.liferay.faces.util.component.InputFileBase
                          extended by com.liferay.faces.alloy.component.inputfile.InputFileBase
All Implemented Interfaces:
com.liferay.faces.util.component.ClientComponent, com.liferay.faces.util.component.Styleable, EventListener, javax.faces.component.behavior.ClientBehaviorHolder, javax.faces.component.EditableValueHolder, javax.faces.component.PartialStateHolder, javax.faces.component.StateHolder, javax.faces.component.TransientStateHolder, javax.faces.component.ValueHolder, javax.faces.event.ComponentSystemEventListener, javax.faces.event.FacesListener, javax.faces.event.SystemEventListenerHolder
Direct Known Subclasses:
InputFile

@Generated(value="com.liferay.alloy.tools.builder.FacesBuilder")
public abstract class InputFileBase
extends com.liferay.faces.util.component.InputFileBase
implements com.liferay.faces.util.component.Styleable, com.liferay.faces.util.component.ClientComponent

Author:
Bruno Basto, Kyle Stiemann

Nested Class Summary
protected static class InputFileBase.InputFilePropertyKeys
           
 
Nested classes/interfaces inherited from class javax.faces.component.html.HtmlInputFile
javax.faces.component.html.HtmlInputFile.PropertyKeys
 
Field Summary
static String COMPONENT_TYPE
           
static String RENDERER_TYPE
           
 
Fields inherited from class javax.faces.component.UIInput
COMPONENT_FAMILY, CONVERSION_MESSAGE_ID, REQUIRED_MESSAGE_ID, UPDATE_MESSAGE_ID, VALIDATE_EMPTY_FIELDS_PARAM_NAME
 
Fields inherited from class javax.faces.component.UIComponent
ATTRS_WITH_DECLARED_DEFAULT_VALUES, BEANINFO_KEY, bindings, COMPOSITE_COMPONENT_TYPE_KEY, COMPOSITE_FACET_NAME, CURRENT_COMPONENT, CURRENT_COMPOSITE_COMPONENT, FACETS_KEY, HONOR_CURRENT_COMPONENT_ATTRIBUTES_PARAM_NAME, VIEW_LOCATION_KEY
 
Fields inherited from interface com.liferay.faces.util.component.Styleable
STYLE, STYLE_CLASS
 
Fields inherited from interface com.liferay.faces.util.component.ClientComponent
CLIENT_KEY
 
Constructor Summary
InputFileBase()
           
 
Method Summary
 String getClientKey()
          clientKey attribute description:
 String getContentTypes()
          contentTypes attribute description:
 javax.el.MethodExpression getFileUploadListener()
          fileUploadListener attribute description:
 String getLabel()
          label attribute description:
 String getLocation()
          location attribute description:
 Long getMaxFileSize()
          maxFileSize attribute description:
 String getMultiple()
          multiple attribute description:
 String getStyleClass()
          styleClass attribute description:
 boolean isAppendNewFiles()
          appendNewFiles attribute description:
 boolean isAuto()
          auto attribute description:
 boolean isShowPreview()
          showPreview attribute description:
 boolean isShowProgress()
          showProgress attribute description:
 void setAppendNewFiles(boolean appendNewFiles)
          appendNewFiles attribute description:
 void setAuto(boolean auto)
          auto attribute description:
 void setClientKey(String clientKey)
          clientKey attribute description:
 void setContentTypes(String contentTypes)
          contentTypes attribute description:
 void setFileUploadListener(javax.el.MethodExpression fileUploadListener)
          fileUploadListener attribute description:
 void setLocation(String location)
          location attribute description:
 void setMaxFileSize(Long maxFileSize)
          maxFileSize attribute description:
 void setMultiple(String multiple)
          multiple attribute description:
 void setShowPreview(boolean showPreview)
          showPreview attribute description:
 void setShowProgress(boolean showProgress)
          showProgress attribute description:
 
Methods inherited from class javax.faces.component.html.HtmlInputFile
getAccesskey, getAlt, getAutocomplete, getDefaultEventName, getDir, getEventNames, getLang, getMaxlength, getOnblur, getOnchange, getOnclick, getOndblclick, getOnfocus, getOnkeydown, getOnkeypress, getOnkeyup, getOnmousedown, getOnmousemove, getOnmouseout, getOnmouseover, getOnmouseup, getOnselect, getRole, getSize, getStyle, getTabindex, getTitle, isDisabled, isReadonly, setAccesskey, setAlt, setAutocomplete, setDir, setDisabled, setLabel, setLang, setMaxlength, setOnblur, setOnchange, setOnclick, setOndblclick, setOnfocus, setOnkeydown, setOnkeypress, setOnkeyup, setOnmousedown, setOnmousemove, setOnmouseout, setOnmouseover, setOnmouseup, setOnselect, setReadonly, setRole, setSize, setStyle, setStyleClass, setTabindex, setTitle
 
Methods inherited from class javax.faces.component.UIInput
addValidator, addValueChangeListener, clearInitialState, compareValues, decode, getConvertedValue, getConverterMessage, getFamily, getRequiredMessage, getSubmittedValue, getValidator, getValidatorMessage, getValidators, getValue, getValueChangeListener, getValueChangeListeners, isEmpty, isImmediate, isLocalValueSet, isRequired, isValid, markInitialState, processDecodes, processUpdates, processValidators, removeValidator, removeValueChangeListener, resetValue, restoreState, saveState, setConverterMessage, setImmediate, setLocalValueSet, setRequired, setRequiredMessage, setSubmittedValue, setValid, setValidator, setValidatorMessage, setValue, setValueChangeListener, updateModel, validate, validateValue
 
Methods inherited from class javax.faces.component.UIOutput
getConverter, getLocalValue, setConverter
 
Methods inherited from class javax.faces.component.UIComponentBase
addClientBehavior, addFacesListener, broadcast, encodeBegin, encodeChildren, encodeEnd, findComponent, getAttributes, getChildCount, getChildren, getClientBehaviors, getClientId, getFacesContext, getFacesListeners, getFacet, getFacetCount, getFacets, getFacetsAndChildren, getId, getListenersForEventClass, getParent, getPassThroughAttributes, getRenderer, getRendererType, getRendersChildren, getValueBinding, invokeOnComponent, isRendered, isTransient, processRestoreState, processSaveState, queueEvent, removeFacesListener, restoreAttachedState, saveAttachedState, setId, setParent, setRendered, setRendererType, setTransient, setValueBinding, subscribeToEvent, unsubscribeFromEvent
 
Methods inherited from class javax.faces.component.UIComponent
encodeAll, getClientId, getCompositeComponentParent, getContainerClientId, getCurrentComponent, getCurrentCompositeComponent, getNamingContainer, getPassThroughAttributes, getResourceBundleMap, getStateHelper, getStateHelper, getTransientStateHelper, getTransientStateHelper, getValueExpression, initialStateMarked, isCompositeComponent, isInView, isVisitable, popComponentFromEL, processEvent, pushComponentToEL, restoreTransientState, saveTransientState, setInView, setValueExpression, visitTree
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface com.liferay.faces.util.component.Styleable
getStyle, setStyle, setStyleClass
 
Methods inherited from interface com.liferay.faces.util.component.ClientComponent
getClientId
 
Methods inherited from interface javax.faces.component.behavior.ClientBehaviorHolder
addClientBehavior, getClientBehaviors
 
Methods inherited from interface javax.faces.component.ValueHolder
getConverter, getLocalValue, setConverter
 

Field Detail

COMPONENT_TYPE

public static final String COMPONENT_TYPE
See Also:
Constant Field Values

RENDERER_TYPE

public static final String RENDERER_TYPE
See Also:
Constant Field Values
Constructor Detail

InputFileBase

public InputFileBase()
Method Detail

isAppendNewFiles

public boolean isAppendNewFiles()

appendNewFiles attribute description:

When this flag is true, selected files are appended to the preview table. Otherwise, the preview table is cleared when new files are selected. NOTE: This feature is only available when showProgress=true.


setAppendNewFiles

public void setAppendNewFiles(boolean appendNewFiles)

appendNewFiles attribute description:

When this flag is true, selected files are appended to the preview table. Otherwise, the preview table is cleared when new files are selected. NOTE: This feature is only available when showProgress=true.


isAuto

public boolean isAuto()

auto attribute description:

When this flag is true, files are uploaded automatically as soon as they are selected.


setAuto

public void setAuto(boolean auto)

auto attribute description:

When this flag is true, files are uploaded automatically as soon as they are selected.


getClientKey

public String getClientKey()

clientKey attribute description:

The key name that can be used to reference the component on the client.

Specified by:
getClientKey in interface com.liferay.faces.util.component.ClientComponent

setClientKey

public void setClientKey(String clientKey)

clientKey attribute description:

The key name that can be used to reference the component on the client.

Specified by:
setClientKey in interface com.liferay.faces.util.component.ClientComponent

getContentTypes

public String getContentTypes()

contentTypes attribute description:

Comma-delimited list of uploaded file MIME types that are valid. If not specified, then all MIME types are assumed to be valid.


setContentTypes

public void setContentTypes(String contentTypes)

contentTypes attribute description:

Comma-delimited list of uploaded file MIME types that are valid. If not specified, then all MIME types are assumed to be valid.


getFileUploadListener

public javax.el.MethodExpression getFileUploadListener()

fileUploadListener attribute description:

A method that is executed when a file is uploaded. The method must be public, return void, and take a FileUploadEvent argument.


setFileUploadListener

public void setFileUploadListener(javax.el.MethodExpression fileUploadListener)

fileUploadListener attribute description:

A method that is executed when a file is uploaded. The method must be public, return void, and take a FileUploadEvent argument.


getLabel

public String getLabel()

label attribute description:

A localized label for this component that is typically only rendered in a FacesMessage when validation fails.

Overrides:
getLabel in class javax.faces.component.html.HtmlInputFile

getLocation

public String getLocation()

location attribute description:

The absolute path that uploaded file should be copied to. If not specified, then the value of the <location> element specified in the Servlet 3.0 web.xml <multipart-config> of the FacesServlet <servlet> will be utilized. Otherwise, the value of the "com.liferay.faces.util.uploadedFilesDir" context-param is utilizied.


setLocation

public void setLocation(String location)

location attribute description:

The absolute path that uploaded file should be copied to. If not specified, then the value of the <location> element specified in the Servlet 3.0 web.xml <multipart-config> of the FacesServlet <servlet> will be utilized. Otherwise, the value of the "com.liferay.faces.util.uploadedFilesDir" context-param is utilizied.


getMaxFileSize

public Long getMaxFileSize()

maxFileSize attribute description:

Maximum length (in bytes) permitted for each individual uploaded file. If not specified, then files of any length are assumed to be valid.


setMaxFileSize

public void setMaxFileSize(Long maxFileSize)

maxFileSize attribute description:

Maximum length (in bytes) permitted for each individual uploaded file. If not specified, then files of any length are assumed to be valid.


getMultiple

public String getMultiple()

multiple attribute description:

HTML passthrough attribute specifying whether or not multiple files can be uploaded. Valid values are blank (to upload a single file) or "multiple" (to upload multiple files).


setMultiple

public void setMultiple(String multiple)

multiple attribute description:

HTML passthrough attribute specifying whether or not multiple files can be uploaded. Valid values are blank (to upload a single file) or "multiple" (to upload multiple files).


isShowPreview

public boolean isShowPreview()

showPreview attribute description:

When this flag is true, a table showing a preview will be rendered when the user selects one or more files.


setShowPreview

public void setShowPreview(boolean showPreview)

showPreview attribute description:

When this flag is true, a table showing a preview will be rendered when the user selects one or more files.


isShowProgress

public boolean isShowProgress()

showProgress attribute description:

When this flag is true, a table showing file upload progress will be rendered when the user selects one of more files.


setShowProgress

public void setShowProgress(boolean showProgress)

showProgress attribute description:

When this flag is true, a table showing file upload progress will be rendered when the user selects one of more files.


getStyleClass

public String getStyleClass()

styleClass attribute description:

List of CSS class names (separated by spaces) that are to be rendered within the class attribute.

Specified by:
getStyleClass in interface com.liferay.faces.util.component.Styleable
Overrides:
getStyleClass in class javax.faces.component.html.HtmlInputFile


Copyright © 2017 Liferay, Inc.. All rights reserved.