|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjavax.faces.component.UIComponent
javax.faces.component.UIComponentBase
javax.faces.component.UIOutput
javax.faces.component.UIInput
org.jboss.seam.ui.component.UIFileUpload
org.jboss.seam.ui.component.html.HtmlFileUpload
public class HtmlFileUpload
Component-Type org.jboss.seam.ui.FileUpload Component-Family org.jboss.seam.ui.FileUpload Renderer-Type org.jboss.seam.ui.FileUploadRenderer Renders a file upload control. This control must be used within a form with an encoding type of multipart/form-data, i.e: <h:form enctype="multipart/form-data"> For multipart requests, the Seam Multipart servlet filter must also be configured in web.xml: <filter> <filter-name>Seam Filter</filter-name> <filter-class>org.jboss.seam.servlet.SeamFilter</filter-class> </filter> <filter-mapping> <filter-name>Seam Filter</filter-name> <url-pattern>/*</url-pattern> </filter-mapping> The following configuration options for multipart requests may be configured in components.xml: createTempFiles - if this option is set to true, uploaded files are streamed to a temporary file instead of in memory. maxRequestSize - the maximum size of a file upload request, in bytes. Here's an example: <component class="org.jboss.seam.servlet.MultipartConfig"> <property name="createTempFiles">true</property> <property name="maxRequestSize">1000000</property> </component>
Field Summary | |
---|---|
static java.lang.String |
COMPONENT_FAMILY
|
static java.lang.String |
COMPONENT_TYPE
|
Fields inherited from class javax.faces.component.UIInput |
---|
CONVERSION_MESSAGE_ID, REQUIRED_MESSAGE_ID, UPDATE_MESSAGE_ID |
Fields inherited from class javax.faces.component.UIComponent |
---|
bindings |
Constructor Summary | |
---|---|
HtmlFileUpload()
Constructor to init default renderers |
Method Summary | |
---|---|
java.lang.String |
getAccept()
a comma-separated list of content types to accept, may not be supported by the browser. |
java.lang.String |
getContentType()
the property to receive the contentType Getter for contentType |
java.lang.Object |
getData()
this value binding receives the file's content type (optional). |
java.lang.String |
getFamily()
|
java.lang.String |
getFileName()
this value binding receives the filename (optional). |
java.lang.Integer |
getFileSize()
this value binding receives the file size (optional). |
java.lang.String |
getStyle()
CSS style(s) is/are to be applied when this component is rendered Getter for style |
java.lang.String |
getStyleClass()
Corresponds to the HTML class attribute Getter for styleClass |
void |
restoreState(javax.faces.context.FacesContext context,
java.lang.Object state)
|
java.lang.Object |
saveState(javax.faces.context.FacesContext context)
|
void |
setAccept(java.lang.String __accept)
a comma-separated list of content types to accept, may not be supported by the browser. |
void |
setContentType(java.lang.String __contentType)
the property to receive the contentType Setter for contentType |
void |
setData(java.lang.Object __data)
this value binding receives the file's content type (optional). |
void |
setFileName(java.lang.String __fileName)
this value binding receives the filename (optional). |
void |
setFileSize(java.lang.Integer __fileSize)
this value binding receives the file size (optional). |
void |
setStyle(java.lang.String __style)
CSS style(s) is/are to be applied when this component is rendered Setter for style |
void |
setStyleClass(java.lang.String __styleClass)
Corresponds to the HTML class attribute Setter for styleClass |
Methods inherited from class org.jboss.seam.ui.component.UIFileUpload |
---|
getLocalContentType, getLocalFileName, getLocalFileSize, getLocalInputStream, processUpdates, setLocalContentType, setLocalFileName, setLocalFileSize, setLocalInputStream |
Methods inherited from class javax.faces.component.UIInput |
---|
addValidator, addValueChangeListener, compareValues, decode, getConvertedValue, getConverterMessage, getRequiredMessage, getSubmittedValue, getValidator, getValidatorMessage, getValidators, getValueChangeListener, getValueChangeListeners, isImmediate, isLocalValueSet, isRequired, isValid, processDecodes, processValidators, removeValidator, removeValueChangeListener, resetValue, setConverterMessage, setImmediate, setLocalValueSet, setRequired, setRequiredMessage, setSubmittedValue, setValid, setValidator, setValidatorMessage, setValue, setValueChangeListener, updateModel, validate, validateValue |
Methods inherited from class javax.faces.component.UIOutput |
---|
getConverter, getLocalValue, getValue, setConverter |
Methods inherited from class javax.faces.component.UIComponentBase |
---|
addFacesListener, broadcast, encodeBegin, encodeChildren, encodeEnd, findComponent, getAttributes, getChildCount, getChildren, getClientId, getFacesContext, getFacesListeners, getFacet, getFacetCount, getFacets, getFacetsAndChildren, getId, getParent, getRenderer, getRendererType, getRendersChildren, getValueBinding, invokeOnComponent, isRendered, isTransient, processRestoreState, processSaveState, queueEvent, removeFacesListener, restoreAttachedState, saveAttachedState, setId, setParent, setRendered, setRendererType, setTransient, setValueBinding |
Methods inherited from class javax.faces.component.UIComponent |
---|
encodeAll, getContainerClientId, getValueExpression, setValueExpression |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface javax.faces.component.ValueHolder |
---|
getConverter, getLocalValue, getValue, setConverter |
Field Detail |
---|
public static final java.lang.String COMPONENT_TYPE
public static final java.lang.String COMPONENT_FAMILY
Constructor Detail |
---|
public HtmlFileUpload()
Method Detail |
---|
public void setFileSize(java.lang.Integer __fileSize)
fileSize
- - new valuepublic java.lang.Integer getFileSize()
public void setStyleClass(java.lang.String __styleClass)
setStyleClass
in class UIFileUpload
styleClass
- - new valuepublic java.lang.String getStyleClass()
getStyleClass
in class UIFileUpload
public void setStyle(java.lang.String __style)
setStyle
in class UIFileUpload
style
- - new valuepublic java.lang.String getStyle()
getStyle
in class UIFileUpload
public void setAccept(java.lang.String __accept)
setAccept
in class UIFileUpload
accept
- - new valuepublic java.lang.String getAccept()
getAccept
in class UIFileUpload
public void setContentType(java.lang.String __contentType)
contentType
- - new valuepublic java.lang.String getContentType()
public void setFileName(java.lang.String __fileName)
fileName
- - new valuepublic java.lang.String getFileName()
public void setData(java.lang.Object __data)
data
- - new valuepublic java.lang.Object getData()
public java.lang.String getFamily()
getFamily
in class javax.faces.component.UIInput
public java.lang.Object saveState(javax.faces.context.FacesContext context)
saveState
in interface javax.faces.component.StateHolder
saveState
in class javax.faces.component.UIInput
public void restoreState(javax.faces.context.FacesContext context, java.lang.Object state)
restoreState
in interface javax.faces.component.StateHolder
restoreState
in class javax.faces.component.UIInput
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |