public class PublishingService extends Object
| Modifier and Type | Method and Description |
|---|---|
void |
assign(int nDocumentId,
int nPortletId)
Assign
Document to a Portlet |
void |
changeDocumentOrder(int nDocumentId,
int nPortletId,
int nNewOrder)
Change the
Document order in a Portlet |
Collection<Document> |
getAssignedDocumentsByPortletId(int nPortletId)
Returns a
Collection of Document objects from a Portlet identifier
Document can be assigned or published. |
DocumentPublication |
getDocumentPublication(int nPortletId,
int nDocumentId)
|
Document |
getFirstValidPublishedDocument(int nPortletId)
Get the first valid document published in a portlet or null if there are none
|
static PublishingService |
getInstance()
Get the unique instance of the service
|
int |
getMaxDocumentOrderByPortletId(int nPortletId)
Get the max document order from a
Portlet id |
Collection<fr.paris.lutece.portal.business.portlet.Portlet> |
getPortletsByDocumentId(String strDocumentId)
Loads the list of the portlets whoes contain Document specified by id
|
Collection<Document> |
getPublishedDocumentsByPortletId(int nPortletId)
Loads the list of the documents whose type is the same as the one specified in parameter
Return published documents from a specified portlet
|
Collection<Document> |
getPublishedDocumentsSinceDate(Date datePublishing,
DocumentFilter documentFilter,
Locale locale)
Loads the list of the documents whose filter and date publication is specified
Return published documents since the publication date.
|
Collection<fr.paris.lutece.portal.business.portlet.Portlet> |
getPublishedPortlets()
Loads the list of portlets who contain published documents
|
boolean |
isAssigned(int nDocumentId)
Check if the specified
Document is assigned (unpublished or published) into at least one Portlet |
boolean |
isAssigned(int nDocumentId,
int nPortletId)
Check if the specified
Document is assigned (unpublished or published) into the specified Portlet |
boolean |
isPublished(int nDocumentId)
Check if the specified
Document is published into the specified Portlet |
boolean |
isPublished(int nDocumentId,
int nPortletId)
Check if the specified
Document is published into the specified Portlet |
void |
publish(int nDocumentId,
int nPortletId)
Publishing documents assigned to a portlet at the begin of the list
|
void |
unAssign(int nDocumentId,
int nPortletId)
unAssign
Document to a Portlet |
void |
unPublish(int nDocumentId,
int nPortletId)
UnPublishing documents assigned to a portlet
|
public static PublishingService getInstance()
public void assign(int nDocumentId,
int nPortletId)
Document to a PortletnDocumentId - The Document identifiernPortletId - The Portlet identifierpublic void publish(int nDocumentId,
int nPortletId)
nDocumentId - the Document idnPortletId - the portlet identifierpublic void unPublish(int nDocumentId,
int nPortletId)
nDocumentId - the DocumentListPortlet identifiernPortletId - the portlet identifierpublic void unAssign(int nDocumentId,
int nPortletId)
Document to a PortletnDocumentId - The Document identifiernPortletId - The Portlet identifierpublic void changeDocumentOrder(int nDocumentId,
int nPortletId,
int nNewOrder)
Document order in a PortletnDocumentId - the Document identifiernPortletId - the Portlet identifiernNewOrder - The new place in the listpublic boolean isPublished(int nDocumentId,
int nPortletId)
Document is published into the specified Portletpublic boolean isPublished(int nDocumentId)
Document is published into the specified Portletpublic boolean isAssigned(int nDocumentId)
Document is assigned (unpublished or published) into at least one Portletpublic boolean isAssigned(int nDocumentId,
int nPortletId)
Document is assigned (unpublished or published) into the specified Portletpublic DocumentPublication getDocumentPublication(int nPortletId, int nDocumentId)
nPortletId - the Portlet identifiernDocumentId - the Document identifierDocumentPublication or null if no object matchpublic Collection<Document> getAssignedDocumentsByPortletId(int nPortletId)
Collection of Document objects from a Portlet identifier
Document can be assigned or published.nPortletId - the Portlet identifierCollection of Document objectspublic Collection<Document> getPublishedDocumentsByPortletId(int nPortletId)
nPortletId - the portlet identifierpublic Document getFirstValidPublishedDocument(int nPortletId)
nPortletId - the portlet identifierpublic Collection<Document> getPublishedDocumentsSinceDate(Date datePublishing, DocumentFilter documentFilter, Locale locale)
datePublishing - The start publication datedocumentFilter - The filter for the published documents. The filter can be null or empty. The array of Ids will not be taked in account.locale - The locale is used to get the list of documents with the findByFilter methodpublic Collection<fr.paris.lutece.portal.business.portlet.Portlet> getPortletsByDocumentId(String strDocumentId)
strDocumentId - the document identifierCollection of the portletspublic Collection<fr.paris.lutece.portal.business.portlet.Portlet> getPublishedPortlets()
Collection of the portletspublic int getMaxDocumentOrderByPortletId(int nPortletId)
Portlet idnPortletId - the Portlet identiferCopyright © 2020 City of Paris. All rights reserved.