Class PublicationEntity
- java.lang.Object
-
- org.silverpeas.core.webapi.publication.PublicationEntity
-
- All Implemented Interfaces:
Serializable
,WebEntity
public class PublicationEntity extends Object implements WebEntity
Web entity representing a publication that can be serialized into a given media type (JSON, XML).- See Also:
- Serialized Form
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static PublicationEntity
fromPublicationDetail(PublicationDetail publication, URI uri)
Creates a new publication entity from the specified publication.protected List<AttachmentEntity>
getAttachments()
String
getComponentId()
Gets the identifier of the Silverpeas component instance which the publication belongs to.String
getDescription()
String
getId()
Gets the unique identifier of the publication.int
getImportance()
String
getKeywords()
String
getName()
Date
getUpdateDate()
URI
getURI()
Gets the URI at which this web entity is published and can be accessed.protected void
setAttachments(List<AttachmentEntity> attachments)
void
setCreator(UserDetail user)
void
setDescription(String description)
void
setImportance(int importance)
void
setKeywords(String keywords)
void
setName(String name)
void
setUpdateDate(Date updateDate)
void
setUri(URI uri)
PublicationDetail
toPublicationDetail()
PublicationEntity
withAttachments(Collection<SimpleDocument> attachmentDetails)
PublicationEntity
withSharedContent(SharingContext context)
-
-
-
Method Detail
-
getURI
public URI getURI()
Description copied from interface:WebEntity
Gets the URI at which this web entity is published and can be accessed.
-
getId
public String getId()
Gets the unique identifier of the publication.- Returns:
- the publication identifier.
-
getComponentId
public String getComponentId()
Gets the identifier of the Silverpeas component instance which the publication belongs to.- Returns:
- the silverpeas component instance identifier.
-
fromPublicationDetail
public static PublicationEntity fromPublicationDetail(PublicationDetail publication, URI uri)
Creates a new publication entity from the specified publication.- Parameters:
publication
- the publication to entitify.
-
withAttachments
public PublicationEntity withAttachments(Collection<SimpleDocument> attachmentDetails)
-
withSharedContent
public PublicationEntity withSharedContent(SharingContext context)
-
setUri
public void setUri(URI uri)
-
setName
public void setName(String name)
-
getName
public String getName()
-
setDescription
public void setDescription(String description)
-
getDescription
public String getDescription()
-
setKeywords
public void setKeywords(String keywords)
-
getKeywords
public String getKeywords()
-
getImportance
public int getImportance()
-
setImportance
public void setImportance(int importance)
-
setUpdateDate
public void setUpdateDate(Date updateDate)
-
getUpdateDate
public Date getUpdateDate()
-
setCreator
public void setCreator(UserDetail user)
-
setAttachments
protected void setAttachments(List<AttachmentEntity> attachments)
-
getAttachments
protected List<AttachmentEntity> getAttachments()
-
toPublicationDetail
public PublicationDetail toPublicationDetail()
-
-