Package lumis.portal.project
Interface IProjectManagerSPI
-
- All Known Implementing Classes:
ProjectManager
public interface IProjectManagerSPI
Manages LumisXP projects.- Since:
- 12.4.0
- Version:
- $Revision: 23904 $ $Date: 2020-06-16 12:23:44 -0300 (Tue, 16 Jun 2020) $
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description void
addProject(IProject project)
Adds the given project.void
clearCache()
Clears cache using current transaction..void
deleteProjects(java.util.Collection<java.lang.String> ids)
Deletes the projects with the given identifiers.void
disconnectProjectFromChannel(java.lang.String channelId)
Disconnects the project (if any) of the given channel.java.util.Collection<IProject>
getAllProjects()
Returns all projects.java.util.Optional<IProject>
getLocalProjectByChannelId(java.lang.String channelId)
Returns an optional project based on the given channel identifier.java.util.Optional<IProject>
getProjectByChannelId(java.lang.String channelId)
Returns an optional project based on the given channel identifier.java.util.Optional<IProject>
getProjectByWebsiteId(java.lang.String websiteId)
Returns an optional project based on the given website identifier.void
updateProject(IProject project)
Updates the given project.
-
-
-
Method Detail
-
getAllProjects
java.util.Collection<IProject> getAllProjects() throws PortalException
Returns all projects.- Returns:
- all projects.
- Throws:
PortalException
- if some error occur.- Since:
- 12.4.0
-
getProjectByWebsiteId
java.util.Optional<IProject> getProjectByWebsiteId(java.lang.String websiteId) throws PortalException
Returns an optional project based on the given website identifier. The optional will not be present if no such project could be found. This operation tries to find the project recursively among the given website's channel and all its parents.- Parameters:
websiteId
- the website identifier.- Returns:
- an optional project based on the given website identifier.
- Throws:
PortalException
- if some error occur.- Since:
- 12.4.0
-
getProjectByChannelId
java.util.Optional<IProject> getProjectByChannelId(java.lang.String channelId) throws PortalException
Returns an optional project based on the given channel identifier. The optional will not be present if no such project could be found. This operation tries to find the project recursively among the given channel and all its parents.- Parameters:
channelId
- the channel identifier.- Returns:
- an optional project based on the given channel identifier.
- Throws:
PortalException
- if some error occur.- Since:
- 12.4.0
-
getLocalProjectByChannelId
java.util.Optional<IProject> getLocalProjectByChannelId(java.lang.String channelId) throws PortalException
Returns an optional project based on the given channel identifier. The optional will not be present if no such project could be found. Does not consider channel structure inheritance.- Parameters:
channelId
- the channel identifier.- Returns:
- an optional project based on the given channel identifier.
- Throws:
PortalException
- if some error occur.- Since:
- 12.4.0
-
addProject
void addProject(IProject project) throws AccessDeniedException, TransactionRequiredException, PortalException
Adds the given project.- Parameters:
project
- the project.- Throws:
java.lang.NullPointerException
- if the given project isnull
.java.lang.NullPointerException
- if the given project does not have a name.java.lang.NullPointerException
- if there's no current user's session.AccessDeniedException
- if the current user does not have manage portal permission.TransactionRequiredException
- if there's no current transaction.PortalException
- if there's already a project with the same channel identifier.PortalException
- if other error occur.- Since:
- 12.4.0
-
updateProject
void updateProject(IProject project) throws AccessDeniedException, TransactionRequiredException, PortalException, ImmutableResourceException
Updates the given project.- Parameters:
project
- the project.- Throws:
java.lang.NullPointerException
- if the given project isnull
.java.lang.NullPointerException
- if the given project does not have an identifier.java.lang.NullPointerException
- if the given project does not have a name.java.lang.NullPointerException
- if there's no current user's session.AccessDeniedException
- if the current user does not have manage portal permission.TransactionRequiredException
- if there's no current transaction.PortalException
- if there's already a project with the same channel identifier.ImmutableResourceException
- if the project trying to be updated cannot be updated.PortalException
- if other error occur.- Since:
- 12.4.0
-
deleteProjects
void deleteProjects(java.util.Collection<java.lang.String> ids) throws AccessDeniedException, TransactionRequiredException, PortalException, ImmutableResourceException
Deletes the projects with the given identifiers. Those identifiers that does not refer to an existent project will be ignored.- Parameters:
ids
- the identifiers of the projects to be deleted.- Throws:
java.lang.NullPointerException
- if the given identifiers is null.java.lang.NullPointerException
- if there's no current user's session.AccessDeniedException
- if the current user does not have manage portal permission.TransactionRequiredException
- if there's no current transaction.ImmutableResourceException
- if some of the projects trying to be deleted cannot be deleted.PortalException
- if other error occur.- Since:
- 12.4.0
-
disconnectProjectFromChannel
void disconnectProjectFromChannel(java.lang.String channelId) throws PortalException
Disconnects the project (if any) of the given channel.- Parameters:
channelId
- the channel identifier.- Throws:
PortalException
- Since:
- 12.4.0
-
clearCache
void clearCache() throws PortalException
Clears cache using current transaction..- Throws:
PortalException
- Since:
- 12.4.0
-
-