Package org.silverpeas.components.quickinfo.model

# Class News

java.lang.Object
org.silverpeas.core.persistence.datasource.model.jpa.AbstractJpaEntity<E,I>
org.silverpeas.core.persistence.datasource.model.jpa.SilverpeasJpaEntity<News,org.silverpeas.core.persistence.datasource.model.identifier.UuidIdentifier>
org.silverpeas.components.quickinfo.model.News

All Implemented Interfaces:
  `Serializable`, `org.silverpeas.core.contribution.model.Contribution`, `org.silverpeas.core.contribution.model.SilverpeasContent`, `org.silverpeas.core.contribution.model.WithAttachment`, `org.silverpeas.core.contribution.model.WithPermanentLink`, `org.silverpeas.core.contribution.model.WithThumbnail`, `org.silverpeas.core.Identifiable`, `org.silverpeas.core.Instance<org.silverpeas.core.contribution.model.Contribution>`, `org.silverpeas.core.Nameable`, `org.silverpeas.core.persistence.datasource.model.Entity<News,org.silverpeas.core.persistence.datasource.model.identifier.UuidIdentifier>`, `org.silverpeas.core.persistence.datasource.model.IdentifiableEntity`, `org.silverpeas.core.reminder.WithReminder`, `org.silverpeas.core.security.Securable`, `org.silverpeas.core.SilverpeasResource`

@Entity public class News extends org.silverpeas.core.persistence.datasource.model.jpa.SilverpeasJpaEntity<News,org.silverpeas.core.persistence.datasource.model.identifier.UuidIdentifier> implements org.silverpeas.core.contribution.model.SilverpeasContent, org.silverpeas.core.contribution.model.WithAttachment, org.silverpeas.core.contribution.model.WithThumbnail, org.silverpeas.core.reminder.WithReminder, org.silverpeas.core.contribution.model.WithPermanentLink

See Also:
  - Serialized Form

- ## Nested Class Summary

  Nested Classes
  Modifier and Type
  Class
  Description
  `static class`
  `News.Builder`
  A builder of a `News` instance by setting some of its properties.

- ## Field Summary

  Fields
  Modifier and Type
  Field
  Description
  `static final String`
  `CONTRIBUTION_TYPE`

- ## Constructor Summary

  Constructors
  Modifier
  Constructor
  Description
  `protected`
  `News()`
  ``
  `News(org.silverpeas.core.contribution.publication.model.PublicationDetail publication)`

- ## Method Summary

  Modifier and Type
  Method
  Description
  `static News.Builder`
  `builder()`
  Gets a builder of `News` instances.
  `static News.Builder`
  `builder(News news)`
  Gets a builder of `News` instances from data of another one.
  `boolean`
  `equals(Object obj)`
  `List<Integer>`
  `getBroadcastModes()`
  `String`
  `getComponentInstanceId()`
  Gets the identifier of the component instance which the news is attached.
  `String`
  `getContent()`
  `String`
  `getContentToStore()`
  `String`
  `getContributionType()`
  `DelegatedNews`
  `getDelegatedNews()`
  `String`
  `getDescription()`
  `protected org.silverpeas.core.contribution.publication.model.PublicationPK`
  `getForeignPK()`
  `org.silverpeas.core.contribution.model.ContributionIdentifier`
  `getIdentifier()`
  `String`
  `getKeywords()`
  `org.silverpeas.core.contribution.model.ContributionModel`
  `getModel()`
  `int`
  `getNbAccess()`
  `int`
  `getNumberOfAttachments()`
  `int`
  `getNumberOfComments()`
  `Date`
  `getOnlineDate()`
  `String`
  `getPermalink()`
  `NewsPK`
  `getPK()`
  `org.silverpeas.core.contribution.publication.model.PublicationDetail`
  `getPublication()`
  `String`
  `getPublicationId()`
  `Date`
  `getPublishDate()`
  `String`
  `getPublishedBy()`
  `Optional<org.silverpeas.core.contribution.publication.model.PublicationPath>`
  `getResourcePath()`
  `static String`
  `getResourceType()`
  The type of this resource
  `String`
  `getSilverpeasContentId()`
  `List<org.silverpeas.core.pdc.pdc.model.ClassifyPosition>`
  `getTaxonomyPositions()`
  `org.silverpeas.core.contribution.model.Thumbnail`
  `getThumbnail()`
  `String`
  `getTitle()`
  `Date`
  `getUpdateDate()`
  `String`
  `getUpdaterId()`
  `org.silverpeas.core.contribution.ContributionVisibility`
  `getVisibility()`
  `int`
  `hashCode()`
  `boolean`
  `isCanBeSubmittedOnHomepage()`
  `boolean`
  `isDraft()`
  `boolean`
  `isImportant()`
  `boolean`
  `isIndexable()`
  `boolean`
  `isMandatory()`
  `boolean`
  `isNoMoreVisible()`
  `boolean`
  `isNotYetVisible()`
  `boolean`
  `isTicker()`
  `boolean`
  `isUpdatedAfterBePublished()`
  `boolean`
  `isVisible()`
  `void`
  `setComponentInstanceId(String componentId)`
  `void`
  `setContentToStore(String content)`
  `void`
  `setCreatorId(String userId)`
  `void`
  `setDelegatedNews(DelegatedNews dn)`
  `void`
  `setDescription(String desc)`
  `void`
  `setDraft()`
  `News`
  `setId(String id)`
  `void`
  `setImportant(boolean important)`
  `void`
  `setKeywords(String keywords)`
  `void`
  `setMandatory(boolean mandatory)`
  `protected void`
  `setPublication(org.silverpeas.core.contribution.publication.model.PublicationDetail publication)`
  `void`
  `setPublicationId(String publicationId)`
  `void`
  `setPublishDate(Date publishDate)`
  `void`
  `setPublished()`
  `void`
  `setPublishedBy(String publishedBy)`
  `void`
  `setTicker(boolean ticker)`
  `void`
  `setTitle(String title)`
  `void`
  `setUpdaterId(String userId)`
  `void`
  `setVisibilityPeriod(org.silverpeas.core.date.Period period)`

  ### Methods inherited from class org.silverpeas.core.persistence.datasource.model.jpa.SilverpeasJpaEntity

  `createdBy, createdBy, createdBy, getCreationDate, getCreator, getCreatorId, getLastUpdateDate, getLastUpdater, getLastUpdaterId, getVersion, hasBeenModified, lastUpdatedBy, markAsModified, performBeforePersist, performBeforeRemove, performBeforeUpdate, setCreationDate, setCreator, setLastUpdateDate, setLastUpdater, setVersion, updatedBy, updatedBy`

  ### Methods inherited from class org.silverpeas.core.persistence.datasource.model.jpa.AbstractJpaEntity

  `getId, getNativeId, isPersisted`

  ### Methods inherited from class java.lang.Object

  `clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait`

  ### Methods inherited from interface org.silverpeas.core.contribution.model.Contribution

  `canBeAccessedBy, getName`

  ### Methods inherited from interface org.silverpeas.core.persistence.datasource.model.IdentifiableEntity

  `getId, isPersisted`

  ### Methods inherited from interface org.silverpeas.core.Instance

  `getParent`

  ### Methods inherited from interface org.silverpeas.core.security.Securable

  `canBeDeletedBy, canBeFiledInBy, canBeModifiedBy`

  ### Methods inherited from interface org.silverpeas.core.contribution.model.SilverpeasContent

  `getId`

  ### Methods inherited from interface org.silverpeas.core.SilverpeasResource

  `getCreationDate, getCreator, getLastUpdateDate, getLastUpdater`

- ## Field Details

  - ### CONTRIBUTION_TYPE

    public static final String CONTRIBUTION_TYPE
    See Also:
      - Constant Field Values

- ## Constructor Details

  - ### News

    protected News()

  - ### News

    public News(org.silverpeas.core.contribution.publication.model.PublicationDetail publication)

- ## Method Details

  - ### builder

    public static News.Builder builder()
    Gets a builder of `News` instances.
    Returns:
      a `News.Builder` instance

  - ### builder

    public static News.Builder builder(News news)
    Gets a builder of `News` instances from data of another one.
    Parameters:
      `news` - the news data to initialize with.
    Returns:
      a `News.Builder` instance

  - ### getPK

    public NewsPK getPK()

  - ### getPublication

    public org.silverpeas.core.contribution.publication.model.PublicationDetail getPublication()

  - ### setId

    public News setId(String id)
    Overrides:
      `setId` in class `org.silverpeas.core.persistence.datasource.model.jpa.AbstractJpaEntity<News,org.silverpeas.core.persistence.datasource.model.identifier.UuidIdentifier>`

  - ### getTitle

    public String getTitle()
    Specified by:
      `getTitle` in interface `org.silverpeas.core.contribution.model.Contribution`

  - ### setTitle

    public void setTitle(String title)

  - ### getDescription

    public String getDescription()
    Specified by:
      `getDescription` in interface `org.silverpeas.core.contribution.model.Contribution`
    Specified by:
      `getDescription` in interface `org.silverpeas.core.Nameable`

  - ### setKeywords

    public void setKeywords(String keywords)

  - ### getKeywords

    public String getKeywords()

  - ### setDescription

    public void setDescription(String desc)

  - ### setCreatorId

    public void setCreatorId(String userId)

  - ### setUpdaterId

    public void setUpdaterId(String userId)

  - ### getUpdaterId

    public String getUpdaterId()

  - ### getUpdateDate

    public Date getUpdateDate()

  - ### isVisible

    public boolean isVisible()

  - ### isNoMoreVisible

    public boolean isNoMoreVisible()

  - ### isNotYetVisible

    public boolean isNotYetVisible()

  - ### setVisibilityPeriod

    public void setVisibilityPeriod(org.silverpeas.core.date.Period period)

  - ### getVisibility

    public org.silverpeas.core.contribution.ContributionVisibility getVisibility()

  - ### setContentToStore

    public void setContentToStore(String content)

  - ### getContentToStore

    public String getContentToStore()

  - ### getContent

    public String getContent()

  - ### getBroadcastModes

    public List<Integer> getBroadcastModes()

  - ### getThumbnail

    public org.silverpeas.core.contribution.model.Thumbnail getThumbnail()
    Specified by:
      `getThumbnail` in interface `org.silverpeas.core.contribution.model.WithThumbnail`

  - ### getNumberOfComments

    public int getNumberOfComments()

  - ### getComponentInstanceId

    public String getComponentInstanceId()
    Gets the identifier of the component instance which the news is attached.
    Specified by:
      `getComponentInstanceId` in interface `org.silverpeas.core.contribution.model.SilverpeasContent`
    Returns:
      the identifier of the component instance which the news is attached.

  - ### setComponentInstanceId

    public void setComponentInstanceId(String componentId)

  - ### getSilverpeasContentId

    public String getSilverpeasContentId()
    Specified by:
      `getSilverpeasContentId` in interface `org.silverpeas.core.contribution.model.SilverpeasContent`

  - ### getIdentifier

    public org.silverpeas.core.contribution.model.ContributionIdentifier getIdentifier()
    Specified by:
      `getIdentifier` in interface `org.silverpeas.core.contribution.model.Contribution`
    Specified by:
      `getIdentifier` in interface `org.silverpeas.core.contribution.model.SilverpeasContent`
    Specified by:
      `getIdentifier` in interface `org.silverpeas.core.SilverpeasResource`

  - ### getContributionType

    public String getContributionType()
    Specified by:
      `getContributionType` in interface `org.silverpeas.core.contribution.model.Contribution`

  - ### isIndexable

    public boolean isIndexable()
    Specified by:
      `isIndexable` in interface `org.silverpeas.core.contribution.model.Contribution`

  - ### getResourceType

    public static String getResourceType()
    The type of this resource
    Returns:
      the same value returned by getContributionType()

  - ### getResourcePath

    public Optional<org.silverpeas.core.contribution.publication.model.PublicationPath> getResourcePath()
    Specified by:
      `getResourcePath` in interface `org.silverpeas.core.contribution.model.Contribution`

  - ### setImportant

    public void setImportant(boolean important)

  - ### isImportant

    public boolean isImportant()

  - ### setTicker

    public void setTicker(boolean ticker)

  - ### isTicker

    public boolean isTicker()

  - ### setMandatory

    public void setMandatory(boolean mandatory)

  - ### isMandatory

    public boolean isMandatory()

  - ### setPublicationId

    public void setPublicationId(String publicationId)

  - ### getPublicationId

    public String getPublicationId()

  - ### getNbAccess

    public int getNbAccess()

  - ### isDraft

    public boolean isDraft()

  - ### setDraft

    public void setDraft()

  - ### setPublished

    public void setPublished()

  - ### getTaxonomyPositions

    public List<org.silverpeas.core.pdc.pdc.model.ClassifyPosition> getTaxonomyPositions() throws org.silverpeas.core.pdc.pdc.model.PdcException
    Throws:
      `org.silverpeas.core.pdc.pdc.model.PdcException`

  - ### getPermalink

    public String getPermalink()
    Specified by:
      `getPermalink` in interface `org.silverpeas.core.contribution.model.WithPermanentLink`

  - ### setPublishDate

    public void setPublishDate(Date publishDate)

  - ### getPublishDate

    public Date getPublishDate()

  - ### setPublishedBy

    public void setPublishedBy(String publishedBy)

  - ### getPublishedBy

    public String getPublishedBy()

  - ### isUpdatedAfterBePublished

    public boolean isUpdatedAfterBePublished()

  - ### getDelegatedNews

    public DelegatedNews getDelegatedNews()

  - ### setDelegatedNews

    public void setDelegatedNews(DelegatedNews dn)

  - ### isCanBeSubmittedOnHomepage

    public boolean isCanBeSubmittedOnHomepage()

  - ### getOnlineDate

    public Date getOnlineDate()

  - ### getNumberOfAttachments

    public int getNumberOfAttachments()

  - ### setPublication

    protected void setPublication(org.silverpeas.core.contribution.publication.model.PublicationDetail publication)

  - ### getForeignPK

    protected org.silverpeas.core.contribution.publication.model.PublicationPK getForeignPK()

  - ### hashCode

    public int hashCode()
    Overrides:
      `hashCode` in class `org.silverpeas.core.persistence.datasource.model.jpa.SilverpeasJpaEntity<News,org.silverpeas.core.persistence.datasource.model.identifier.UuidIdentifier>`

  - ### equals

    public boolean equals(Object obj)
    Overrides:
      `equals` in class `org.silverpeas.core.persistence.datasource.model.jpa.SilverpeasJpaEntity<News,org.silverpeas.core.persistence.datasource.model.identifier.UuidIdentifier>`

  - ### getModel

    public org.silverpeas.core.contribution.model.ContributionModel getModel()
    Specified by:
      `getModel` in interface `org.silverpeas.core.contribution.model.Contribution`