org.apache.struts.upload
public class MultipartElement extends java.lang.Object
null
content type,
files have a non-null content type.Modifier and Type | Field and Description |
---|---|
protected java.lang.String |
contentType
Deprecated.
The content type of this element.
|
protected byte[] |
data
Deprecated.
This should never be used.
|
protected java.io.File |
file
Deprecated.
The element's data represented in a (possibly temporary) file.
|
protected java.lang.String |
fileName
Deprecated.
The element's filename, null for text elements.
|
protected boolean |
isFile
Deprecated.
Whether or not this element is a file.
|
protected java.lang.String |
name
Deprecated.
The element name.
|
protected java.lang.String |
value
Deprecated.
The element's text value, null for file elements
|
Constructor and Description |
---|
MultipartElement(java.lang.String name,
java.lang.String value)
Deprecated.
Constructor for a text element.
|
MultipartElement(java.lang.String name,
java.lang.String fileName,
java.lang.String contentType,
java.io.File file)
Deprecated.
Constructor for a file element.
|
Modifier and Type | Method and Description |
---|---|
java.lang.String |
getContentType()
Deprecated.
Retrieve the content type.
|
java.io.File |
getFile()
Deprecated.
Get the File that holds the data for this element.
|
java.lang.String |
getFileName()
Deprecated.
Retrieve the filename, can return
null
for text elements. |
java.lang.String |
getName()
Deprecated.
Retrieve the name.
|
java.lang.String |
getValue()
Deprecated.
Returns the value of this multipart element.
|
boolean |
isFile()
Deprecated.
Is this element a file.
|
void |
setContentType(java.lang.String contentType)
Deprecated.
Set the content type.
|
void |
setFile(java.io.File file)
Deprecated.
Set the file that represents this element.
|
void |
setFileName(java.lang.String fileName)
Deprecated.
Set the file name for this element.
|
void |
setName(java.lang.String name)
Deprecated.
Set the name for this element.
|
void |
setValue(java.lang.String value)
Deprecated.
|
protected java.lang.String contentType
protected byte[] data
protected java.io.File file
protected java.lang.String name
protected java.lang.String fileName
protected java.lang.String value
protected boolean isFile
public MultipartElement(java.lang.String name, java.lang.String fileName, java.lang.String contentType, java.io.File file)
name
- The form name of the elementfileName
- The file name of the element if this element is a filecontentType
- The content type of the element if a filefile
- The (possibly temporary) file representing this element if
it's a filepublic MultipartElement(java.lang.String name, java.lang.String value)
name
- The name of the elementvalue
- The value of the elementpublic java.lang.String getContentType()
public java.io.File getFile()
public java.lang.String getName()
public java.lang.String getFileName()
null
for text elements.public java.lang.String getValue()
null
otherwisepublic void setFile(java.io.File file)
public void setFileName(java.lang.String fileName)
public void setName(java.lang.String name)
public void setContentType(java.lang.String contentType)
public boolean isFile()
public void setValue(java.lang.String value)
Copyright ? 2000-2014 - The Apache Software Foundation