Class ContentDisposition
java.lang.Object
org.glassfish.jersey.media.multipart.ContentDisposition
- Direct Known Subclasses:
FormDataContentDisposition
A content disposition header.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classContentDisposition.ContentDispositionBuilder<T extends ContentDisposition.ContentDispositionBuilder, V extends ContentDisposition>Builder to build content disposition. -
Field Summary
FieldsModifier and TypeFieldDescriptionprivate Dateprivate Stringprivate Dateprivate Dateprivate longprivate final CharSequence -
Constructor Summary
ConstructorsModifierConstructorDescriptionContentDisposition(String header) ContentDisposition(String header, boolean fileNameFix) protectedContentDisposition(String type, String fileName, Date creationDate, Date modificationDate, Date readDate, long size) ContentDisposition(HttpHeaderReader reader, boolean fileNameFix) -
Method Summary
Modifier and TypeMethodDescriptionprotected voidaddDateParameter(StringBuilder sb, String name, Date p) protected voidaddLongParameter(StringBuilder sb, String name, Long p) protected voidaddStringParameter(StringBuilder sb, String name, String p) private DatecreateDate(String name) private longcreateLong(String name) private voidGet the creation-date parameter.Get the filename parameter.Get the modification-date parameter.Get the parameters.Get the read-date parameter.longgetSize()Get the size parameter.getType()Get the type.toString()Convert the disposition to a "Content-Disposition" header value.protected StringBuilderStart building content disposition.
-
Field Details
-
type
-
parameters
-
fileName
-
creationDate
-
modificationDate
-
readDate
-
size
private long size
-
-
Constructor Details
-
ContentDisposition
-
ContentDisposition
- Throws:
ParseException
-
ContentDisposition
- Throws:
ParseException
-
ContentDisposition
- Throws:
ParseException
-
-
Method Details
-
getType
-
getParameters
-
getFileName
-
getCreationDate
-
getModificationDate
Get the modification-date parameter.- Returns:
- the modificationDate
-
getReadDate
-
getSize
public long getSize()Get the size parameter.- Returns:
- the size
-
toString
-
toStringBuffer
-
addStringParameter
-
addDateParameter
-
addLongParameter
-
createParameters
- Throws:
ParseException
-
createDate
- Throws:
ParseException
-
createLong
- Throws:
ParseException
-
type
Start building content disposition.- Parameters:
type- the disposition type.- Returns:
- the content disposition builder.
-