Interface ContentDispositionField

All Superinterfaces:
Field, ParsedField
All Known Implementing Classes:
ContentDispositionFieldImpl, ContentDispositionFieldLenientImpl

public interface ContentDispositionField extends ParsedField
  • Field Details

  • Method Details

    • bodyDescriptionField

      default boolean bodyDescriptionField()
      Specified by:
      bodyDescriptionField in interface ParsedField
    • getDispositionType

      String getDispositionType()
      Gets the disposition type defined in this Content-Disposition field.
      Returns:
      the disposition type or an empty string if not set.
    • getParameter

      String getParameter(String name)
      Gets the value of a parameter. Parameter names are case-insensitive.
      Parameters:
      name - the name of the parameter to get.
      Returns:
      the parameter value or null if not set.
    • getParameters

      Map<String,String> getParameters()
      Gets all parameters.
      Returns:
      the parameters.
    • isDispositionType

      boolean isDispositionType(String dispositionType)
      Determines if the disposition type of this field matches the given one.
      Parameters:
      dispositionType - the disposition type to match against.
      Returns:
      true if the disposition type of this field matches, false otherwise.
    • isInline

      boolean isInline()
      Return true if the disposition type of this field is inline, false otherwise.
      Returns:
      true if the disposition type of this field is inline, false otherwise.
    • isAttachment

      boolean isAttachment()
      Return true if the disposition type of this field is attachment, false otherwise.
      Returns:
      true if the disposition type of this field is attachment, false otherwise.
    • getFilename

      String getFilename()
      Gets the value of the filename parameter if set.
      Returns:
      the filename parameter value or null if not set.
    • getCreationDate

      Date getCreationDate()
      Gets the value of the creation-date parameter if set and valid.
      Returns:
      the creation-date parameter value or null if not set or invalid.
    • getModificationDate

      Date getModificationDate()
      Gets the value of the modification-date parameter if set and valid.
      Returns:
      the modification-date parameter value or null if not set or invalid.
    • getReadDate

      Date getReadDate()
      Gets the value of the read-date parameter if set and valid.
      Returns:
      the read-date parameter value or null if not set or invalid.
    • getSize

      long getSize()
      Gets the value of the size parameter if set and valid.
      Returns:
      the size parameter value or -1 if not set or invalid.