Package com.atlassian.confluence.it
Class Attachment
- java.lang.Object
 - 
- com.atlassian.confluence.it.Attachment
 
 
- 
- All Implemented Interfaces:
 LinkableContent,TitledContent,VersionedContent,ContentConvertible
@Deprecated public class Attachment extends Object implements TitledContent, LinkableContent, ContentConvertible, VersionedContent
Deprecated.Please use confluence-java-api module instead. See {com.atlassian.confluence.api.model.content.Content} alternative 
- 
- 
Nested Class Summary
Nested Classes Modifier and Type Class Description static classAttachment.AttachmentBuilderDeprecated.Builds anAttachmentobject 
- 
Field Summary
Fields Modifier and Type Field Description static StringGIF_TYPEDeprecated.static StringMOV_TYPEDeprecated.static StringPDF_TYPEDeprecated.static StringPNG_TYPEDeprecated.static StringSWF_TYPEDeprecated.static StringTEXT_TYPEDeprecated.static StringZIP_TYPEDeprecated. 
- 
Constructor Summary
Constructors Constructor Description Attachment(Attachment original, String versionComment, byte[] newData)Deprecated.Since 5.7.Attachment(ContentEntity contentEntity, Attachment other)Deprecated.Since 5.7.Attachment(ContentEntity contentEntity, File file, String contentType)Deprecated.Since 5.7.Attachment(ContentEntity contentEntity, String filename, String contentType, String classpathResource)Deprecated.Since 5.7.Attachment(ContentEntity contentEntity, String filename, String contentType, String comment, byte[] data)Deprecated.Since 5.7.Attachment(ContentEntity contentEntity, String filename, String contentType, String comment, byte[] data, boolean minorEdit)Deprecated.Since 5.7. 
- 
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description StringgetAbsoluteImageMarkup()Deprecated.Retrieves the wiki markup to embed this image from another page in another space.StringgetComment()Deprecated.ContentIdgetContentId()Deprecated.StringgetContentType()Deprecated.ContentTypegetContentTypeObject()Deprecated.byte[]getData()Deprecated.StringgetDownloadUrl()Deprecated.StringgetDownloadUrl(String contextPath)Deprecated.The application context without any slashes at all.StringgetEditUrl()Deprecated.StringgetEditUrl(boolean isFromPageView)Deprecated.LonggetFileId()Deprecated.StringgetFilename()Deprecated.longgetId()Deprecated.StringgetImageMarkup()Deprecated.Gets the wiki markup to insert this attachment, as an embedded imaged, on the page to which it's attached.StringgetImageXpath()Deprecated.Returns xpath that will match the an embedded image.ContentEntitygetPage()Deprecated.StringgetPlaceholderXpath()Deprecated.Returns xpath that will match the "unidentified attachment" placeholder for this image.ContentSelectorgetSelector()Deprecated.StringgetThumbnailMarkup()Deprecated.StringgetThumbnailUrl()Deprecated.StringgetTitle()Deprecated.StringgetUrl()Deprecated.UrlBuildergetUrlBuilder()Deprecated.intgetVersion()Deprecated.booleanisHidden()Deprecated.booleanisMinorEdit()Deprecated.voidsetFileId(Long fileId)Deprecated.voidsetId(long id)Deprecated.voidsetUrl(String url)Deprecated.voidsetVersion(int version)Deprecated.booleanshouldConvertToContent()Deprecated. 
 - 
 
- 
- 
Field Detail
- 
GIF_TYPE
public static final String GIF_TYPE
Deprecated.- See Also:
 - Constant Field Values
 
 
- 
PNG_TYPE
public static final String PNG_TYPE
Deprecated.- See Also:
 - Constant Field Values
 
 
- 
PDF_TYPE
public static final String PDF_TYPE
Deprecated.- See Also:
 - Constant Field Values
 
 
- 
TEXT_TYPE
public static final String TEXT_TYPE
Deprecated.- See Also:
 - Constant Field Values
 
 
- 
SWF_TYPE
public static final String SWF_TYPE
Deprecated.- See Also:
 - Constant Field Values
 
 
- 
MOV_TYPE
public static final String MOV_TYPE
Deprecated.- See Also:
 - Constant Field Values
 
 
- 
ZIP_TYPE
public static final String ZIP_TYPE
Deprecated.- See Also:
 - Constant Field Values
 
 
 - 
 
- 
Constructor Detail
- 
Attachment
@Deprecated public Attachment(ContentEntity contentEntity, String filename, String contentType, String comment, byte[] data, boolean minorEdit)
Deprecated.Since 5.7. UseinsteadCreates an Attachment object of an intended file.Example: Attachment attachment = new Attachment(TEST_PAGE, attachmentName, Attachment.TEXT_TYPE, "your upload comment", "foo".getBytes());
- Parameters:
 contentEntity- the page or blog where the attachment will residefilename- the attachment filecontentType- mime type of the attachmentcomment- comment associated with the attachment, which can be nulldata- byte array of the attachment contentminorEdit- whether the attachment is a minor edit
 
- 
Attachment
@Deprecated public Attachment(ContentEntity contentEntity, String filename, String contentType, String comment, byte[] data)
Deprecated.Since 5.7. Useinstead 
- 
Attachment
@Deprecated public Attachment(Attachment original, String versionComment, byte[] newData)
Deprecated.Since 5.7. Useinstead 
- 
Attachment
@Deprecated public Attachment(ContentEntity contentEntity, File file, String contentType)
Deprecated.Since 5.7. Useinstead 
- 
Attachment
@Deprecated public Attachment(ContentEntity contentEntity, String filename, String contentType, String classpathResource)
Deprecated.Since 5.7. Useinstead 
- 
Attachment
@Deprecated public Attachment(ContentEntity contentEntity, Attachment other)
Deprecated.Since 5.7. UseinsteadCopy constructor -- put the provided attachment on another page. 
 - 
 
- 
Method Detail
- 
getPage
public ContentEntity getPage()
Deprecated. 
- 
getFilename
public String getFilename()
Deprecated. 
- 
getContentType
public String getContentType()
Deprecated. 
- 
getContentTypeObject
public ContentType getContentTypeObject()
Deprecated.- Specified by:
 getContentTypeObjectin interfaceContentConvertible- Returns:
 - the api ContentType that this ContentConvertible converts to
 
 
- 
getComment
public String getComment()
Deprecated. 
- 
getId
public long getId()
Deprecated. 
- 
setId
public void setId(long id)
Deprecated. 
- 
setUrl
public void setUrl(String url)
Deprecated. 
- 
getData
public byte[] getData()
Deprecated. 
- 
getDownloadUrl
public String getDownloadUrl()
Deprecated. 
- 
getDownloadUrl
public String getDownloadUrl(String contextPath)
Deprecated.The application context without any slashes at all. Eg "confluence" 
- 
getThumbnailUrl
public String getThumbnailUrl()
Deprecated. 
- 
getEditUrl
public String getEditUrl()
Deprecated. 
- 
getEditUrl
public String getEditUrl(boolean isFromPageView)
Deprecated. 
- 
getImageMarkup
public String getImageMarkup()
Deprecated.Gets the wiki markup to insert this attachment, as an embedded imaged, on the page to which it's attached. 
- 
getAbsoluteImageMarkup
public String getAbsoluteImageMarkup()
Deprecated.Retrieves the wiki markup to embed this image from another page in another space. 
- 
getThumbnailMarkup
public String getThumbnailMarkup()
Deprecated. 
- 
getTitle
public String getTitle()
Deprecated.- Specified by:
 getTitlein interfaceTitledContent
 
- 
getUrl
public String getUrl()
Deprecated.- Specified by:
 getUrlin interfaceLinkableContent
 
- 
getUrlBuilder
public UrlBuilder getUrlBuilder()
Deprecated.- Specified by:
 getUrlBuilderin interfaceLinkableContent
 
- 
getPlaceholderXpath
public String getPlaceholderXpath()
Deprecated.Returns xpath that will match the "unidentified attachment" placeholder for this image. 
- 
getImageXpath
public String getImageXpath()
Deprecated.Returns xpath that will match the an embedded image. 
- 
getContentId
public ContentId getContentId()
Deprecated.- Specified by:
 getContentIdin interfaceContentConvertible- Returns:
 - the ContentId identifying this Content-convertible entity.
 
 
- 
getSelector
public ContentSelector getSelector()
Deprecated.- Specified by:
 getSelectorin interfaceContentConvertible- Returns:
 - the ContentSelector identifying this Content-convertible entity.
 
 
- 
shouldConvertToContent
public boolean shouldConvertToContent()
Deprecated.- Specified by:
 shouldConvertToContentin interfaceContentConvertible- Returns:
 - true if the implementer wants to be part of the core API (default value), false otherwise
 
 
- 
getVersion
public int getVersion()
Deprecated.- Specified by:
 getVersionin interfaceVersionedContent
 
- 
setVersion
public void setVersion(int version)
Deprecated.- Specified by:
 setVersionin interfaceVersionedContent
 
- 
isMinorEdit
public boolean isMinorEdit()
Deprecated.- Specified by:
 isMinorEditin interfaceVersionedContent
 
- 
isHidden
public boolean isHidden()
Deprecated. 
- 
getFileId
public Long getFileId()
Deprecated. 
- 
setFileId
public void setFileId(Long fileId)
Deprecated. 
 - 
 
 -