public class ServicePreAction
extends com.liferay.portal.kernel.events.Action
Modifier and Type | Class and Description |
---|---|
protected class |
ServicePreAction.LayoutComposite |
Modifier and Type | Field and Description |
---|---|
protected File |
privateLARFile |
protected File |
publicLARFile |
Constructor and Description |
---|
ServicePreAction() |
Modifier and Type | Method and Description |
---|---|
protected void |
addDefaultLayoutsByLAR(long userId,
long groupId,
boolean privateLayout,
File larFile) |
protected void |
addDefaultUserPrivateLayoutByProperties(long userId,
long groupId) |
protected void |
addDefaultUserPrivateLayouts(com.liferay.portal.kernel.model.User user) |
protected void |
addDefaultUserPublicLayoutByProperties(long userId,
long groupId) |
protected void |
addDefaultUserPublicLayouts(com.liferay.portal.kernel.model.User user) |
protected void |
deleteDefaultUserPrivateLayouts(com.liferay.portal.kernel.model.User user) |
protected void |
deleteDefaultUserPublicLayouts(com.liferay.portal.kernel.model.User user) |
protected ServicePreAction.LayoutComposite |
getDefaultUserPersonalSiteLayoutComposite(com.liferay.portal.kernel.model.User user) |
protected ServicePreAction.LayoutComposite |
getDefaultUserSitesLayoutComposite(com.liferay.portal.kernel.model.User user) |
protected ServicePreAction.LayoutComposite |
getDefaultViewableLayoutComposite(javax.servlet.http.HttpServletRequest request,
com.liferay.portal.kernel.model.User user,
com.liferay.portal.kernel.security.permission.PermissionChecker permissionChecker,
long doAsGroupId,
boolean signedIn) |
protected ServicePreAction.LayoutComposite |
getDefaultVirtualHostLayoutComposite(javax.servlet.http.HttpServletRequest request) |
protected String |
getFriendlyURL(String friendlyURL) |
protected ServicePreAction.LayoutComposite |
getGuestSiteLayoutComposite(com.liferay.portal.kernel.model.User user) |
protected ServicePreAction.LayoutComposite |
getViewableLayoutComposite(javax.servlet.http.HttpServletRequest request,
com.liferay.portal.kernel.model.User user,
com.liferay.portal.kernel.security.permission.PermissionChecker permissionChecker,
com.liferay.portal.kernel.model.Layout layout,
List<com.liferay.portal.kernel.model.Layout> layouts,
long doAsGroupId) |
protected ServicePreAction.LayoutComposite |
getViewableLayoutComposite(javax.servlet.http.HttpServletRequest request,
com.liferay.portal.kernel.model.User user,
com.liferay.portal.kernel.security.permission.PermissionChecker permissionChecker,
ServicePreAction.LayoutComposite defaultLayoutComposite,
long doAsGroupId) |
protected boolean |
hasAccessPermission(com.liferay.portal.kernel.security.permission.PermissionChecker permissionChecker,
com.liferay.portal.kernel.model.Layout layout,
long doAsGroupId,
boolean checkViewableGroup) |
protected Boolean |
hasPowerUserRole(com.liferay.portal.kernel.model.User user) |
protected void |
initImportLARFiles() |
com.liferay.portal.kernel.theme.ThemeDisplay |
initThemeDisplay(javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response) |
protected boolean |
isLoginRequest(javax.servlet.http.HttpServletRequest request)
Returns
true if the request URI's path starts with the
portal's default login path c/portal/login . |
protected List<com.liferay.portal.kernel.model.Layout> |
mergeAdditionalLayouts(javax.servlet.http.HttpServletRequest request,
com.liferay.portal.kernel.model.User user,
com.liferay.portal.kernel.security.permission.PermissionChecker permissionChecker,
com.liferay.portal.kernel.model.Layout layout,
List<com.liferay.portal.kernel.model.Layout> layouts,
long doAsGroupId) |
protected void |
rememberVisitedGroupIds(javax.servlet.http.HttpServletRequest request,
long currentGroupId) |
void |
run(javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response) |
protected void |
servicePre(javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response) |
protected void |
updateUserLayouts(com.liferay.portal.kernel.model.User user) |
protected File privateLARFile
protected File publicLARFile
public com.liferay.portal.kernel.theme.ThemeDisplay initThemeDisplay(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response) throws Exception
Exception
public void run(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response) throws com.liferay.portal.kernel.events.ActionException
run
in class com.liferay.portal.kernel.events.Action
com.liferay.portal.kernel.events.ActionException
protected void addDefaultLayoutsByLAR(long userId, long groupId, boolean privateLayout, File larFile) throws com.liferay.portal.kernel.exception.PortalException
com.liferay.portal.kernel.exception.PortalException
protected void addDefaultUserPrivateLayoutByProperties(long userId, long groupId) throws com.liferay.portal.kernel.exception.PortalException
com.liferay.portal.kernel.exception.PortalException
protected void addDefaultUserPrivateLayouts(com.liferay.portal.kernel.model.User user) throws com.liferay.portal.kernel.exception.PortalException
com.liferay.portal.kernel.exception.PortalException
protected void addDefaultUserPublicLayoutByProperties(long userId, long groupId) throws com.liferay.portal.kernel.exception.PortalException
com.liferay.portal.kernel.exception.PortalException
protected void addDefaultUserPublicLayouts(com.liferay.portal.kernel.model.User user) throws com.liferay.portal.kernel.exception.PortalException
com.liferay.portal.kernel.exception.PortalException
protected void deleteDefaultUserPrivateLayouts(com.liferay.portal.kernel.model.User user) throws com.liferay.portal.kernel.exception.PortalException
com.liferay.portal.kernel.exception.PortalException
protected void deleteDefaultUserPublicLayouts(com.liferay.portal.kernel.model.User user) throws com.liferay.portal.kernel.exception.PortalException
com.liferay.portal.kernel.exception.PortalException
protected ServicePreAction.LayoutComposite getDefaultUserPersonalSiteLayoutComposite(com.liferay.portal.kernel.model.User user)
protected ServicePreAction.LayoutComposite getDefaultUserSitesLayoutComposite(com.liferay.portal.kernel.model.User user) throws com.liferay.portal.kernel.exception.PortalException
com.liferay.portal.kernel.exception.PortalException
protected ServicePreAction.LayoutComposite getDefaultViewableLayoutComposite(javax.servlet.http.HttpServletRequest request, com.liferay.portal.kernel.model.User user, com.liferay.portal.kernel.security.permission.PermissionChecker permissionChecker, long doAsGroupId, boolean signedIn) throws com.liferay.portal.kernel.exception.PortalException
com.liferay.portal.kernel.exception.PortalException
protected ServicePreAction.LayoutComposite getDefaultVirtualHostLayoutComposite(javax.servlet.http.HttpServletRequest request) throws com.liferay.portal.kernel.exception.PortalException
com.liferay.portal.kernel.exception.PortalException
protected String getFriendlyURL(String friendlyURL)
protected ServicePreAction.LayoutComposite getGuestSiteLayoutComposite(com.liferay.portal.kernel.model.User user) throws com.liferay.portal.kernel.exception.PortalException
com.liferay.portal.kernel.exception.PortalException
protected ServicePreAction.LayoutComposite getViewableLayoutComposite(javax.servlet.http.HttpServletRequest request, com.liferay.portal.kernel.model.User user, com.liferay.portal.kernel.security.permission.PermissionChecker permissionChecker, com.liferay.portal.kernel.model.Layout layout, List<com.liferay.portal.kernel.model.Layout> layouts, long doAsGroupId) throws com.liferay.portal.kernel.exception.PortalException
com.liferay.portal.kernel.exception.PortalException
protected ServicePreAction.LayoutComposite getViewableLayoutComposite(javax.servlet.http.HttpServletRequest request, com.liferay.portal.kernel.model.User user, com.liferay.portal.kernel.security.permission.PermissionChecker permissionChecker, ServicePreAction.LayoutComposite defaultLayoutComposite, long doAsGroupId) throws com.liferay.portal.kernel.exception.PortalException
com.liferay.portal.kernel.exception.PortalException
protected boolean hasAccessPermission(com.liferay.portal.kernel.security.permission.PermissionChecker permissionChecker, com.liferay.portal.kernel.model.Layout layout, long doAsGroupId, boolean checkViewableGroup) throws com.liferay.portal.kernel.exception.PortalException
com.liferay.portal.kernel.exception.PortalException
protected Boolean hasPowerUserRole(com.liferay.portal.kernel.model.User user) throws Exception
Exception
protected void initImportLARFiles()
protected boolean isLoginRequest(javax.servlet.http.HttpServletRequest request)
true
if the request URI's path starts with the
portal's default login path c/portal/login
.request
- the servlet request for the page, which can be a result
of a redirecttrue
if the request is a login request;
false
otherwiseprotected List<com.liferay.portal.kernel.model.Layout> mergeAdditionalLayouts(javax.servlet.http.HttpServletRequest request, com.liferay.portal.kernel.model.User user, com.liferay.portal.kernel.security.permission.PermissionChecker permissionChecker, com.liferay.portal.kernel.model.Layout layout, List<com.liferay.portal.kernel.model.Layout> layouts, long doAsGroupId) throws com.liferay.portal.kernel.exception.PortalException
com.liferay.portal.kernel.exception.PortalException
protected void rememberVisitedGroupIds(javax.servlet.http.HttpServletRequest request, long currentGroupId)
protected void servicePre(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response) throws Exception
Exception
protected void updateUserLayouts(com.liferay.portal.kernel.model.User user) throws Exception
Exception