Interface ContentDispositionField

    • Field Detail

      • DISPOSITION_TYPE_INLINE

        static final java.lang.String DISPOSITION_TYPE_INLINE
        The inline disposition type.
        See Also:
        Constant Field Values
      • DISPOSITION_TYPE_ATTACHMENT

        static final java.lang.String DISPOSITION_TYPE_ATTACHMENT
        The attachment disposition type.
        See Also:
        Constant Field Values
      • PARAM_FILENAME

        static final java.lang.String PARAM_FILENAME
        The name of the filename parameter.
        See Also:
        Constant Field Values
      • PARAM_CREATION_DATE

        static final java.lang.String PARAM_CREATION_DATE
        The name of the creation-date parameter.
        See Also:
        Constant Field Values
      • PARAM_MODIFICATION_DATE

        static final java.lang.String PARAM_MODIFICATION_DATE
        The name of the modification-date parameter.
        See Also:
        Constant Field Values
      • PARAM_READ_DATE

        static final java.lang.String PARAM_READ_DATE
        The name of the read-date parameter.
        See Also:
        Constant Field Values
      • PARAM_SIZE

        static final java.lang.String PARAM_SIZE
        The name of the size parameter.
        See Also:
        Constant Field Values
    • Method Detail

      • getDispositionType

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

        java.lang.String getParameter​(java.lang.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

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

        boolean isDispositionType​(java.lang.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

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

        java.util.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

        java.util.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

        java.util.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.