Package com.smartsheet.api.models
Class Attachment
- java.lang.Object
-
- com.smartsheet.api.models.IdentifiableModel<T>
-
- com.smartsheet.api.models.NamedModel<java.lang.Long>
-
- com.smartsheet.api.models.Attachment
-
public class Attachment extends NamedModel<java.lang.Long>
Represents the Attachment object.- See Also:
- Help Uploading Attachments
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classAttachment.CreateAttachmentBuilderA convenience class for quickly creating a List of cells to update.
-
Constructor Summary
Constructors Constructor Description Attachment()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description AttachmentSubTypegetAttachmentSubType()Gets the attachment sub type.AttachmentTypegetAttachmentType()Gets the attachment type.java.util.DategetCreatedAt()Gets the created at.UsergetCreatedBy()java.lang.StringgetDescription()Gets the attachment description.java.lang.StringgetMimeType()Gets the mime type.java.lang.LonggetParentId()Gets the parent id.AttachmentParentTypegetParentType()Gets the parent type.java.lang.LonggetSizeInKb()Gets the size in kb.java.lang.StringgetUrl()Gets the URL.java.lang.LonggetUrlExpiresInMillis()Gets the url expires in millis.AttachmentsetAttachmentSubType(AttachmentSubType attachmentSubType)Sets the attachment sub type.AttachmentsetAttachmentType(AttachmentType attachmentType)Sets the attachment type.AttachmentsetCreatedAt(java.util.Date createdAt)Sets the created at.AttachmentsetCreatedBy(User createdBy)AttachmentsetDescription(java.lang.String description)Sets the attachment description.AttachmentsetMimeType(java.lang.String mimeType)Sets the mime type.AttachmentsetName(java.lang.String name)Provide an 'override' of setName (returns Attachment not NamedModel)AttachmentsetParentId(java.lang.Long parentId)Sets the parent id.AttachmentsetParentType(AttachmentParentType parentType)Sets the parent type.AttachmentsetSizeInKb(java.lang.Long sizeInKb)Sets the size in kb.AttachmentsetUrl(java.lang.String url)Sets the URL.AttachmentsetUrlExpiresInMillis(java.lang.Long urlExpiresInMillis)Sets the url expires in millis.-
Methods inherited from class com.smartsheet.api.models.NamedModel
getName
-
Methods inherited from class com.smartsheet.api.models.IdentifiableModel
equals, getId, hashCode, setId
-
-
-
-
Method Detail
-
setName
public Attachment setName(java.lang.String name)
Provide an 'override' of setName (returns Attachment not NamedModel)- Overrides:
setNamein classNamedModel<java.lang.Long>- Parameters:
name- the new name
-
getUrl
public java.lang.String getUrl()
Gets the URL.- Returns:
- The url.
-
setUrl
public Attachment setUrl(java.lang.String url)
Sets the URL.- Parameters:
url- the new url
-
getUrlExpiresInMillis
public java.lang.Long getUrlExpiresInMillis()
Gets the url expires in millis.- Returns:
- the url expires in millis
-
setUrlExpiresInMillis
public Attachment setUrlExpiresInMillis(java.lang.Long urlExpiresInMillis)
Sets the url expires in millis.- Parameters:
urlExpiresInMillis- the new url expires in millis
-
getAttachmentType
public AttachmentType getAttachmentType()
Gets the attachment type.- Returns:
- the attachment type
-
setAttachmentType
public Attachment setAttachmentType(AttachmentType attachmentType)
Sets the attachment type.- Parameters:
attachmentType- the new attachment type
-
getAttachmentSubType
public AttachmentSubType getAttachmentSubType()
Gets the attachment sub type.- Returns:
- the attachment sub type
-
setAttachmentSubType
public Attachment setAttachmentSubType(AttachmentSubType attachmentSubType)
Sets the attachment sub type.- Parameters:
attachmentSubType- the new attachment sub type
-
getCreatedAt
public java.util.Date getCreatedAt()
Gets the created at.- Returns:
- the created at
-
setCreatedAt
public Attachment setCreatedAt(java.util.Date createdAt)
Sets the created at.- Parameters:
createdAt- the new created at
-
getMimeType
public java.lang.String getMimeType()
Gets the mime type.- Returns:
- the mime type
-
setMimeType
public Attachment setMimeType(java.lang.String mimeType)
Sets the mime type.- Parameters:
mimeType- the new mime type
-
getParentType
public AttachmentParentType getParentType()
Gets the parent type.- Returns:
- the parent type
-
setParentType
public Attachment setParentType(AttachmentParentType parentType)
Sets the parent type.- Parameters:
parentType- the new parent type
-
getParentId
public java.lang.Long getParentId()
Gets the parent id.- Returns:
- the parent id
-
setParentId
public Attachment setParentId(java.lang.Long parentId)
Sets the parent id.- Parameters:
parentId- the new parent id
-
getSizeInKb
public java.lang.Long getSizeInKb()
Gets the size in kb.- Returns:
- the size in kb
-
setSizeInKb
public Attachment setSizeInKb(java.lang.Long sizeInKb)
Sets the size in kb.- Parameters:
sizeInKb- the new size in kb
-
getCreatedBy
public User getCreatedBy()
- Returns:
- the createdBy
-
setCreatedBy
public Attachment setCreatedBy(User createdBy)
- Parameters:
createdBy- the createdBy to set
-
getDescription
public java.lang.String getDescription()
Gets the attachment description.- Returns:
- the attachment description.
-
setDescription
public Attachment setDescription(java.lang.String description)
Sets the attachment description.- Parameters:
description- the description
-
-