org.camunda.bpm.engine.impl.persistence.entity
Class AttachmentEntity

java.lang.Object
  extended by org.camunda.bpm.engine.impl.persistence.entity.AttachmentEntity
All Implemented Interfaces:
Serializable, HasRevision, PersistentObject, Attachment

public class AttachmentEntity
extends Object
implements Attachment, PersistentObject, HasRevision, Serializable

Author:
Tom Baeyens
See Also:
Serialized Form

Field Summary
protected  ByteArrayEntity content
           
protected  String contentId
           
protected  String description
           
protected  String id
           
protected  String name
           
protected  String processInstanceId
           
protected  int revision
           
protected  String taskId
           
protected  String type
           
protected  String url
           
 
Constructor Summary
AttachmentEntity()
           
 
Method Summary
 ByteArrayEntity getContent()
           
 String getContentId()
           
 String getDescription()
          long (max 255 chars) explanation what this attachment is about in context of the task and/or process instance it's linked to.
 String getId()
          unique id for this attachment
 String getName()
          free user defined short (max 255 chars) name for this attachment
 Object getPersistentState()
          Returns a representation of the object, as would be stored in the database.
 String getProcessInstanceId()
          reference to the process instance to which this attachment is associated.
 int getRevision()
           
 int getRevisionNext()
           
 String getTaskId()
          reference to the task to which this attachment is associated.
 String getType()
          indication of the type of content that this attachment refers to.
 String getUrl()
          the remote URL in case this is remote content.
 void setContent(ByteArrayEntity content)
           
 void setContentId(String contentId)
           
 void setDescription(String description)
          long (max 255 chars) explanation what this attachment is about in context of the task and/or process instance it's linked to.
 void setId(String id)
           
 void setName(String name)
          free user defined short (max 255 chars) name for this attachment
 void setProcessInstanceId(String processInstanceId)
           
 void setRevision(int revision)
           
 void setTaskId(String taskId)
           
 void setType(String type)
           
 void setUrl(String url)
           
 String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

id

protected String id

revision

protected int revision

name

protected String name

description

protected String description

type

protected String type

taskId

protected String taskId

processInstanceId

protected String processInstanceId

url

protected String url

contentId

protected String contentId

content

protected ByteArrayEntity content
Constructor Detail

AttachmentEntity

public AttachmentEntity()
Method Detail

getPersistentState

public Object getPersistentState()
Description copied from interface: PersistentObject
Returns a representation of the object, as would be stored in the database. Used when deciding if updates have occurred to the object or not since it was last loaded.

Specified by:
getPersistentState in interface PersistentObject

getRevisionNext

public int getRevisionNext()
Specified by:
getRevisionNext in interface HasRevision

getId

public String getId()
Description copied from interface: Attachment
unique id for this attachment

Specified by:
getId in interface PersistentObject
Specified by:
getId in interface Attachment

setId

public void setId(String id)
Specified by:
setId in interface PersistentObject

getRevision

public int getRevision()
Specified by:
getRevision in interface HasRevision

setRevision

public void setRevision(int revision)
Specified by:
setRevision in interface HasRevision

getName

public String getName()
Description copied from interface: Attachment
free user defined short (max 255 chars) name for this attachment

Specified by:
getName in interface Attachment

setName

public void setName(String name)
Description copied from interface: Attachment
free user defined short (max 255 chars) name for this attachment

Specified by:
setName in interface Attachment

getDescription

public String getDescription()
Description copied from interface: Attachment
long (max 255 chars) explanation what this attachment is about in context of the task and/or process instance it's linked to.

Specified by:
getDescription in interface Attachment

setDescription

public void setDescription(String description)
Description copied from interface: Attachment
long (max 255 chars) explanation what this attachment is about in context of the task and/or process instance it's linked to.

Specified by:
setDescription in interface Attachment

getType

public String getType()
Description copied from interface: Attachment
indication of the type of content that this attachment refers to. Can be mime type or any other indication.

Specified by:
getType in interface Attachment

setType

public void setType(String type)

getTaskId

public String getTaskId()
Description copied from interface: Attachment
reference to the task to which this attachment is associated.

Specified by:
getTaskId in interface Attachment

setTaskId

public void setTaskId(String taskId)

getProcessInstanceId

public String getProcessInstanceId()
Description copied from interface: Attachment
reference to the process instance to which this attachment is associated.

Specified by:
getProcessInstanceId in interface Attachment

setProcessInstanceId

public void setProcessInstanceId(String processInstanceId)

getUrl

public String getUrl()
Description copied from interface: Attachment
the remote URL in case this is remote content. If the attachment content was uploaded with an input stream, then this method returns null and the content can be fetched with TaskService.getAttachmentContent(String).

Specified by:
getUrl in interface Attachment

setUrl

public void setUrl(String url)

getContentId

public String getContentId()

setContentId

public void setContentId(String contentId)

getContent

public ByteArrayEntity getContent()

setContent

public void setContent(ByteArrayEntity content)

toString

public String toString()
Overrides:
toString in class Object


Copyright © 2014 camunda services GmbH. All Rights Reserved.