public interface Uploadable<T>
form parameters.
All supported objects that can be uploaded using
the HttpBase.form(String, Object) has to
be wrapped with this interface.| Modifier and Type | Method and Description |
|---|---|
byte[] |
getBytes()
Returns content bytes.
|
T |
getContent()
Returns the original content.
|
java.lang.String |
getFileName()
Returns content file name.
|
java.lang.String |
getMimeType()
Returns MIME type.
|
int |
getSize()
Returns size in bytes.
|
java.io.InputStream |
openInputStream()
Opens
InputStream. |
T getContent()
byte[] getBytes()
java.lang.String getFileName()
null, the field's name will be used.java.lang.String getMimeType()
null,
MIME type will be determined from
file name's extension.int getSize()
java.io.InputStream openInputStream()
throws java.io.IOException
InputStream. User is responsible
for closing it.java.io.IOExceptionCopyright © 2003-present Jodd Team