Top Description Fields Constructors Methods
io.netty.contrib.handler.codec.http.multipart

public Class MixedFileUpload

extends AbstractMixedHttpData<FileUpload>
implements FileUpload
Class Inheritance
All Implemented Interfaces
io.netty.contrib.handler.codec.http.multipart.FileUpload, io.netty.contrib.handler.codec.http.multipart.HttpData, io.netty.contrib.handler.codec.http.multipart.InterfaceHttpData, io.netty5.util.Resource, java.lang.AutoCloseable, java.lang.Comparable
Imports
io.netty5.buffer.Owned, io.netty5.util.Send, java.nio.charset.Charset

Mixed implementation using both in Memory and in File with a limit of size

Field Summary

Inherited from io.netty.contrib.handler.codec.http.multipart.AbstractMixedHttpData:
baseDirdeleteOnExitlimitSizewrapped

Constructor Summary

AccessConstructor and Description
public
MixedFileUpload(String name, String filename, String contentType, String contentTransferEncoding, Charset charset, long size, long limitSize)

public
MixedFileUpload(String name, String filename, String contentType, String contentTransferEncoding, Charset charset, long size, long limitSize, String baseDir, boolean deleteOnExit)

private
MixedFileUpload(long limitSize, String baseDir, boolean deleteOnExit, FileUpload fileUpload)

Method Summary

Modifier and TypeMethod and Description
public String
public String
getContentType()

Implements io.netty.contrib.handler.codec.http.multipart.FileUpload.getContentType.

Returns the content type passed by the browser or null if not defined.
public String
getFilename()

Implements io.netty.contrib.handler.codec.http.multipart.FileUpload.getFilename.

Returns the original filename in the client's filesystem, as provided by the browser (or other client software).
pack-priv FileUpload
protected Owned<AbstractMixedHttpData<?>>
prepareSend()

Implements abstract io.netty5.buffer.internal.ResourceSupport.prepareSend.

Prepare this instance for ownership transfer.
public void
setContentTransferEncoding(String contentTransferEncoding)

Implements io.netty.contrib.handler.codec.http.multipart.FileUpload.setContentTransferEncoding.

Set the Content-Transfer-Encoding type from String as 7bit, 8bit or binary
public void
setContentType(String
Content Type to set - must be not null
contentType
)

Implements io.netty.contrib.handler.codec.http.multipart.FileUpload.setContentType.

Set the Content Type passed by the browser if defined
public void
Inherited from io.netty.contrib.handler.codec.http.multipart.AbstractMixedHttpData:
addContentcheckAccessiblecheckAccessiblecheckSizecompareTocopycreateResourceClosedExceptiondefinedLengthdeleteequalsgetgetCharsetgetChunkgetFilegetHttpDataTypegetMaxSizegetNamegetStringgetStringhashCodeisCompletedisInMemorylengthrenameToreplacesetCharsetsetContentsetContentsetContentsetMaxSizetoStringusingBufferusingContent

Constructor Detail

MixedFileUploadback to summary
public MixedFileUpload(String name, String filename, String contentType, String contentTransferEncoding, Charset charset, long size, long limitSize)
MixedFileUploadback to summary
public MixedFileUpload(String name, String filename, String contentType, String contentTransferEncoding, Charset charset, long size, long limitSize, String baseDir, boolean deleteOnExit)
MixedFileUploadback to summary
private MixedFileUpload(long limitSize, String baseDir, boolean deleteOnExit, FileUpload fileUpload)

Method Detail

getContentTransferEncodingback to summary
public String getContentTransferEncoding()

Implements io.netty.contrib.handler.codec.http.multipart.FileUpload.getContentTransferEncoding.

Doc from io.netty.contrib.handler.codec.http.multipart.FileUpload.getContentTransferEncoding.

Returns the Content-Transfer-Encoding

Returns:String

the Content-Transfer-Encoding

Annotations
@Override
getContentTypeback to summary
public String getContentType()

Implements io.netty.contrib.handler.codec.http.multipart.FileUpload.getContentType.

Doc from io.netty.contrib.handler.codec.http.multipart.FileUpload.getContentType.

Returns the content type passed by the browser or null if not defined.

Returns:String

the content type passed by the browser or null if not defined.

Annotations
@Override
getFilenameback to summary
public String getFilename()

Implements io.netty.contrib.handler.codec.http.multipart.FileUpload.getFilename.

Doc from io.netty.contrib.handler.codec.http.multipart.FileUpload.getFilename.

Returns the original filename in the client's filesystem, as provided by the browser (or other client software).

Returns:String

the original filename

Annotations
@Override
makeDiskDataback to summary
pack-priv FileUpload makeDiskData()

Implements abstract io.netty.contrib.handler.codec.http.multipart.AbstractMixedHttpData.makeDiskData.

Annotations
@Override
prepareSendback to summary
protected Owned<AbstractMixedHttpData<?>> prepareSend()

Implements abstract io.netty5.buffer.internal.ResourceSupport.prepareSend.

Doc from io.netty5.buffer.internal.ResourceSupport.prepareSend.

Prepare this instance for ownership transfer. This method is called from send() in the sending thread. This method should put this resource in a deactivated state where it is no longer accessible from the currently owning thread. In this state, the resource instance should only allow a call to Owned#transferOwnership(Drop) in the recipient thread.

Returns:Owned<AbstractMixedHttpData<?>>

This resource instance in a deactivated state.

Annotations
@Override
setContentTransferEncodingback to summary
public void setContentTransferEncoding(String contentTransferEncoding)

Implements io.netty.contrib.handler.codec.http.multipart.FileUpload.setContentTransferEncoding.

Doc from io.netty.contrib.handler.codec.http.multipart.FileUpload.setContentTransferEncoding.

Set the Content-Transfer-Encoding type from String as 7bit, 8bit or binary

Annotations
@Override
setContentTypeback to summary
public void setContentType(String contentType)

Implements io.netty.contrib.handler.codec.http.multipart.FileUpload.setContentType.

Doc from io.netty.contrib.handler.codec.http.multipart.FileUpload.setContentType.

Set the Content Type passed by the browser if defined

Parameters
contentType:String

Content Type to set - must be not null

Annotations
@Override
setFilenameback to summary
public void setFilename(String filename)

Implements io.netty.contrib.handler.codec.http.multipart.FileUpload.setFilename.

Doc from io.netty.contrib.handler.codec.http.multipart.FileUpload.setFilename.

Set the original filename

Annotations
@Override