Class TemporaryWebAttachment

java.lang.Object
com.atlassian.jira.issue.attachment.TemporaryWebAttachment

@Immutable @ParametersAreNonnullByDefault public class TemporaryWebAttachment extends Object
Represents temporary attachment uploaded by user which may be later converted into a real attachment.
Since:
v6.4
  • Constructor Details

    • TemporaryWebAttachment

      public TemporaryWebAttachment(TemporaryAttachmentId temporaryAttachmentId, String filename, String contentType, String formToken, long size, org.joda.time.DateTime created)
  • Method Details

    • getTemporaryAttachmentId

      public TemporaryAttachmentId getTemporaryAttachmentId()
    • getStringId

      public String getStringId()
    • getFilename

      public String getFilename()
    • getContentType

      public String getContentType()
    • getContentType

      public String getContentType(boolean stripParams)
      ContentType header might include extra parameters (the part starts with a semicolon). See https://www.w3.org/Protocols/rfc1341/4_Content-Type.html for more detail. For certain use like QTempAttachmentsMonitor we don't need these extra params. The column that stores the value has a limit of 255 characters. See https://jira.atlassian.com/browse/JSDCLOUD-5477
      Parameters:
      stripParams - whether to cut the value after type + subtype
      Returns:
      value of Content-Type header field.
      Since:
      v7.5.0
    • getFormToken

      public String getFormToken()
    • getSize

      public long getSize()
    • getCreated

      public org.joda.time.DateTime getCreated()
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • equals

      public boolean equals(@Nullable Object obj)
      Overrides:
      equals in class Object
    • toString

      public String toString()
      Overrides:
      toString in class Object