|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface AttachmentInfo
Contains information about a file to attach to a task.
Use the setType()
method to specify the type of attachment.
The default value is AttachmentInfo.TYPE_ATTACHMENT
.
TaskManager.addAttachment(long, com.adobe.idp.taskmanager.dsc.client.task.AttachmentInfo, java.io.InputStream)
Field Summary | |
---|---|
static java.lang.String |
ATTACH_CREATE_DATE
Document attribute that contains the attachment creation date when a list of documents is exported from the task. |
static java.lang.String |
ATTACH_CREATOR_ID
Document attribute that contains the attachment creator identifier when a list of documents is exported from the task. |
static java.lang.String |
ATTACH_DESC
Document attribute that contains the attachment description (or note content) when a list of documents is exported from the task. |
static java.lang.String |
ATTACH_FILENAME
Document attribute that contains the attachment file name when a list of documents is exported from the task. |
static java.lang.String |
ATTACH_PERM
Document attribute that contains the attachment permissions when a list of documents is exported from the task. |
static java.lang.String |
ATTACH_TYPE
Document attribute that contains the attachment type when a list of documents is exported from the task. |
static java.lang.String |
ATTACH_UPDATE_DATE
Document attribute that contains the attachment update date when a list of documents is exported from the task. |
static int |
PERMISSION_DELETE
A bit mask value containing the delete permission for the attachment. |
static int |
PERMISSION_READ
A bit mask value containing the read permission for the attachment. |
static int |
PERMISSION_WRITE
A bit mask value containing the permission for writing the attachment. |
static java.lang.String |
TYPE_ATTACHMENT
Indicates that this attachment is of an attachment type. |
static java.lang.String |
TYPE_NOTE
Indicates this attachment is a note type. |
Method Summary | |
---|---|
java.util.Date |
getCreateDate()
Retrieves the time stamp indicating when this attachment was created. |
java.lang.String |
getCreatorCommonName()
Retrieves the common name of the user who created this attachment. |
java.lang.String |
getCreatorId()
Retrieves the identifier of the user who created this attachment. |
java.lang.String |
getDescription()
Retrieves the description for this attachment. |
java.lang.String |
getFileName()
Retrieves the file name for this attachment. |
long |
getId()
Retrieves the identifier for this attachment. |
java.util.Date |
getLastModifiedDate()
Retrieves the time stamp indicating when this attachment was last updated. |
int |
getPermissions()
Retrieves the permissions for this attachment. |
long |
getSize()
Returns the file size, in bytes, of this attachment. |
java.lang.String |
getType()
Retrieves the type of the attachment. |
boolean |
isDeleteable()
Determines whether this attachment can be deleted. |
boolean |
isNoteExtended()
Determines whether a note attachment is longer than the contents of the description field. |
boolean |
isReadable()
Determines whether this attachment is readable. |
boolean |
isWriteable()
Determines whether this attachment is writeable. |
void |
setDescription(java.lang.String aDescription)
Sets the description for a new attachment. |
void |
setFileName(java.lang.String aFileName)
Sets the file name for this attachment. |
void |
setId(long aId)
Sets the identifier for this attachment. |
void |
setPermissions(int aPermissions)
Sets new permissions for this attachment. |
void |
setType(java.lang.String attachmentType)
Sets the type of the attachment. |
Field Detail |
---|
static final int PERMISSION_READ
static final int PERMISSION_WRITE
static final int PERMISSION_DELETE
static final java.lang.String ATTACH_FILENAME
static final java.lang.String ATTACH_PERM
static final java.lang.String ATTACH_DESC
static final java.lang.String ATTACH_CREATOR_ID
static final java.lang.String ATTACH_CREATE_DATE
static final java.lang.String ATTACH_UPDATE_DATE
static final java.lang.String ATTACH_TYPE
Its possible values are AttachmentInfo.TYPE_ATTACHMENT
and AttachmentInfo.TYPE_NOTE
.
static final java.lang.String TYPE_ATTACHMENT
static final java.lang.String TYPE_NOTE
Method Detail |
---|
long getId() throws UnknownValueException
UnknownValueException
- if the identifier has not been set.void setId(long aId)
aId
- The identifier for this attachment.java.lang.String getFileName() throws UnknownValueException
UnknownValueException
- if the name has not been set.void setFileName(java.lang.String aFileName)
aFileName
- The file name for this attachment.boolean isReadable() throws UnknownValueException
true
if this attachment can be read, false
otherwise.
UnknownValueException
- if the permissions of this attachment are unknown.boolean isWriteable() throws UnknownValueException
true
if this attachment can be updated, false
otherwise.
UnknownValueException
- if the permissions of this attachment are unknown.boolean isDeleteable() throws UnknownValueException
true
if this attachment can be deleted, false
otherwise.
UnknownValueException
- if the permissions of this attachment are unknown.int getPermissions() throws UnknownValueException
AttachmentInfo.PERMISSION_READ
, AttachmentInfo.PERMISSION_WRITE
, and AttachmentInfo.PERMISSION_DELETE
values.
UnknownValueException
- if the permissions for this attachment are unknown.void setPermissions(int aPermissions)
aPermissions
is a bit mask made up of AttachmentInfo.PERMISSION_READ
(001
),
AttachmentInfo.PERMISSION_WRITE
(010
), and AttachmentInfo.PERMISSION_DELETE
values (100
).
Therefore, read and write permissions would correspond to a value of 011
; read,
write, and delete permissions would correspond to a value of 111
.
aPermissions
- The new permissions for this attachment.long getSize() throws UnknownValueException
UnknownValueException
- if the file size is not known.java.util.Date getLastModifiedDate() throws UnknownValueException
UnknownValueException
- if the last modified date is not known.java.lang.String getDescription() throws UnknownValueException
UnknownValueException
void setDescription(java.lang.String aDescription) throws UnknownValueException
aDescription
- The description for the attachment.
UnknownValueException
java.lang.String getCreatorId() throws UnknownValueException
UnknownValueException
java.lang.String getCreatorCommonName() throws UnknownValueException
UnknownValueException
java.util.Date getCreateDate()
java.lang.String getType()
AttachmentInfo.TYPE_ATTACHMENT
and AttachmentInfo.TYPE_NOTE
.
String
indicating the type of the attachment (attachment or note).void setType(java.lang.String attachmentType) throws UnknownValueException
AttachmentInfo.TYPE_ATTACHMENT
and AttachmentInfo.TYPE_NOTE
.
attachmentType
- The type of attachment.
UnknownValueException
- if the type being set does not match one of the possible values.boolean isNoteExtended()
If true
, only a part of the note can be viewed from the description field, and the full note contents
can only be seen by returning the note contents.
true
if the note attachment of type note is longer than the description field, false
otherwise.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |